Alexander Belopolsky
c142bba2a7
Issue #1667546 : On platforms supporting tm_zone and tm_gmtoff fields
...
in struct tm, time.struct_time objects returned by time.gmtime(),
time.localtime() and time.strptime() functions now have tm_zone and
tm_gmtoff attributes. Original patch by Paul Boddie.
2012-06-13 22:15:26 -04:00
Sandro Tosi
f6a899fe6d
Issue #15060 : merge with 3.2
2012-06-14 00:37:25 +02:00
Sandro Tosi
27b130e702
Issue #15060 : better fix, thanks to review on #python-dev
2012-06-14 00:37:09 +02:00
Sandro Tosi
9994b096d1
Issue #15060 : merge with 3.2
2012-06-13 23:59:21 +02:00
Sandro Tosi
56692f5722
Issue #15060 : fix typo in socket doc; Patch by anatoly techtonik
2012-06-13 23:58:54 +02:00
Victor Stinner
6222d76952
Fix test_time for adjusted/adjustable changes
2012-06-12 23:04:11 +02:00
Victor Stinner
2b89fdf7eb
PEP 418: Rename adjusted attribute to adjustable in time.get_clock_info() result
...
Fix also its value on Windows and Linux according to its documentation:
"adjustable" indicates if the clock *can be* adjusted, not if it is or was
adjusted.
In most cases, it is not possible to indicate if a clock is or was adjusted.
2012-06-12 22:46:37 +02:00
Victor Stinner
bda4b8802c
time.get_clock_info() uses a namespace instead of structseq
2012-06-12 22:11:44 +02:00
Alexander Belopolsky
d9738242f8
Fixed a typo in time_localtime()
2012-06-12 16:14:17 -04:00
Stefan Krah
b7832939c7
1) Fix signature of _mpd_qpow_uint(): contrary to the comment base is constant.
...
2) Abort the loop for all specials, not only infinity.
3) Make the function more general and distinguish between zero clamping
and folding down the exponent. The latter case is currently handled
by setting context->clamp to 0 before calling the function.
2012-06-12 21:06:06 +02:00
Richard Oudkerk
f0604fddc3
Issue #3518 : Remove references to non-existent BaseManager.from_address()
...
method
2012-06-11 17:56:08 +01:00
Brett Cannon
99d776fdf4
Update importlib.h by touching Lib/importlib/_bootstrap.py.
2012-06-11 11:02:53 -04:00
Brett Cannon
7b383c431a
Make a test easier to read.
2012-06-11 11:02:36 -04:00
Richard Oudkerk
839a482a11
Dummy merge
2012-06-11 15:16:56 +01:00
Richard Oudkerk
197651b4e3
Issue #10133 : Make multiprocessing deallocate buffer if socket read fails.
...
Patch by Hallvard B Furuseth.
2012-06-11 15:12:12 +01:00
Nick Coghlan
4fae8cdaea
Close #13857 : Added textwrap.indent() function (initial patch by Ezra
...
Berch)
2012-06-11 23:07:51 +10:00
Raymond Hettinger
3c4acd8bf9
merge
2012-06-11 00:42:17 -07:00
Raymond Hettinger
6fed9fdf22
Fix indentation of method and attribute examples.
2012-06-11 00:38:14 -07:00
Stefan Krah
88e19779ad
1) Replace long-winded abort() construct by assert().
...
2) Remove micro optimization (inline checking for NaN before calling
mpd_qcheck_nans()) that probably has no benefit in this case.
2012-06-11 08:57:17 +02:00
Brian Quinlan
a26ad5a0a1
#15015 : Fix accessing an non-existing attribute.
2012-06-11 12:59:07 +10:00
Michael Foord
911fd327f1
unittest.mock minor doc update
2012-06-10 20:38:54 +01:00
Michael Foord
f7c4158057
Adding patch.stopall method to unittest.mock
2012-06-10 20:36:32 +01:00
Raymond Hettinger
bfcb42936b
Expand examples for ChainMap(). Improve markup.
2012-06-10 11:39:44 -07:00
Stefan Krah
9253862f45
1) State restrictions for the transform length.
...
2) Switch argument order to match the function signature of mpd_calloc()
(cosmetic change, since the order is irrelevant).
2012-06-10 16:50:55 +02:00
Raymond Hettinger
1c2018c311
Small cleanup and optimization
2012-06-09 22:51:39 -07:00
Raymond Hettinger
7929cfb18c
Note that the _asdict() method is outdated
2012-06-09 19:15:26 -07:00
Raymond Hettinger
80ed4d4774
Minor reformatting (wrap fat lines, etc.) and create an __main__ file
2012-06-09 18:46:45 -07:00
Michael Foord
75963643b1
Fix exception when calling reset_mock on a mock created with autospec
2012-06-09 17:31:59 +01:00
Stefan Krah
afc0c77b42
Add one extra comparison to the _mpd_shortmul() case to avoid repetitive code.
2012-06-09 15:28:36 +02:00
R David Murray
6e50b699ac
Now that Defects are Exception subclasses, call super.
...
The behavior of MessageDefect is legacy behavior. The chances anyone is
actually using the undocumented 'line' attribute is low, but it costs
little to retain backward compatibility. Although one of the costs is
having to restore normal exception behavior in HeaderDefect. On the
other hand, I'll probably add some specialized behavior there later.
2012-06-08 22:45:46 -04:00
Stefan Krah
5248a2d3c1
Enumerate all cases in the overflow detection strategy in mpd_qlog10().
2012-06-09 00:01:28 +02:00
Alexander Belopolsky
f6f56183ee
Relax datetime.timestamp() test around DST change
2012-06-08 13:00:27 -04:00
Alexander Belopolsky
0c687e5e88
Relax datetime.timestamp() test around DST change
2012-06-08 12:58:31 -04:00
Stefan Krah
0bf506cca5
Merge.
2012-06-08 18:55:22 +02:00
Stefan Krah
1cf6dfc8b2
1) List relative error for _mpd_qln10().
...
2) Add rigorous error analysis to _mpd_qlog10 (ACL2 proofs exist).
3) Use the relative error as a basis for the interval generation in the
correction loop (same as in _mpd_qln()).
2012-06-08 18:41:33 +02:00
Alexander Belopolsky
a4415141da
Issue #2736 : Added datetime.timestamp() method.
2012-06-08 12:33:09 -04:00
Hynek Schlawack
ed36b2e55b
#14814 : Remove redundant code from ipaddress.IPv6Network
...
The strict checks and netmask computing don't make sense if constructed with
a ALL_ONES mask based on addresses. Also fix a bug due to mis-indentation of
a return statement in the same code block.
2012-06-08 15:21:21 +02:00
Terry Jan Reedy
571ee57695
Merge from 3.2, #12510
2012-06-07 20:04:17 -04:00
Terry Jan Reedy
2a2ce4f673
Issue #12510 : Revise and triple # of calltip tests, with an eye to unittest
...
use. Make the get_entity 'method' a module function as it did not use 'self'.
Delete buggy _find_constructor function that is not needed, at least in 3.x.
Revise get_argspec so all tests pass. Add and fix NEWS entries.
2012-06-07 19:41:04 -04:00
Richard Oudkerk
58ba47f97b
Merge fixes for #13854 and #12157 .
2012-06-07 20:38:11 +01:00
Alexander Belopolsky
74482201b8
Issue #11823 : disassembly now shows argument counts on calls with keyword args
2012-06-07 14:28:14 -04:00
Stefan Krah
7bda265662
1) The overflow detection in mpd_qln() has a surprising number of case splits.
...
List all of them in the comment.
2) Use the recently stated relative error of _mpd_qln() to generate the
interval for the exact value of ln(x). See also the comment in mpd_qexp().
2012-06-07 17:48:47 +02:00
Nick Coghlan
cbc203e655
Merge from 3.2
2012-06-07 22:42:29 +10:00
Nick Coghlan
a3a164a03c
Nudge readers towards a more accurate mental model for loop else clauses
2012-06-07 22:41:34 +10:00
Kristján Valur Jónsson
55e5dc8371
Rearrange code to beat an optimizer bug affecting Release x64 on windows
...
with VS2010sp1
2012-06-06 21:58:08 +00:00
Richard Oudkerk
29471de459
Issue #13854 : Properly handle non-integer, non-string arg to SystemExit
...
Previously multiprocessing only expected int or str. It also wrongly
used an exit code of 1 when the argument was a string instead of zero.
2012-06-06 19:04:57 +01:00
Richard Oudkerk
e41682b994
Issue #12157 : pool.map() does not handle empty iterable correctly
...
Initial patch by mouad
2012-06-06 19:04:57 +01:00
Stefan Krah
a3394bce33
1) Add error analysis comments to mpd_qln10() and _mpd_qln().
...
2) Simplify the precision adjustment code for values in [0.900, 1.15].
2012-06-06 15:57:18 +02:00
Victor Stinner
a01f1adb87
Close #6203 : Document that Python 3 sets LC_CTYPE at startup to the user's preferred locale encoding
2012-06-06 01:37:37 +02:00
Kristján Valur Jónsson
187aa54516
Signal condition variables with the mutex held. Destroy condition variables
...
before their mutexes.
2012-06-05 22:17:42 +00:00