Neal Norwitz
22b3e3aff8
Ensure that the mailbox is closed to prevent problems on Windows with removing
...
an open file. This doesn't seem to be a problem in 2.6, but that appears
to be somewhat accidental (specific to reference counting). When this
gets merged to 3.0, it will make the 3.0 code simpler.
2008-03-26 05:19:41 +00:00
Jerry Seutter
14f0bc7900
Changed test so it no longer runs as a side effect of importing.
2008-03-26 05:03:03 +00:00
Neal Norwitz
85fc3c1f1c
Try to get this test to be less flaky. It was failing sometimes because
...
the connect would succeed before the timeout occurred. Try using an
address and port that hopefully doesn't exist to ensure we get no response.
If this doesn't work, we can use a public address close to python.org
and hopefully that address never gets taken.
2008-03-26 04:55:51 +00:00
Andrew M. Kuchling
7c29aaee88
Add various items
2008-03-26 00:30:02 +00:00
Andrew M. Kuchling
a8c3f2b6b6
Minor docstring typos
2008-03-26 00:16:50 +00:00
Benjamin Peterson
da868d6cf1
Opps! I merged the revisions, but forgot to add
...
the header to ACKS
2008-03-25 21:55:50 +00:00
Thomas Heller
fffd939056
Make _ctypes.c PY_SSIZE_T_CLEAN.
2008-03-25 21:18:39 +00:00
Benjamin Peterson
6f7e71dc32
Merged the ACKS from py3k
2008-03-25 21:14:42 +00:00
Mark Dickinson
8e85ffa4b2
Issue #2482 : Make sure that the coefficient of a Decimal
...
instance is always stored as a str instance, even
when that Decimal has been created from a unicode string.
2008-03-25 18:47:59 +00:00
Georg Brandl
cdde579fb9
Add Benjamin.
2008-03-25 17:36:43 +00:00
Mark Dickinson
3b24ccbe7e
Issue #2478 : Decimal(sqrt(0)) failed when the decimal context
...
was not explicitly supplied.
2008-03-25 14:33:23 +00:00
Georg Brandl
f8f1fbd53c
Move declarations to block start.
2008-03-25 11:59:51 +00:00
Georg Brandl
799b372f31
#2476 : document that %default feature is new in 2.4.
2008-03-25 08:39:10 +00:00
Georg Brandl
1e7c37514d
#2359 : add Py3k warning for array.read/array.write.
2008-03-25 08:37:23 +00:00
Georg Brandl
d65ab950c1
Fix tabs.
2008-03-25 08:31:32 +00:00
Georg Brandl
d5b635f196
Make Py3k warnings consistent w.r.t. punctuation; also respect the
...
EOL 80 limit and supply more alternatives in warning messages.
2008-03-25 08:29:14 +00:00
Georg Brandl
80055f6295
#2355 : py3k warning for buffer().
2008-03-25 07:56:27 +00:00
Gregory P. Smith
aef3e529e2
On platforms without zlib, make this do the right thing and return the python
...
2.x signed value. Also, don't waste space on a table full of unsigned longs
when all it needs are unsigned ints (incase anyone builds this without zlib on
a 64-bit unix for some strange reason).
tested by forcing it to compile this version on both 32-bit and 64-bit linux.
2008-03-25 07:46:07 +00:00
Gregory P. Smith
1fa588e14f
Use a 32-bit unsigned int here, a long is not needed.
2008-03-25 07:31:28 +00:00
Georg Brandl
18f1914a02
#868845 : document <...> reprs.
2008-03-25 07:20:15 +00:00
Neal Norwitz
bb89e686e3
Try to get this test to be more stable:
...
* disable gc during the test run because we are spawning objects and there
was an exception when calling Popen.__del__
* Always set an alarm handler so the process doesn't exit if the test fails
(should probably add assertions on the value of hndl_called in more places)
* Using a negative time causes Linux to treat it as zero, so disable that test.
2008-03-25 07:00:39 +00:00
Neal Norwitz
be9160b035
Don't try to close a non-open file.
...
Don't let file removal cause the test to fail.
2008-03-25 06:35:10 +00:00
Gregory P. Smith
88440960f9
A stab in the dark attempt to fix the alpha/tru64 buildbot problem and add more
...
test coverage of valid inputs to zlib.crc32.
2008-03-25 06:12:45 +00:00
Neal Norwitz
4677fbf7de
Try to fix a bunch of compiler warnings on Win64.
2008-03-25 04:18:18 +00:00
Neal Norwitz
40f5e4c5a2
Fix a bunch of UnboundLocalErrors when the tests fail.
2008-03-25 04:17:38 +00:00
Amaury Forgeot d'Arc
fac02faed8
Issue2469: Correct a typo I introduced at r61793: compilation error with UCS4 builds.
...
All buildbots compile with UCS2...
2008-03-24 21:04:10 +00:00
Christian Heimes
a113bd9f69
Added quick hack for bzr
2008-03-24 19:58:17 +00:00
Christian Heimes
6a453c3750
Added quick hack for bzr
2008-03-24 19:57:42 +00:00
Martin v. Löwis
b74d084da8
Conditionalize sys/time.h inclusion.
2008-03-24 13:54:23 +00:00
Martin v. Löwis
aef18b1c67
Patch #2240 : Implement signal.setitimer and signal.getitimer.
2008-03-24 13:31:16 +00:00
Martin v. Löwis
cdbc977c03
Install 2to3 script.
2008-03-24 12:57:53 +00:00
Georg Brandl
9bdead0aed
#1700821 : add a note to audioop docs about signedness of sample formats.
2008-03-24 09:34:34 +00:00
Raymond Hettinger
b72233ce63
Issue 2460: Make Ellipsis objects copyable.
2008-03-24 08:17:39 +00:00
Raymond Hettinger
d145240f9a
Tighten documentation for Random.triangular.
2008-03-24 06:07:49 +00:00
Martin v. Löwis
966d0e0930
Merged revisions 61724-61824 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/sandbox/trunk/2to3/lib2to3
........
r61730 | martin.v.loewis | 2008-03-22 02:20:58 +0100 (Sa, 22 Mär 2008) | 2 lines
More explicit relative imports.
........
r61755 | david.wolever | 2008-03-22 21:33:52 +0100 (Sa, 22 Mär 2008) | 1 line
Fixing #2446 -- 2to3 now translates 'import foo' to 'from . import foo'
........
r61824 | david.wolever | 2008-03-24 01:30:24 +0100 (Mo, 24 Mär 2008) | 3 lines
Fixed a bug where 'from itertools import izip' would return 'from itertools import'
........
2008-03-24 00:46:53 +00:00
Gregory P. Smith
440ca772f3
Have the binascii module use zlib's optimized crc32() function when available
...
to reduce our code size (1k data table and tiny bit of code). It falls back
to its own without zlib.
2008-03-24 00:08:01 +00:00
Gregory P. Smith
dd10284516
prevent a warning from the struct module when data size >= 2**32.
2008-03-23 23:45:12 +00:00
Gregory P. Smith
ac830e932d
A bugfix for r61813, it would fail if the data size was >=2**32.
2008-03-23 23:43:02 +00:00
Gregory P. Smith
be446b4ab7
replace calls to get the initial values with the raw constants.
2008-03-23 22:14:38 +00:00
Gregory P. Smith
79b4ba8fd7
Fix gzip to deal with CRC's being signed values in Python 2.x properly and to
...
read 32bit values as unsigned to start with rather than applying signedness
fixups allover the place afterwards.
This hopefully fixes the test_tarfile failure on the alpha/tru64 buildbot.
2008-03-23 21:04:43 +00:00
Gregory P. Smith
73f57b0c05
Revert r61779 - It undid correct code and caused test_zlib to fail on all
...
platforms with a 64-bit long.
The Alpha/Tru64 test problem is a problem in either tarfile or test_tarfile,
not zlib.
crc32 and adler32 return 32-bit values. by using a long thats larger than
32-bits in these functions they were prevented from wrapping around to their
signed 32-bit value that we want them to return in python 2.x.
2008-03-23 20:31:23 +00:00
Raymond Hettinger
c4f7bab0a0
Adopt Nick's suggestion for useful default arguments.
...
Clean-up floating point issues by adding true division and float constants.
2008-03-23 19:37:53 +00:00
Raymond Hettinger
bbc50eafe5
Issue 1681432: Add triangular distribution the random module.
2008-03-23 13:32:32 +00:00
Amaury Forgeot d'Arc
9a0d3462fc
#1477 : ur'\U0010FFFF' raised in narrow unicode builds.
...
Corrected the raw-unicode-escape codec to use UTF-16 surrogates in
this case, just like the unicode-escape codec.
2008-03-23 09:55:29 +00:00
Georg Brandl
61854332b9
Make the doctests presentation-friendlier.
2008-03-23 08:05:30 +00:00
Neal Norwitz
ade57d0485
Remove compiler warnings (on Alpha at least) about using chars as
...
array subscripts. Using chars are dangerous b/c they are signed
on some platforms and unsigned on others.
2008-03-23 06:19:57 +00:00
Neal Norwitz
acdb6fb2a5
Try to prevent the alarm going off early in tearDown
2008-03-23 06:16:04 +00:00
Neal Norwitz
0d2192be8b
Move itertools before future_builtins since the latter depends on the former.
...
From a clean build importing future_builtins would fail since itertools
wasn't built yet.
2008-03-23 06:13:25 +00:00
Neal Norwitz
41d649116c
Suppress failure (to avoid a flaky test) if we cannot connect to svn.python.org
2008-03-23 05:47:20 +00:00
Neal Norwitz
acbd6420e3
Fix test_tarfile failures on Alpha (Tru64). The problem was caused in r61449
...
which made the return value signed. On the Alpha that also lost data
since sizeof(int) != sizeof(long) and apparently adler32/crc32 return
64 bits of data. This change keeps the signedness and continues to store the
data in a long rather than an int as was the case before r61449.
2008-03-23 05:08:37 +00:00