[Python-Dev] MemoryError... how much memory?

Facundo Batista facundobatista at gmail.com
Thu Oct 28 13:14:54 CEST 2010

On Wed, Oct 27, 2010 at 8:27 PM, Nick Coghlan <ncoghlan at gmail.com> wrote:

> If you see MemoryError (5 bytes), the things you go looking for are
> very different from those you look for when you see MemoryError(1
> gajillion bytes). (i.e. for the former, you look for a memory or other
> resource leak, for the latter, you look for the reason your code is
> trying to get 1 gajillion bytes from the OS). If a long-lived server
> isn't crashing but is still getting MemoryError occasionally, problems
> with specific oversized requests are much more likely than a general
> resource leak (as those usually bring the whole process down
> eventually).

Very well explained, you're all right.

Furthermore, our server is fairly complex: we're using quite some
libraries to do different jobs, and one of the approaches (not the
only one) that we're taking to deal with this beast is to analyze its
memory-related behaviour from an external POV (thinking it as a black

So, beyond it's arguable utility, do you think that having that
information could harm us in some way?


.    Facundo

Blog: http://www.taniquetil.com.ar/plog/
PyAr: http://www.python.org/ar/

More information about the Python-Dev mailing list