-
Notifications
You must be signed in to change notification settings - Fork 224
Update deploy command following NEO3 schema #463
Conversation
Great! Let me have a look. |
@shargon Hi, Shargon, I've made a test based on my simple sc. The content is:
It was compiled successfully within neon.exe |
Thanks for the test, i will review it |
You are right, we need some changes included in neo-project/neo-devpack-dotnet#93 , i will copy these fixes |
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.
Great to see how simpler is becomes!
|
||
if (!InteropService.SupportedMethods().ContainsKey(ci.TokenU32)) | ||
{ | ||
throw new FormatException($"Syscall not found {ci.TokenU32.ToString("x2")}. Are you using a NEO2 smartContract?"); |
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.
Is this needed, @shargon?
The compiler is going to be different.
Maybe we can just say that the syscall is not valid. I think there is not need to really explicit that it is NEO2.
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.
@vncoelho Hey, my friend, since we've not deployed a new nuget for NEO3 SmartContract Framework, and the NEO3 one is also using the version number 2.9.3
, it can make developers greatly confused, including me, hahaha. So I think this error message is necessary because if you're using the NEO2 nuget of Framework 2.9.3
to deploy a sc on NEO3, it's incompatible.
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.
Yes, If you use the old version of SmartContract.Framework, you can get a wrong NEF, so I think that this checks could be very useful. Is possible that some invalid contract pass, it is a basic filter for prevent some human errors.
@shargon we just have to replace ".nef" with "manifest.json", or equivalent (I don't recall the exact file extension) |
Is not the expected behavior , tell me one linux command that works as you said? |
@shargon all of them, you tell me a program that you have to point to all files 😂 For example |
Then i don't understand you very well, you are asking for a file (first parameter) and name (the second) ? give me an example please |
@lock9 please review it again. |
This reverts commit 47f3be0.
I'll let @nicolegys to have a test. |
Maybe the manifest is broken? I used the latest master and you can see that the file exists. EDIT: It worked when I added 'static' to the methods, maybe it should have blocked it at compilation time? |
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.
It is working.
Thanks @shargon!
we can remove the Debug directive |
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.
Thanks Shargon
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.
Tested. It works effectively.
Close neo-project/neo-devpack-dotnet#91
Require neo-project/neo-devpack-dotnet#109
Related to neo-project/neo-devpack-dotnet#91
Should follow this logic
https://github.com/neo-project/neo/blob/e1fdde307153879f0a7ae64bd3e11d042284896e/neo/SmartContract/InteropService.NEO.cs#L248