Commit graph

18984 commits

Author SHA1 Message Date
Benjamin Peterson
01fc6cd056 make __doc__ mutable on heaptypes (closes #12773) 2011-08-17 12:03:47 -05:00
Benjamin Peterson
af3dcd2f98 improve test name 2011-08-17 11:48:23 -05:00
Benjamin Peterson
c4085c8470 complain when a class variable shadows a name in __slots__ (closes #12766) 2011-08-16 18:53:26 -05:00
Benjamin Peterson
51be6e0a0f merge heads 2011-08-16 17:46:44 -05:00
Benjamin Peterson
ae6ae025d1 some *nixes decided not to call init process 1 (closes #12763) 2011-08-16 17:46:04 -05:00
Ezio Melotti
67321cc9b0 #9723: refactor regex. 2011-08-16 19:03:41 +03:00
Ezio Melotti
269e3ee3db #12266: merge with 3.2. 2011-08-15 09:26:28 +03:00
Ezio Melotti
ee8d998ecf #12266: Fix str.capitalize() to correctly uppercase/lowercase titlecased and cased non-letter characters. 2011-08-15 09:09:57 +03:00
Antoine Pitrou
85674936c7 Monotonic, not monotonous 2011-08-14 01:51:52 +02:00
Antoine Pitrou
3c7e928098 Issue #12744: Fix inefficient representation of integers
between 2**31 and 2**63 on systems with a 64-bit C "long".
2011-08-13 20:15:19 +02:00
Nadeem Vawda
780199e6a3 Issue #12669: Fix test_curses so that it can run on the buildbots. 2011-08-13 15:43:49 +02:00
Nadeem Vawda
1c38546e49 Issue #12646: Add an 'eof' attribute to zlib.Decompress.
This will make it easier to detect truncated input streams.

Also, make zlib's error messages more consistent.
2011-08-13 15:22:40 +02:00
Georg Brandl
74b6abf61f Merge with 3.2. 2011-08-13 11:48:40 +02:00
Georg Brandl
3abb372c81 Fix #11513: wrong exception handling for the case that GzipFile itself raises an IOError. 2011-08-13 11:48:12 +02:00
Benjamin Peterson
3672c4e21f merge 3.2 2011-08-13 00:33:29 -05:00
Benjamin Peterson
963e40256a tokenize is just broken on test_pep3131.py 2011-08-13 00:33:21 -05:00
Benjamin Peterson
478267f9c4 merge 3.2 2011-08-12 23:35:46 -05:00
Benjamin Peterson
be66287e20 normalization is different between unicode builds, so use a new non-BMP char and add normalization test 2011-08-12 23:35:34 -05:00
Benjamin Peterson
f8e7543df9 merge 3.2 (#12732) 2011-08-12 22:18:19 -05:00
Benjamin Peterson
f413b80806 in narrow builds, make sure to test codepoints as identifier characters (closes #12732)
This fixes the use of Unicode identifiers outside the BMP in narrow builds.
2011-08-12 22:17:18 -05:00
Éric Araujo
a7e33a10ae Clean up test_shutil, to facilitate upcoming improvements (#12721).
The tests now have two convenience functions to wrap os.path.join, open
and read or write instead of four or six slightly different functions.
The new functions accept a tuple of path segments but not a list
anymore, as it makes no sense to use a list here; I have also removed
the default value for the contents in write_file, as I find it better to
have the contents at the call site.

For simple open then read/write calls, I have left the usual idiom (with
open + read/write), as it is short and readable enough.

I’ve also changed some convoluted cleanup code to just use rmtree, and
removed dubious LBYL os.path.exists checks.  The tests still pass on my
machine, and leave no file in $TMP.  test_shutil is not as clean as it
could be, but I’ll stop here.

Initial patch provided by Hynek Schlawack, in preparation for a new
feature with new tests in #12715.
2011-08-12 19:51:35 +02:00
Éric Araujo
14eba5fa41 Brench merge 2011-08-12 17:59:25 +02:00
Éric Araujo
28d39a0c08 Branch merge 2011-08-12 17:40:25 +02:00
Éric Araujo
4460abea64 Use our existing drop-in, no-op decorator instead of redefining it.
Patch by Francisco Martin Brugue.
2011-08-12 00:15:41 +02:00
Antoine Pitrou
fdf4a27422 Issue #12687: Fix a possible buffering bug when unpickling text mode (protocol 0, mostly) pickles. 2011-08-11 21:15:53 +02:00
Antoine Pitrou
f6c7a8595e Issue #12687: Fix a possible buffering bug when unpickling text mode (protocol 0, mostly) pickles. 2011-08-11 21:04:02 +02:00
Senthil Kumaran
5b0a4d22c5 merge from 3.2 2011-08-11 09:25:45 +08:00
Senthil Kumaran
962fed9101 Fix closes Issue10087 - fixing the output of calendar display in the html format. Patch by Chris Lambacher. Test Contributed by catherine. 2011-08-11 09:22:52 +08:00
Éric Araujo
cfcc9779fc Remove unused names in except clauses 2011-08-10 20:54:33 +02:00
Éric Araujo
25785e9ca5 Revert cosmetic change.
A reminder: distutils only gets bug fixes.  Cosmetic changes, especially
in tests, are not worth the time spent, and can even make future merges
of bugfixes a bit less easy.
2011-08-10 02:46:33 +02:00
Éric Araujo
7fc0394a12 Avoid unwanted behavior change in shlex.quote (see #9723).
I simplified the quote code to use a regex instead of a loop+test when I
moved pipes.quote to shlex in 5966eeb0457d; Ezio Melotti pointed out
that my regex contained redundant parts (now removed) and allowed
non-ASCII characters (now disallowed).

I think common UNIX shells don’t quote non-ASCII characters, but there’s
no harm in doing so.  We’ll see if users request a change.
2011-08-09 23:18:06 +02:00
Benjamin Peterson
71ce8970cf fix indentation 2011-08-09 16:17:12 -05:00
Benjamin Peterson
e451ec393f merge heads 2011-08-09 16:16:33 -05:00
Benjamin Peterson
832bfe2ebd add a AST validator (closes #12575) 2011-08-09 16:15:04 -05:00
Éric Araujo
ef1e94a848 Test pipes.quote with a few non-ASCII characters (see #9723).
That pipes.quote thinks all non-ASCII characters need to be quoted may
be a bug, but right now I’m committing this test to make sure I haven’t
introduced a behavior change in 3.3 when I simplified the code to use a
regex (in 5966eeb0457d).
2011-08-09 23:03:43 +02:00
Raymond Hettinger
fcb393c018 Add support for unary plus and unary minus to collections.Counter() 2011-08-09 13:00:40 -07:00
Éric Araujo
19272beec9 Branch merge 2011-08-09 18:01:52 +02:00
Victor Stinner
a8db378434 Issue #12700: fix test_faulthandler for Mac OS X Lion
Read from NULL raises SIGILL, not SIGSEGV, on Mac OS X Lion.
2011-08-08 22:43:45 +02:00
Éric Araujo
5c3f648c0c Branch merge 2011-08-08 16:56:17 +02:00
Éric Araujo
e4d5b8e646 Clean up shutil.disk_usage.
- Move a test from call time to define time
- Add the function name to __all__
- Improve docstring and docs

A few lines are now duplicated (named tuple definition and docstring)
but I think the end result reads better.
2011-08-08 16:51:11 +02:00
Sandro Tosi
c42a568cd4 #12677: merge with 3.2 2011-08-07 17:13:13 +02:00
Sandro Tosi
2a389e4601 #12677: correct turtle orientation in doc 2011-08-07 17:12:19 +02:00
Senthil Kumaran
0c8108914e merge from 3.2 - Fix closes issue12698 - make the no_proxy environment variable handling a bit lenient (accomodate spaces in between the items) 2011-08-06 12:28:16 +08:00
Senthil Kumaran
89976f1cdc Fix closes issue12698 - make the no_proxy environment variable handling a bit lenient (accomodate spaces in between the items) 2011-08-06 12:27:40 +08:00
Sandro Tosi
4dc9c84ed9 #11572: improvements to copy module tests along with removal of old test suite 2011-08-05 23:05:35 +02:00
Éric Araujo
29f6297605 Fix wrong use of root logger in packaging (also a NameError) 2011-08-04 17:17:07 +02:00
Ned Deily
2ef905d449 Issue #12540: Prevent zombie IDLE processes on Windows due to changes
in os.kill().  Original patch by Eli Bendersky.
2011-08-04 23:38:19 -07:00
Brett Cannon
252365bab8 Silence the altered state warning about threadgs when running test_httplib. 2011-08-04 22:43:11 -07:00
Brett Cannon
40ccea7e1e Silence altered execution state warnings from test_telnetlib involving threads. 2011-08-04 22:37:55 -07:00
Brett Cannon
a4265546f9 Explicitly close a file to stop raising a ResourceWarning. 2011-08-04 21:34:52 -07:00