-
Notifications
You must be signed in to change notification settings - Fork 34
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
VM Internal Error: MemOutOfBound with Capsule 0.9.0 #80
Comments
the tx built by capsule 0.9.0 should be running with ckb2021 edition ckb-vm, which is incompatible with old version ckb-vm, I think it will pass if you set the value of |
Is there any way this error could be recognized so a more friendly error message can be provided? |
@TravisLeeRichardson @jordanmack and I spent at least three days each thinking about this: we are smart and well informed on Nervos L1, but we couldn't figured it out. What would do a new developer who is trying out Nervos L1 for the first time? He probably just give up and go away from Nervos. @quake thanks for helping us, but please improve the error message 🙏 |
@jordanmack @phroi we'll figure out a way to display more friendly error messages, but before this issue is fixed, I'd also like to know where you saw the document of setting hash_type to |
Great news on more friendly error messages!! 🥳 As for me I'm following the Developer Training Course and noting errors as I go. You may want to check out if the current recommended guidelines are followed in the course! To be honest I believe there are good uses for both:
|
I see, in your example the |
if you want run a script compiled by capsule v0.8.0+ on vm0 (hash_type: data), you may need to run the ckb-binary-patcher with the compiled binary, which has been removed in this pr, or you may run it on vm1 (hash_type: data1 or type) directly without this patcher. @jordanmack could you update the https://nervos.gitbook.io/developer-training-course accordingly? I think change the lumos code from |
I already tried changing from |
@quake now basically the issue is displaying a proper error message when CKB VM 2021 binary is run in a old CKB VM, a very common mistake. Feel free to move and rename this issue to the appropriate repository! |
Yes, I am updating all references and will add a new section to explain data, type, and data1. |
Sometimes a binary will run fine in the old CKB-VM, and sometimes it fails with a strange error. This also adds to the confusion. |
Executing these tests shows that
Capsule 0.9.0
withrustc 1.63.0
suffer from:VM Internal Error: MemOutOfBound
when executing any non trivial script.Transaction timeout
when executingalways
success script.Note: creating and executing tests for these scripts will not manifest these issues without a full CKB VM environment.
The same scripts compiled with
Capsule 0.7.3
don't have these issues.Some research on these issues has been done already by Travis Lee Richardson and Jordan Mack.
Keep up the Great work 💪
Phroi
The text was updated successfully, but these errors were encountered: