Niels Zeilemaker
Niels Zeilemaker
@synctext seems like a great addition to the new website.
Its an inconsistency in the api, we should aim to correct it.
How many communities did you have in memory?
Could you start the wx inspectiontool (ctrl+i), and then in the console ``` for community in dispersy.get_communities(): print community.get_classification(), len(community.candidates) ```
And the output of the command I posted above?
The key is only bound in the debug panel, first go there
And ``` for community in dispersy.get_communities(): print community.get_classification(), len(community.request_cache._identifiers) ```
And after ``` import gc gc.collect() ```
Let's remove the communities one by one. Verify the memory usage afterwards ``` c = dispersy.get_communities()[0] c.unload_community() print "unloaded", c.get_classification() print "remaining" for community in dispersy.get_communities(): print community.get_classification() import gc...
``` from Tribler.dispersy.util import blocking_call_on_reactor_thread @blocking_call_on_reactor_thread def do_unload(): c = dispersy.get_communities()[0] c.unload_community() print "unloaded", c.get_classification() do_unload() print "remaining" for community in dispersy.get_communities(): print community.get_classification() import gc gc.collect() ```