-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Warn user at deploy time if contract size above ethereum/EIPs#170 #1461
Conversation
src/app/tabs/run-tab.js
Outdated
} | ||
|
||
if (selectedContract.contract.object.evm.deployedBytecode.object.length > 24576) { | ||
modalDialog('Contract code size over limit', yo`<div>Contract creation initialization returns data with length of more than 24576 bytes. The deployment will likely fails.</div>`, |
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.
could we add a link to the iep too? (as reference to user know what is this limitation for)
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.
@yann300 -- i've added it ^^
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 but i meant as a link in the content of the modal too
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's done ^^
0b2a49b
to
694e311
Compare
@yann300 --- anything else i need to do? |
src/app/tabs/run-tab.js
Outdated
}) | ||
} | ||
|
||
if (selectedContract.contract.object.evm.deployedBytecode.object.length > 24576) { |
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.
object
here is hex string.
1 hex string is 1/2 bytes.
so you need to divide by 2 here to get the length in bytes
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.
@yann300 - thanks, i fixed it
Fix: #1457