-
-
Notifications
You must be signed in to change notification settings - Fork 788
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
refactor events #2403
refactor events #2403
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2403 +/- ##
==========================================
- Coverage 85.73% 85.48% -0.25%
==========================================
Files 91 91
Lines 9101 9035 -66
Branches 2176 2151 -25
==========================================
- Hits 7803 7724 -79
- Misses 796 805 +9
- Partials 502 506 +4
Continue to review full report at Codecov.
|
This pull request introduces 3 alerts when merging 492587d into 0a389e3 - view on LGTM.com new alerts:
|
492587d
to
e9e568c
Compare
This pull request introduces 8 alerts when merging e9e568c into 0a389e3 - view on LGTM.com new alerts:
|
- use abi_encode for the data - use keccak256_helper for non-basetype topics - block non-value types in indexes note: a test for blocked functionality has been removed because the functionality now works
e9e568c
to
52ac67a
Compare
c777653
to
be42f18
Compare
The key is to make sure the memory is allocated and registered with the context variable BEFORE evaluating the expressions inside the event (in case any of them make internal calls) fixes vyperlang#1476
be42f18
to
cea5dd8
Compare
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.
Not sure I understand the test changes (from static array to integer), but otherwise looks fine
I removed those because arrays are now blocked from being event indexes. |
if typ.is_dynamic_size: | ||
maxlen += typ.size_in_bytes | ||
# sanity check, abi size_bound is the same calculated both ways | ||
print(data.typ, type(data.typ)) |
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.
oh haha i left this in
What I did
refactor events to use abi_encode. Fixes #1170, #1476
note: a test for blocked functionality has been removed because the functionality now works
How I did it
How to verify it
Description for the changelog
Cute Animal Picture