Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new field in CCTX object to contains cross-chain call error #2913

Open
lumtis opened this issue Sep 24, 2024 · 3 comments · May be fixed by #2952
Open

Add new field in CCTX object to contains cross-chain call error #2913

lumtis opened this issue Sep 24, 2024 · 3 comments · May be fixed by #2952
Assignees

Comments

@lumtis
Copy link
Member

lumtis commented Sep 24, 2024

Describe the Issue

Currently the error of a cross-chain call is contained in the cctx.status.status_message which might contain other concatenated strings which makes the error difficult to read.

This issue is about adding a field to contains specifically the cross-chain call error.

In addition: adding a query to directly fetch this error message from the cctx index.

@fbac fbac self-assigned this Sep 25, 2024
@fbac fbac linked a pull request Oct 1, 2024 that will close this issue
6 tasks
@kingpinXD
Copy link
Contributor

kingpinXD commented Oct 2, 2024

We might have more than 1 error message,
For example if a tx revertes and the abort fails , there would be two error messages ,

  • original TX failure
  • revert tx failure

I think it would be a good idea to make it clear to the user which is which

I feel it would be benificial for users to see something like

Outbound Error : XXX
Revert Error : XXX

@kingpinXD
Copy link
Contributor

kingpinXD commented Oct 2, 2024

Sample call

contract call failed: method 'depositAndCall', contract '0xEdf1c3275d13489aCdC6cD6eD246E72458B8795B', args: [{[116 98 49 112 57 50 54 117 121 121 102 121 48 57 57 101 114 112 121 115 118 103 122 56 99 120 48 120 113 99 107 119 114 120 119 122 50 55 55 100 109 118 119 113 48 115 102 113 102 120 115 57 115 108 112 113 54 53 56 103 103 51] 0x0000000000000000000000000000000000000000 18332} 0x65a45c57636f9BcCeD4fe193A602008578BcA90b 9294 0xE869b85987D86d8fBb8913f97A705B4741edE86E [232 105 184 89 135 216 109 143 187 137 19 249 122 112 91 71 65 237 232 110 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 64 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 31 8 114 173 89 103 28 32 216 199 223 23 218 144 178 97 227 198 29 206 71 31 177 222 58 199 57 100 26 67 128 175 0 0 0 0 0 0 0 0 0 0 0 0 126 135 72 161 246 45 197 182 19 229 130 54 52 51 181 206 92 51 225 55 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 128 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 65 175 191 243 152 14 157 230 78 250 153 214 115 97 4 131 21 152 237 112 234 246 43 190 249 73 184 226 162 133 70 151 205 109 70 59 128 91 14 111 31 146 175 64 231 41 105 163 226 174 101 216 41 59 122 188 107 40 167 241 147 210 184 116 198 28 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]]: execution reverted: ret 0x: evm transaction execution failed : outTxGasFee(11800) more than available gas for tx (9294) | Identifiers : tb1p926uyyfy099erpysvgz8cx0xqckwrxwz277dmvwq0sfqfxs9slpq658gg3-18332-18332-0 : not enough gas

@fbac
Copy link
Contributor

fbac commented Oct 2, 2024

We might have more than 1 error message, For example if a tx revertes and the abort fails , there would be two error messages ,

  • original TX failure
  • revert tx failure

I think it would be a good idea to make it clear to the user which is which

I feel it would be benificial for users to see something like

Outbound Error : XXX Revert Error : XXX

This can be done having multiple error/status fields, such as cctx.outbound_status and cctx.revert_status.
The problem is in that case we might want to include as well abort_status, etc...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants