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

TransactionState.FromStackItem throws when state not available #2721

Closed
devhawk opened this issue May 6, 2022 · 2 comments
Closed

TransactionState.FromStackItem throws when state not available #2721

devhawk opened this issue May 6, 2022 · 2 comments

Comments

@devhawk
Copy link
Contributor

devhawk commented May 6, 2022

#2591 was the first PR merged after Neo 3.1 shipped. This PR added a public VMState State; field to TransactionState. However, the TransactionState.FromStackItem method does not take into account that the State field will not be present for any transactions that were recorded before 3.2 ships. So any 3.2 code that attempts to retrieve a TransactionState that was recorded during 3.1 or earlier will throw.

This will affect any method that calls LedgerContract.GetTransactionState

@devhawk devhawk mentioned this issue May 6, 2022
19 tasks
@devhawk
Copy link
Contributor Author

devhawk commented May 6, 2022

Note, this is likely NOT an issue if we do a full resync for 3.2 (which may be required for other reasons). However, the existing error message (index out of range) is not going to be helpful for an operator who runs into this issue.

@shargon
Copy link
Member

shargon commented May 7, 2022

I think that we should resync

@erikzhang erikzhang closed this as not planned Won't fix, can't repro, duplicate, stale May 20, 2022
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

No branches or pull requests

3 participants