Page 1 of 1

[resolved] Python Framework - New Domoticz.Configure() API - memory leak

Posted: Tuesday 07 September 2021 17:57
by pipiche
I have made a small plugin, which is loading 217KB json file, converting it into a Dictionary and then saving with the Configure() method.

Then via the onHeartbeat,

I'm loading the dictionary from Configure()
incrementing a simple counter
saving it back with with Configure()

This is immediatly starting to consume memory without releasing it.

The fact to use a large data dictionary just speed up the process, but similar happens with a very short dictory

Here is the plugin

untar it on the plugins folder
move the file export.json to /tmp (or update the plugin.py , so it loads from somewhere else)
MemoryLeak.tar.bz2
(14.44 KiB) Downloaded 56 times

Re: [resolved] Python Framework - New Domoticz.Configure() API - memory leak

Posted: Thursday 09 September 2021 14:50
by pipiche
fixed with the latest beta version.

Re: [resolved] Python Framework - New Domoticz.Configure() API - memory leak

Posted: Friday 10 September 2021 8:44
by eddieb
thanks for this fix. running 13495 for 16 hours now and memory use is still under 90MB here !