WhistleMaster / tingbot-apps

Tingbot apps
8 stars 1 forks source link

memory leak in weather tingapp #4

Open davidudin opened 7 years ago

davidudin commented 7 years ago

If you leave the weather tingapp running for two or three days, it uses up all available memory and crashes the system. I can see the memory usage by watching the system with htop. No way of my telling if it's the weather tingapp directly or something it's using in the tingbot environment, of course.

I haven't seen this in other tingapps, but I haven't left more than one or two others running for days at a time.

joerick commented 7 years ago

Hi @davidudin, @WhistleMaster pointed me over here! We've been chatting about this memory leak issue too. I don't suppose you know any ways to debug memory leak issues in Python?

davidudin commented 7 years ago

Memory leaks are a bear. I haven't coded in Python other than a tweak here and there, nor am I familiar with any of its coding environments and tools, so I'm not much help there. I'd probably start by some brute force attempt to determine whether the leak was in the display end of things or in the data retrieval end by cutting out chunks of the application and seeing if the leak persisted. I'd do it myself, but I can't get Tide to install on linux Mint 17.3 (missing package). I'll try again when I install 18.1.

davidudin commented 7 years ago

Don't know Python much at all. I've been looking at the code a bit and might try things like changing the run rates individually to try to determine at least whether the leak is in retrieving the info from the weather web site or in formatting and displaying it. I was avoiding looking into it until I could run tide on my linux machine, but I upgraded to the latest linux mint and can now run it so long as I run it as root--I hope someone is looking into fixing that, too.

Cheers,

David

On Thu, Mar 2, 2017 at 4:32 AM, Joe Rickerby notifications@github.com wrote:

Hi @davidudin https://github.com/davidudin, @WhistleMaster https://github.com/WhistleMaster pointed me over here! We've been chatting about this memory leak issue too. I don't suppose you know any ways to debug memory leak issues in Python?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/WhistleMaster/tingbot-apps/issues/4#issuecomment-283603009, or mute the thread https://github.com/notifications/unsubscribe-auth/AJ3YCjiSMnUN1sEnUmG58bcx-eOiyjOxks5rhoy5gaJpZM4MP33O .