-
-
Notifications
You must be signed in to change notification settings - Fork 125
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
memory leak? #549
Comments
So, I did a little investigation (ran 4 different ags instances with different interval times, the first two with 5ms, the last two with 50ms. The first and third call But now I'm even more confused as why in the world this is happening? Well ok, in many cases it's not that critical since you won't run it infinitely, but the problem is that it doesn't free memory even when the interval is destroyed (or I'm doing something wrong, I'm a noob in JS), which can already lead to some bad consequences |
does printing the output directly (without passing into the json parser) trigger the GC? might be a leak in the JSON parser |
No, it doesn't. And memory leak happens only with Utils and Services methods like |
upd. The only solution I've come up with so far is to use an external script. But It really seems to be a problem with some parts of |
What's even weirder is that I have looked at the sources and 2024-08-26.12-06-38.mp4 |
RAM usage is growing uncontrollably when using
Utils.interval
. it looks like it's a problem withhyprland.messge()
(and.messageAsync()
as well, which is causing this to happen. I've tried usingUtils.exec()
alternatively and haven't noticed this behavior. Video below:vid.mp4
P.s. 1 millisecond interval for clarity. In reality, even with interval values like 100, memory usage grows, just a bit slower, but it is never freed, even when the interval is already destroyed.
The text was updated successfully, but these errors were encountered: