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

add add_global_state_det #190

Closed
wants to merge 2 commits into from

Conversation

zoedberg
Copy link
Contributor

This PR adds the possibility to add global state in a determistic way (necessary for the deterministic contract ID creation, see #111)

@dr-orlovsky
Copy link
Member

Thank you! I think we also need to assert that we do mot add deterministic state in non-deterministic builders - and then other way around. You can check how we do that in other method checking deterministic field

@dr-orlovsky dr-orlovsky linked an issue Apr 16, 2024 that may be closed by this pull request
@zoedberg
Copy link
Contributor Author

Thank you! I think we also need to assert that we do mot add deterministic state in non-deterministic builders - and then other way around. You can check how we do that in other method checking deterministic field

I'm not sure I understood what you exactly mean but I gave it a try anyway. I've also updated rgb-schemata PR accordingly

@dr-orlovsky
Copy link
Member

dr-orlovsky commented Apr 17, 2024

Ok, sorry, I was wrong three times:

First, this problem is a bug in RGB Core and must be fixed there: the global state must not have a salt or concealment. Here is the fix: RGB-WG/rgb-core#241

Second, deterministic flag was present in RGB20 helpers, and not this builders. I recognized it has to be added at the level of OperationBuilder instead, which I did in #191

Finally, we need to do that basing on script-refactor branch and not v0.11, since otherwise we won't be able to merge due to multiple conflicts touching the same code which was removed or changed in script-refactor.

Closing this PR since we have to use those different approaches and there is literally nothing which remains from the changes proposed here. Sorry for not understanding it in the original review and asking you to do something which was not correct.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Provide an API for deterministic contract generation
2 participants