-
Notifications
You must be signed in to change notification settings - Fork 72
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
fix: check state changes #126
Conversation
Ah this makes sense. Since I can't dispatch workflows from branches from a fork (which makes sense, to avoid leaking secrets), I've pushed this commit to a temporary brach and kicked off the CI job |
thought on also implementing this? ArbitrumFoundation@cf816df although that would also mean the CI would run nothing most of the time with this haha |
Looks like this sims for this PR worked as expected! I noticed the
I agree this would be nice and the current CI is pretty wasteful. We have it tracked in #117, using the approach that the BDG Labs fork uses, to ensure old reports are cached and easily accessible. The main reason it hasn't been done is that currently no one is actively working on improvements to Seatbelt. I'm no longer at ScopeLift, but previously we were maintaining it while I was there. I'm not sure if @apbendi and co. have any upcoming plans to keep working on some of the improvements being tracked in the issues |
I see, I might implement that later but for now let's merge this? |
Hey @mds1 @gzeoneth 👋 Vuk from Tenderly here... To me this looks good just off the top of my head, but I didn't manage to find the time to dive deep since we had too many support requests left over from the Holidays. If you'd like a more certain answer, I can take a deeper look tomorrow and let you know. I understand that this is governance, so you'd like to be pretty certain, correct? |
Thanks @beruda! A deeper look would be appreciated—I mainly just want to have confidence that the way we are parsing state diffs will not result in any missing or incorrect data :) |
Hey @mds1 @gzeoneth , Aleksandar from Tenderly here 👋 I took a look at our code, and ran some tests. In short, your logic is correct. If there is no change (i.e. The only time we will return null values is if we fail to decode the variable, as your comment on the other PR states. In case of mappings, it is indeed possible that either original or dirty value for a certain key will be null. This mostly happens in cases where we fail to decode the variable. It is also possible to happen for some types when the value of a mapping was reset to 0-value. Regardless, your logic for checking if the keys are present in the map is the way to go for mappings. This can also happen for elements of dynamic arrays, but I see that you are using raw state changes for them, so that will continue to work as expected. Hope this clears things up for you! |
@mds1 can we merge or is there anything unresolved? |
Sorry for the delay here, I was out most of the day today and didn't get to this yesterday. Just caught up and we should be all set here, so going to merge this now. Thank you @beruda and @strahor-13 for the explanations and confirming our implementations, and thank you @gzeoneth for the PR! |
Was #124 reverted by #125
Handling a case where when the diff is a decoded mapping, the original object can be null if the key was not present in the original state. Example:
Uniswap prop 11
this change is previously ignored due to original===null, also note that the raw object only report the first slot changed in a mapping so using the decoded field is crucial
Tested with no error with the ENS governor