-
Notifications
You must be signed in to change notification settings - Fork 85
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
[Access] Fix SendAndSubscribeTransactionStatuses and example #798
[Access] Fix SendAndSubscribeTransactionStatuses and example #798
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #798 +/- ##
==========================================
+ Coverage 56.59% 57.47% +0.88%
==========================================
Files 35 35
Lines 7305 7454 +149
==========================================
+ Hits 4134 4284 +150
+ Misses 2670 2660 -10
- Partials 501 510 +9
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
serviceAcctAddr, serviceAcctKey, serviceSigner := examples.ServiceAccount(flowClient) | ||
signerIndex := uint32(0) | ||
|
||
signerPublicAddress := flow.HexToAddress("YOUR_ACCOUNT_ADDRESS") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this example work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested it within the testnet, and yes, this is working.
In the same vein as @chasefleming 's comments. For consistency purposes, it's probably best to follow the approach already used by the send transaction example here. In this example, the Flow Emulator is used and the signer is the emulator service account. |
the issue here is that there are some AccessAPI endpoints that are missing from the emulator, which is why these changes were made. totally open to other options if you think there's a better way. eventually we will update the emulator to add these endpoints, but there is no demand for it other than this test so far. |
Gotcha, wasn't aware if this limitation 👍 |
Closes: #6604
Description
SendAndSubscribeTransactionStatuses
on the testnet, as the emulator does not support subscriptions.messageIndex
value has been fixed, as it should always start at 1.