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

fix(#2035): Prevent infinite loops caused by cyclic references on typedValue #2036

Merged
merged 3 commits into from
May 6, 2024

Conversation

omarsy
Copy link
Member

@omarsy omarsy commented May 4, 2024

Closes #2035.

Contributors' checklist...
  • Added new tests, or not needed, or not feasible
  • Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory
  • Updated the official documentation or not needed
  • No breaking changes were made, or a BREAKING CHANGE: xxx message was included in the description
  • Added references to related issues and PRs
  • Provided any useful hints for running manual tests
  • Added new benchmarks to generated graphs, if any. More info here.

@github-actions github-actions bot added the 📦 🤖 gnovm Issues or PRs gnovm related label May 4, 2024
Copy link

codecov bot commented May 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 46.74%. Comparing base (555357e) to head (4044fe0).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2036      +/-   ##
==========================================
- Coverage   46.74%   46.74%   -0.01%     
==========================================
  Files         492      492              
  Lines       69616    69614       -2     
==========================================
- Hits        32542    32539       -3     
- Misses      34363    34364       +1     
  Partials     2711     2711              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@omarsy omarsy marked this pull request as draft May 4, 2024 21:08
@omarsy omarsy marked this pull request as ready for review May 4, 2024 22:00
@omarsy omarsy marked this pull request as draft May 4, 2024 22:03
@omarsy omarsy marked this pull request as ready for review May 5, 2024 16:46
Copy link
Contributor

@deelawn deelawn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for identifying and solving this bug. Could make the same change for the map key as well and add a file test to demonstrate the issue is fixed?

@omarsy
Copy link
Member Author

omarsy commented May 5, 2024

Thanks for identifying and solving this bug. Could make the same change for the map key as well and add a file test to demonstrate the issue is fixed?

Thank you for your review. ^^
I Add file test + apply same change for the map key on 4635def

@ltzmaxwell
Copy link
Contributor

Thanks for identifying and solving this bug. Could make the same change for the map key as well and add a file test to demonstrate the issue is fixed?

Thank you for your review. ^^ I Add file test + apply same change for the map key on 4635def

I guess what @deelawn suggests is that you can have another test file show case using a struct as key of a map to prove you modification thoroughly. But actually I found another bug from this direction, see #2041. cc @deelawn .

@deelawn deelawn merged commit c66adb2 into gnolang:master May 6, 2024
199 checks passed
@omarsy omarsy deleted the fix/2035 branch May 6, 2024 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📦 🤖 gnovm Issues or PRs gnovm related
Projects
Status: Done
Status: Done
Development

Successfully merging this pull request may close these issues.

Infinite Loop Caused by Self-Referencing Struct in Map
3 participants