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

Account for LangError #31

Merged
merged 1 commit into from
Jan 4, 2023
Merged

Account for LangError #31

merged 1 commit into from
Jan 4, 2023

Conversation

athei
Copy link
Collaborator

@athei athei commented Jan 4, 2023

The new ink! beta wraps cross contract calls into a Result<T, LangError>. Our low level cross contract call didn't account for that and hence failed to decode the Turn. It just decoded garbage which then turned out to be out of bounds.

@xermicus You need to make sure that your handwritten sol contract wraps the value as to game expects this after this PR is merged. Option just prepends one byte (0=None, 1=Some).

@netlify
Copy link

netlify bot commented Jan 4, 2023

Deploy Preview for squink-splash canceled.

Name Link
🔨 Latest commit 51926d6
🔍 Latest deploy log https://app.netlify.com/sites/squink-splash/deploys/63b5aeb6f894890008cb30b6

@athei athei merged commit 520e6f5 into main Jan 4, 2023
@athei athei deleted the at/fix-turn-decoding branch January 4, 2023 16:56
@ascjones
Copy link
Collaborator

ascjones commented Jan 4, 2023

linking use-ink/ink#1512

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