-
Notifications
You must be signed in to change notification settings - Fork 375
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
Storing previous randomness values #1197
Storing previous randomness values #1197
Conversation
Thanks for the PR @mrsmkl ! We are currently still discussing the specific change, but I can tell you that we can't store the whole history for sure. Ill update here once that is the case! |
Would you mind adding some? I suspect we don't have them because of the We can define an internal function that has all of the business logic, and then expose it in an external function that just requires msg.sender == address(0) and then calls the internal function. Then, for testing, we can create Here's an example for |
Codecov Report
@@ Coverage Diff @@
## master #1197 +/- ##
=========================================
+ Coverage 65.33% 67.1% +1.76%
=========================================
Files 271 266 -5
Lines 8184 7776 -408
Branches 570 444 -126
=========================================
- Hits 5347 5218 -129
+ Misses 2716 2458 -258
+ Partials 121 100 -21
Continue to review full report at Codecov.
|
@@ -13,7 +13,18 @@ contract Random is IRandom { | |||
|
|||
bytes32 public _random; |
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 now redundant with history?
For some reason the end-to-end transfer tests appear to be failing.. |
…repo into randomness-history-1181
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.
Just a few nits
README-dev.md
Outdated
2. Exception to (1) are packages that represent a GAE/firebase app which must use the last published version. | ||
3. To differentiate published vs unpublished version. Master version (in package.json) must end with suffix `-dev` and should not be published. | ||
4. If a developer want to publish a version; then after publishing it needs to set master version to next `-dev` version and change all package.json that require on it. | ||
1. All packages must use **master version** of sibling packages. |
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.
Were the changes to the readmes intentional? If not, please revert.
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.
I wonder where this came from...
Let's hold off on merging this until we cut for Alfajores deploy since this is breaking mobile clients |
…repo into aaronmgdr/invite-page * 'aaronmgdr/invite-page' of github.com:celo-org/celo-monorepo: (63 commits) Fix compile error during local clean build (#1506) Update to RN 61 and AndroidX (#1343) Set usage of shuffled round robin in the genesis block (#1464) Add spanish backup key for backup key flow (#1500) Fix sync tests by pulling genesis block to determine epoch length (#1504) [Wallet] fix missing full name error alert (#1496) [Wallet + Verification Pool] Add details about generating an app-signature (#1482) Deploy celo's image of ethstats (#1421) Storing previous randomness values (#1197) [Wallet] Fix wei invite bug (#1489) Point all packages to latest ganache-cli master (#1488) Point end-to-end tests back to master (#1469) [Wallet] Migrate app view functions to contractkit (#1381) [Wallet] Add script to translate locale strings (#1485) [Wallet] Update wallet celo client version and add missing translations for backup flow (#1483) [Wallet] Hotfix local currency (#1481) [Wallet] Remove QR debouncing to improve responsiveness (#1480) [Wallet] Upgrade app version to v1.5.1 (#1463) Update governance end-to-end tests to work with changed precompile (#1476) Fixes key_placer.sh when encrypting files (#1465) ...
Description
Just stores the randomness value to a mapping. If it is too much overhead to store it for all blocks, it can be easily changed to just store N previous blocks.
Tested
I didn't see any tests related to randomness.
Other changes
Related issues
Backwards compatibility