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

api: fix wait_for_transaction_receipt for neo-go nodes #273

Merged
merged 1 commit into from
Aug 1, 2023

Conversation

ixje
Copy link
Member

@ixje ixje commented Aug 1, 2023

  1. neo-go nodes return a different error message when a transaction cannot be found. Which breaks the wait_for_transaction_receipt() helper function.
  2. neo-go when asking for a transaction that does not exist (e.g. because the block is not yet processed) an error is expected. However, the neo-go nodes do not set the content-type of the response to application/json like the C# nodes do. This causes a failed content-type check during the conversion to JSON using aiohttp. This PR also disables content-type checking in the RPC client.

@coveralls
Copy link

coveralls commented Aug 1, 2023

Coverage Status

coverage: 80.779%. remained the same when pulling d45125e on fix-wait-receipt into 90006e0 on master.

@ixje ixje merged commit cffc4e2 into master Aug 1, 2023
11 checks passed
@ixje ixje deleted the fix-wait-receipt branch August 1, 2023 12:34
@AnnaShaleva
Copy link

BTW, implementation of neo-project/proposals#156 for both NeoC# and NeoGo will solve the first problem. And we have nspcc-dev/neo-go#3063 in progress, the error text for this case won't be changed, but it will have a special error code.

@ixje
Copy link
Member Author

ixje commented Aug 7, 2023

if only they'd move the PR forward before 2030 🤷

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

Successfully merging this pull request may close these issues.

3 participants