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 memory leak by putting setInterval() in a useeffect #82

Merged
merged 5 commits into from
Nov 28, 2024

Conversation

rerpha
Copy link
Contributor

@rerpha rerpha commented Nov 27, 2024

Closes #80

this also fixes a bug that we witnessed a few weeks ago where POLREF got stuck in RESUMING on the wall display.

@rerpha rerpha mentioned this pull request Nov 27, 2024
app/wall/page.tsx Outdated Show resolved Hide resolved
Copy link
Contributor

@Tom-Willemsen Tom-Willemsen left a comment

Choose a reason for hiding this comment

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

This refactor got a bit big!

Functionally, did leave a tab open on wall display overnight and didn't seem to use significantly more memory after a long time. Refactors look good although I didn't go through all with a fine-tooth comb...

@rerpha
Copy link
Contributor Author

rerpha commented Nov 28, 2024

it did, sorry, i got a bit carried away as I noticed a few issues with the wall display not updating sometimes etc.
let's merge for now if you're happy. I think there's a lot more tests that can/should be added for some of the components which don't have snapshot tests, we should have most things typed now so that should help a bit.

@rerpha rerpha merged commit 726f733 into main Nov 28, 2024
3 checks passed
@rerpha rerpha deleted the 80_fix_memory_leak branch November 28, 2024 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

High memory usage
2 participants