After some investigation it looks like a simple call to apt.Cache() from the python apt module is responsible for the high memory usage of mintUpdate. Without this call mintUpdate uses 4.6MB of RAM. As soon as the module is called the memory usage grows to 47MB. The python interpreter doesn’t free up memory and an additional 47MB of RAM is reserved every time mintUpdate refreshes (every 5 minutes by default).

Of course mintUpdate relies on the apt module to get the list of available packages so we’ll need to find some decent solution to replace this call. Either we’ll manage to force python in freeing the memory used by the module or we’ll rely on APT directly without using the module.

Anyway, the next release of mintUpdate should use around 5MB of RAM and this shouldn’t grow over time.

Note: This comes as excellent news as I was personally worried that we would have to rewrite mintUpdate from scratch using another language. The java-gnome bindings lacked popularity and were not even packaged for Debian. Perl kind of scared me a bit when it came to OO-threaded development and I wasn’t particularly amused at the thought of using C++ (although I must say I was quite impressed with how Eclipse handles C++ and with the quality of the Gtkmm API). Well anyway, more on this later.. and hopefully we’ll stay with Python, at least for already existing Mint apps.

Edit: Apparently python won’t let us force any garbage collection. However the apt module can be replaced entirely by calls to “sudo apt-get -s upgrade | grep ^Inst” and “sudo apt-get -s dist-upgrade | grep ^Inst”. We’ll even save calculating dependencies ourselves…

Clem

BETA 044 should be released this week.

BETA 044 is out and available for download 🙂

A last minute innovation was added to mintMenu 3.1 just before it reached code-freeze.

You can now uninstall any application by right-clicking on them in mintMenu and by selecting “Uninstall”.

A little window appears to show you the corresponding package name and its dependencies. You can confirm or cancel, and that’s about it really…. the packages get removed.

For menu entries without a corresponding package, the window asks you if you want to get rid of the menu entry or not.

Steve Jobs was showing his new Apple Air at CES 2008. If we had the money let me tell you.. I’d be there in all these conventions making a lot of noise about this 🙂

Don’t you love it when things get easier? Many thanks for the people who posted about this and similar ideas in the suggestions section of the forums.

Clem