-
Notifications
You must be signed in to change notification settings - Fork 45
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
Decode transaction errors #346
Comments
/start |
Tip
|
This library needs ethers v6, so we need to upgrade ethers from v5 to v6. Shall we upgrade ethers to v6? |
I think retaining v5 is more maintainable because LLMs are trained on it but not v6. |
We've just recently downgraded from v6 to v5. Perhaps there're other libs. |
I see. |
One potentially hacky method but it would give better insight maybe is the 4byte API where we can search for fn signatures and log them to the console on tx fail. Obv there are collisions and sometimes the sig has not been uploaded but it's something we can setup internally and it's free to use. I personally copy paste into 4byte when I'm debugging errors so this would make my life easier at least lmao |
Do you still have the result from 4byte? Curious how it looks like |
Copy the selector from the start of the data and then paste it into the function signature search feature on 4byte and it'll show you. You'll need to write logic to deal with the API for my suggestion ofc I do this when I'm writing tests, debugging, etc that sort of thing. It's tedious manually as sometimes there are 10-15 calls you need to manually track not always in the same order etc. I don't have any stored results or anything, whatever I gather at the time I comment in the code then remove it after I've fixed it. |
I am not sure why we need to use function search feature from 4byte. I tried the I thought what we need is to decode the transaction error and not function signature. The transaction error can be decoded by simply using this library ethers-decode-error/. I think it is sufficient. Did I miss something? |
They both help when debugging in my opinion but both are not required. The spec says to use the lib and decode, so do that and ignore my suggestion. My suggestion to implement it that way and then to embed it into our official
No, both approaches were suggested but the spec only lists one. My comment was given a thumbs-up which is usually a sign of approval but only I've mentioned it beyond that. Implement the spec unless someone explicitly approves my suggestion. |
Passed the deadline and no activity is detected, removing assignees: @ariesgun. |
/help |
Available Commands
|
/start |
Note that there is already a PR open for this issue |
|
View | Contribution | Count | Reward |
---|---|---|---|
Issue | Task | 1 | 150 |
Conversation Incentives
Comment | Formatting | Relevance | Priority | Reward |
---|
[ 9.324 UUSD ]
@0x4007
Contributions Overview
View | Contribution | Count | Reward |
---|---|---|---|
Issue | Comment | 1 | 2.226 |
Review | Comment | 6 | 7.098 |
Conversation Incentives
Comment | Formatting | Relevance | Priority | Reward |
---|---|---|---|---|
I think retaining v5 is more maintainable because LLMs are train… | 1.06content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 16 wordValue: 0.1 result: 1.06 | 0.7 | 3 | 2.226 |
I think we should self host @rndquu | 0.52content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 7 wordValue: 0.1 result: 0.52 | 0.7 | 3 | 1.092 |
Perhaps we need to get a copy of your repo and then host it. @rn… | 1.11content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 17 wordValue: 0.1 result: 1.11 | 0.6 | 3 | 1.998 |
I suppose all crypto related software should be under ubiquity o… | 0.77content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 11 wordValue: 0.1 result: 0.77 | 0.3 | 3 | 0.693 |
The crypto related stuff should be under @ubiquity | 0.59content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 8 wordValue: 0.1 result: 0.59 | 0.3 | 3 | 0.531 |
That's right we might not have access to the ubiquity npm for so… | 1.7content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 28 wordValue: 0.1 result: 1.7 | 0.5 | 3 | 2.55 |
@rndquu @gentlementlegen lets finalize this | 0.39content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 5 wordValue: 0.1 result: 0.39 | 0.2 | 3 | 0.234 |
[ 120.534 UUSD ]
@rndquu
Contributions Overview
View | Contribution | Count | Reward |
---|---|---|---|
Issue | Specification | 1 | 46.02 |
Issue | Comment | 1 | 2.82 |
Review | Comment | 4 | 71.694 |
Conversation Incentives
Comment | Formatting | Relevance | Priority | Reward |
---|---|---|---|---|
There's [this](https://github.com/superical/ethers-decode-error)… | 15.34content: content: p: score: 0 elementCount: 5 ul: score: 1 elementCount: 1 li: score: 0.5 elementCount: 2 a: score: 5 elementCount: 2 result: 12 regex: wordCount: 62 wordValue: 0.1 result: 3.34 | 1 | 3 | 46.02 |
We've just recently downgraded from v6 to v5. Perhaps there're o… | 0.94content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 14 wordValue: 0.1 result: 0.94 | 1 | 3 | 2.82 |
[This](https://github.com/ubiquity/pay.ubq.fi/pull/353#issuecomm… | 14.97content: content: p: score: 0 elementCount: 5 ol: score: 1 elementCount: 1 li: score: 0.5 elementCount: 2 a: score: 5 elementCount: 2 result: 12 regex: wordCount: 54 wordValue: 0.1 result: 2.97 | 1 | 3 | 44.91 |
Did you try NFT minting with this line added? | 0.65content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 9 wordValue: 0.1 result: 0.65 | 0.6 | 3 | 1.17 |
Isn't [NPM_TOKEN](https://github.com/ubiquity/ethers-decode-erro… | 11.44content: content: p: score: 0 elementCount: 1 a: score: 5 elementCount: 2 result: 10 regex: wordCount: 23 wordValue: 0.1 result: 1.44 | 0.5 | 3 | 17.16 |
As far as I understand everything is fine right now:- https://… | 14.09content: content: p: score: 0 elementCount: 4 ul: score: 1 elementCount: 1 li: score: 0.5 elementCount: 3 a: score: 5 elementCount: 2 result: 12.5 regex: wordCount: 26 wordValue: 0.1 result: 1.59 | 0.2 | 3 | 8.454 |
[ 64.215 UUSD ]
@Keyrxng
Contributions Overview
View | Contribution | Count | Reward |
---|---|---|---|
Issue | Comment | 3 | 36.039 |
Review | Comment | 2 | 28.176 |
Conversation Incentives
Comment | Formatting | Relevance | Priority | Reward |
---|---|---|---|---|
One potentially hacky method but it would give better insight ma… | 9.06content: content: p: score: 0 elementCount: 2 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 78 wordValue: 0.1 result: 4.06 | 0.5 | 3 | 13.59 |
Copy the selector from the start of the data and then paste it i… | 5.27content: content: p: score: 0 elementCount: 2 result: 0 regex: wordCount: 106 wordValue: 0.1 result: 5.27 | 0.5 | 3 | 7.905 |
They both help when debugging in my opinion but both are not req… | 6.06content: content: p: score: 0 elementCount: 3 result: 0 regex: wordCount: 125 wordValue: 0.1 result: 6.06 | 0.8 | 3 | 14.544 |
Yeah we do.Also Ana shared QA on another issue that showed the… | 3.84content: content: p: score: 0 elementCount: 3 result: 0 regex: wordCount: 73 wordValue: 0.1 result: 3.84 | 0.7 | 3 | 8.064 |
Looks good. Idk if it's worth it to also log the onchain functio… | 8.38content: content: p: score: 0 elementCount: 2 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 63 wordValue: 0.1 result: 3.38 | 0.8 | 3 | 20.112 |
[ 65.979 UUSD ]
@gentlementlegen
Contributions Overview
View | Contribution | Count | Reward |
---|---|---|---|
Review | Comment | 8 | 65.979 |
Conversation Incentives
Comment | Formatting | Relevance | Priority | Reward |
---|---|---|---|---|
I opened a PR on that regard here: https://github.com/ubiquity/e… | 6.17content: content: p: score: 0 elementCount: 2 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 18 wordValue: 0.1 result: 1.17 | 0.3 | 3 | 5.553 |
I had implemented our own `ethers-decode-error` but ever… | 7.3content: content: p: score: 0 elementCount: 3 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 40 wordValue: 0.1 result: 2.3 | 0.6 | 3 | 13.14 |
@0x4007 You are the one with `NPM` credentials if you ca… | 0.94content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 14 wordValue: 0.1 result: 0.94 | 0.4 | 3 | 1.128 |
@rndquu yeah I tried several times:https://github.com/ubiquity… | 7.73content: content: p: score: 0 elementCount: 3 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 49 wordValue: 0.1 result: 2.73 | 0.5 | 3 | 11.595 |
I published it under `ubiquity-os`: https://www.npmjs.co… | 11.17content: content: p: score: 0 elementCount: 2 a: score: 5 elementCount: 2 result: 10 regex: wordCount: 18 wordValue: 0.1 result: 1.17 | 0.7 | 3 | 23.457 |
@0x4007 Please move it because I have no access and the NPM toke… | 6.9content: content: p: score: 0 elementCount: 2 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 32 wordValue: 0.1 result: 1.9 | 0.3 | 3 | 6.21 |
@0x4007 would need the token to be updated in order to publish t… | 1.11content: content: p: score: 0 elementCount: 1 result: 0 regex: wordCount: 17 wordValue: 0.1 result: 1.11 | 0.4 | 3 | 1.332 |
@rndquu if you can delete https://github.com/ubiquity/ethers-dec… | 5.94content: content: p: score: 0 elementCount: 1 a: score: 5 elementCount: 1 result: 5 regex: wordCount: 14 wordValue: 0.1 result: 0.94 | 0.2 | 3 | 3.564 |
There's this package which is able to decode transaction errors which really helps in finding out the root cause of why permit or card minting is throwing an error.
As a part of this issue we should decode and show the decoded error to a user on:
Original comment
The text was updated successfully, but these errors were encountered: