2010/11/3 Victor Stinner <victor.stin...@haypocalc.com>: > Le mardi 02 novembre 2010 23:38:12, vous avez écrit : >> On Tue, Nov 2, 2010 at 10:55 PM, Victor Stinner >> >> <victor.stin...@haypocalc.com> wrote: >> > I don't know how to ignore the BytesWarning without importing warning. >> > How can I do that? >> >> I was suggesting trying to fix the bootstrap issue so you could use a >> top-level import, instead of working around it with a function level >> import (which we've learned from experience is a recipe for later >> reports from users of programs deadlocking on the import lock - we've >> made lots of improvement to avoid such deadlocks, but still prefer to >> avoid function level imports anyway). > > I don't know if there is a bootstrap issue. I'm using a local import because > os is always loaded at startup, and get_exec_path() is only used to run a > subprocess: os.exec*() and subprocess.Popen() (only the POSIX implementation). > I suppose that a top level "import warnings" would augment the memory > footprint.
Warnings is loaded every time anyway. -- Regards, Benjamin _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com