Commit Graph

9 Commits

Author SHA1 Message Date
Raymond Hettinger a9ef5e565d SF bug #1083202L UnboundLocalError raised by atexit module
The sys module could be called before being imported.
2004-12-11 02:49:40 +00:00
Skip Montanaro 599bd5e1e1 Fix bug 1052242. Also includes rewrite of test case using unittest and
avoiding use of popen.
2004-11-04 04:31:30 +00:00
Walter Dörwald 70a6b49821 Replace backticks with repr() or "%r"
From SF patch #852334.
2004-02-12 17:35:32 +00:00
Guido van Rossum 68468eba63 Get rid of many apply() calls. 2003-02-27 20:14:51 +00:00
Tim Peters 012b69cb30 The atexit module effectively turned itself off if sys.exitfunc already
existed at the time atexit first got imported.  That's a bug, and this
fixes it.

Also reworked test_atexit.py to test for this too, and to stop using
an "expected output" file, and to test what actually happens at exit
instead of just simulating what it thinks atexit will do at exit.

Bugfix candidate, but it's messy so I'll backport to 2.2 myself.
2002-07-16 19:30:59 +00:00
Tim Peters 384fd106e8 Bug #128475: mimetools.encode (sometimes) fails when called from a thread.
pythonrun.c:  In Py_Finalize, don't reset the initialized flag until after
the exit funcs have run.
atexit.py:  in _run_exitfuncs, mutate the list of pending calls in a
threadsafe way.  This wasn't a contributor to bug 128475, it just burned
my eyeballs when looking at that bug.
2001-01-21 03:40:37 +00:00
Skip Montanaro e99d5ea25b added __all__ lists to a number of Python modules
added test script and expected output file as well
this closes patch 103297.
__all__ attributes will be added to other modules without first submitting
a patch, just adding the necessary line to the test script to verify
more-or-less correct implementation.
2001-01-20 19:54:20 +00:00
Tim Peters 146965abf2 Whitespace standardization. 2001-01-14 18:09:23 +00:00
Fred Drake c19425d520 Added the atexit module and documentation from Skip Montanaro
<skip@mojam.com>.  Revisions to the markup to make it pass LaTeX, added
an index entry and a reference from the sys.exitfunc documentation.

This closes SourceForge patch #100620.
2000-06-28 15:07:31 +00:00