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

Storage.Put() overcharging GAS fees #124

Closed
king-smith opened this issue Dec 9, 2017 · 4 comments
Closed

Storage.Put() overcharging GAS fees #124

king-smith opened this issue Dec 9, 2017 · 4 comments

Comments

@king-smith
Copy link

king-smith commented Dec 9, 2017

Storage.Put() currently charges a minimum GAS fee of 1, no matter how much data is actually written. I'm unsure if this is intended but it seems incorrect based on the documented system fees which indicate 1 GAS per KB: http://docs.neo.org/en-us/sc/systemfees.html

This line: https://github.com/neo-project/neo/blob/master/neo/SmartContract/ApplicationEngine.cs#L388

If unintended, the formula could be updated to something similar to: ((l1 + l2 - 1) * 1000) / 1024. If this was intended then the documents should be updated for clarity on the cost.

@erikzhang
Copy link
Member

You are right, the document should be updated.

@king-smith
Copy link
Author

Alright, thank you for clarifying 👍

@metachris
Copy link

What about leaving this issue open to track it and the progress, and only close it after the document has been updated?

@king-smith
Copy link
Author

Document has been updated by neo-project/docs#258, closing this.

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