-
Notifications
You must be signed in to change notification settings - Fork 19
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
Querying any resource kills the game #17
Comments
Thx for report, will try to fix that. I thibk, that this is happening, because the mod querying KSP data too frequently in the Main thread. I'll try to detach it to different thread. |
Just curious, but is there a fixed release yet? The stuttering makes the game unplayable, which is a slight issue when doing IVA landings. |
With KSP 1.9.1 and Telemachus 1.7.64: Edit: It seems that polling Oxidizer Current Max at least still results in a memory leak. Edit2: When polling only r.resourceMax[Oxidizer] memory usage does not grow (after a run of 6 hours). When I added r.resourceCurrentMax[Oxidizer] it seemed to increase again. |
Okay, some findings of more extensive testing, KSP 1.9.1 + all DLC + Telemachus 1.7.64. In summary: I only got memory leaking when r.resource.currentMax[] is polled.
|
Has this bug been resolved in the latest release? Sorry for asking again, but just want to check if it's been/being looked at |
So I've found a weird issue. If you query "r.resourceCurrent" or "r.resourceCurrentMax", the game starts to lag a lot. Doesn't matter if you do it via WebSocket or HTTP API.
I have installed MemGraph to see memory usage and there is a notable spike in RAM usage. Also it starts to do more frecuent GC calls. After a few minutes, the memory usage and the GC calls starts to go up and up until the game is unplayable because it's stuttering.
That's my list of subscriptions for telemachus. Notice how the reources are commented out.
If I start a web socket with those parameters, everything works nice and awesome. But the moment I add any of those four commented parameters, the game starts to lag.
Here I'm in orbit with a Probodobodyne HECS2 core. The vessel only has a couple solar panels and the antena. It doesn't have any fuel or engines.
You can see the memory usage is rather normal with a few GC calls that don't lag the game. It has been running for 15 minutes or so.
(I'm connected via telemachus and querying all the data except for the resources)
And this is the moment when I add a resource to the query list. You can clearly see the spikes and the GC calls going crazy.
Closing my web browser has no effect. The lag spykes are still happening and the only way to go back to normal is restarting the game.
The text was updated successfully, but these errors were encountered: