fix(solana): add patched anchor-go NewCleanupIncompleteUploadInstruction instruction#906
Conversation
| @@ -356,15 +355,6 @@ func NewAssembleAndUpdateClientInstruction( | |||
| func NewCleanupIncompleteUploadInstruction( | |||
There was a problem hiding this comment.
This one is not used now. We use the patched version added in this PR.
| // The generated NewCleanupIncompleteUploadInstruction function sets instruction data to `nil` | ||
| // instead of encoding the discriminator. This file provides a corrected version. | ||
| // | ||
| // Tracking: This should be removed once the anchor-go bug is fixed upstream. |
There was a problem hiding this comment.
I'd suggest opening an issue to track it.
There was a problem hiding this comment.
I'd rather open an issue in anchor go and link it here
There was a problem hiding this comment.
there are already issues in anchor-go for this problem. Linked in the PR's description.
There was a problem hiding this comment.
I will add it in a comment
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #906 +/- ##
===========================================
+ Coverage 73.73% 99.90% +26.17%
===========================================
Files 111 27 -84
Lines 15931 1092 -14839
===========================================
- Hits 11747 1091 -10656
+ Misses 4184 1 -4183
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
srdtrk
left a comment
There was a problem hiding this comment.
Lgtm. You can merge it after linking an issue
| // The generated NewCleanupIncompleteUploadInstruction function sets instruction data to `nil` | ||
| // instead of encoding the discriminator. This file provides a corrected version. | ||
| // | ||
| // Tracking: This should be removed once the anchor-go bug is fixed upstream. |
There was a problem hiding this comment.
I'd rather open an issue in anchor go and link it here
Description
Add the manually patched function because the fix in anchor-go hasn't been merged for a while. Because of this bug, every time we run
just generate-solana-typesthe auto-generated function is recreated with a bug (missing discriminator).gagliardetto/anchor-go#50
gagliardetto/anchor-go#52
Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.
godoccomments.Files changedin the GitHub PR explorer.SonarCloud Reportin the comment section below once CI passes.