Commit graph

3690 commits

Author SHA1 Message Date
Antoine Pitrou
fc6acccbaf Remove outdated statements about threading and imports. 2012-05-18 13:57:04 +02:00
Antoine Pitrou
6c6d3a2f9f Move import lock-related functions to a separate doc section. 2012-05-17 19:00:35 +02:00
Antoine Pitrou
ea3eb88bca Issue #9260: A finer-grained import lock.
Most of the import sequence now uses per-module locks rather than the
global import lock, eliminating well-known issues with threads and imports.
2012-05-17 18:55:59 +02:00
R David Murray
dd95974509 #14823: Simplify threading.Lock.acquire argument discussion. 2012-05-17 09:14:28 -04:00
R David Murray
f7a6615719 #14823: Simplify threading.Lock.acquire argument discussion. 2012-05-17 09:13:30 -04:00
Antoine Pitrou
de9ac6c2e5 Issue #14780: urllib.request.urlopen() now has a cadefault argument to use the default certificate store.
Initial patch by James Oakley.
2012-05-16 21:40:01 +02:00
Hynek Schlawack
07542a0629 #14692 Fix json docs to reflect changes in json.load
The behaviour of the parse_constant callback changed insofar that 'null',
'true', 'false' don't trigger its call anymore.

Patch by Serhiy Storchaka
2012-05-16 19:08:36 +02:00
Hynek Schlawack
9729fd4427 #14692 Fix json docs to reflect changes in json.load
The behaviour of the parse_constant callback changed insofar that 'null',
'true', 'false' don't trigger its call anymore.

Patch by Serhiy Storchaka
2012-05-16 19:01:04 +02:00
Hynek Schlawack
51b2ed51f0 #14809: Add HTTP status codes from RFC 6585 to http.server and http.client
Patch by EungJun Yi.
2012-05-16 09:51:07 +02:00
R David Murray
a32df1e0e6 merge #1440472: reflow 2012-05-15 22:13:55 -04:00
R David Murray
28e68ea6ea #1440472: reflow 2012-05-15 22:13:29 -04:00
R David Murray
b3ad106dca merge #1440472: Explain that email parser/generator isn't *quite* "idempotent" 2012-05-15 22:09:14 -04:00
R David Murray
ea1badbfef #1440472: Explain that email parser/generator isn't *quite* "idempotent" 2012-05-15 22:07:52 -04:00
Charles-François Natali
9b704ec9e1 Add versionadded for hmac.secure_compare(). 2012-05-15 21:00:32 +02:00
Giampaolo Rodola'
0fb41b56ea remove unused import in asyncore doc 2012-05-15 15:46:00 +02:00
Giampaolo Rodola'
ffa1d0b8d5 #14807: move undocumented tarfile.filemode() to stat.filemode(). Add tarfile.filemode alias with deprecation warning. 2012-05-15 15:30:25 +02:00
Benjamin Peterson
d5a1c44455 PEP 415: Implement suppression of __context__ display with an exception attribute
This replaces the original PEP 409 implementation. See #14133.
2012-05-14 22:09:31 -07:00
R David Murray
d91dc62379 Merge #14766: Add correct algorithm for when a 'time' object is naive.
This patch also clarifies the definition of Naive and Aware.

Original patch by Greg Weller, I modified the first hunk
somewhat to make the exposition even clearer (I hope).
2012-05-14 22:19:10 -04:00
R David Murray
539f239e88 #14766: Reflow the altered paragraphs. 2012-05-14 22:17:23 -04:00
R David Murray
9075d8b771 #14766: Add correct algorithm for when a 'time' object is naive.
This patch also clarifies the definition of Naive and Aware.

Original patch by Greg Weller, I modified the first hunk
somewhat to make the exposition even clearer (I hope).
2012-05-14 22:14:46 -04:00
Antoine Pitrou
9a2349030a Issue #14417: Mutating a dict during lookup now restarts the lookup instead of raising a RuntimeError (undoes issue #14205). 2012-05-13 20:48:01 +02:00
Charles-François Natali
7feb9f4225 Issue #14532: Add a secure_compare() helper to the hmac module, to mitigate
timing attacks. Patch by Jon Oberheide.
2012-05-13 19:53:07 +02:00
Brett Cannon
d200bf534b Add importlib.util.resolve_name(). 2012-05-13 13:45:09 -04:00
Brett Cannon
62961dde31 Issue #13959: Document imp.find_module/load_module as deprecated.
The code itself does not raise a DeprecationWarning as the functions
are technically fine, it's just a bad API. Unfortunately experience
has shown that the terrible API has been exposed in various places,
necessitating that it stick around probably until py4k comes around
since it is such a shift to move over to importlib.find_loader().
2012-05-13 13:04:21 -04:00
Sandro Tosi
708d88c334 merge with 3.2 2012-05-13 11:01:36 +02:00
Sandro Tosi
3918b1ebfb Issue #14793: fix grammar in bytes object paragraph; patch by Tshepang Lekhonkhobe 2012-05-13 11:01:20 +02:00
Martin v. Löwis
7fb79fcb64 Issue #14366: Support lzma compression in zip files.
Patch by Serhiy Storchaka.
2012-05-13 10:06:36 +02:00
Brett Cannon
ee78a2b51c Issue #13959: Introduce importlib.find_loader().
The long-term goal is to deprecate imp.find_module() in favour of this
API, but it will take some time as some APIs explicitly return/use what
imp.find_module() returns.
2012-05-12 17:43:17 -04:00
Sandro Tosi
36c4e38f73 merge with 3.2 2012-05-12 23:30:05 +02:00
Sandro Tosi
38b86b4cf5 correctly define what 'fill' could be; thanks to Leland Hulbert from docs@ 2012-05-12 23:29:32 +02:00
Antoine Pitrou
424246fbf3 Issue #14082: shutil.copy2() now copies extended attributes, if possible.
Patch by Hynek Schlawack.
2012-05-12 19:02:01 +02:00
Brett Cannon
c049952de7 Issue #13959: Have
importlib.abc.FileLoader.load_module()/get_filename() and
importlib.machinery.ExtensionFileLoader.load_module() have their
single argument be optional as the loader's constructor has all the
ncessary information.

This allows for the deprecation of
imp.load_source()/load_compile()/load_package().
2012-05-11 14:48:41 -04:00
Brett Cannon
0c59b039b8 Deprecate the imp constants related to imp.get_suffixes(). 2012-05-11 14:27:29 -04:00
Brett Cannon
cb66eb0dec Issue #13959: Deprecate imp.get_suffixes() for new attributes on
importlib.machinery that provide the suffix details for import.
The attributes were not put on imp so as to compartmentalize
everything importlib needs for setting up imports in
importlib.machinery.

This also led to an indirect deprecation of inspect.getmoduleinfo() as
it directly returned imp.get_suffix's returned tuple which no longer
makes sense.
2012-05-11 12:58:42 -04:00
Richard Oudkerk
59d5404bc7 Issue #14753: Make multiprocessing treat negative timeouts as it did in 3.2
In Python 3.2 and earlier, Process.join() and Connection.poll()
treated negative timeouts as zero timeouts.  Earlier versions from
the 3.3 line of development treat them as infinite timeouts.

The patch reverts to the old behaviour.
2012-05-10 16:11:12 +01:00
Antoine Pitrou
fda08b0860 Some nits in the pickle docs. 2012-05-10 15:38:47 +02:00
Antoine Pitrou
a9494f6c53 Some nits in the pickle docs. 2012-05-10 15:38:30 +02:00
Ezio Melotti
fd7aaab184 #14763: merge with 3.2. 2012-05-10 15:33:13 +03:00
Ezio Melotti
bf3165b971 #14763: document default maxsplit value for str.split. 2012-05-10 15:30:42 +03:00
R David Murray
7ca8d1f748 Merge: Improve the grammar of a non-sentence. 2012-05-08 21:29:06 -04:00
R David Murray
b98b37f101 Improve the grammar of a non-sentence. 2012-05-08 21:28:24 -04:00
Nadeem Vawda
bc459bb484 Rename lzma.check_is_supported() to is_check_supported() to avoid grammatical confusion. 2012-05-06 23:01:51 +02:00
Nadeem Vawda
f55b329edc Add lzma.{encode,decode}_filter_properties(). 2012-05-06 23:01:27 +02:00
Ezio Melotti
df5bedbf88 #14034: merge argparse tutorial from 3.2. 2012-05-06 16:34:43 +03:00
Ezio Melotti
6cc7a41c2f #14034: added the argparse tutorial. Patch by Tshepang Lekhonkhobe. 2012-05-06 16:15:35 +03:00
Nadeem Vawda
7e126205e6 Closes #13989: Add support for text modes to gzip.open().
Also, add tests for gzip.open().
2012-05-06 15:04:01 +02:00
Lars Gustäbel
7a919e9930 Issue #13815: TarFile.extractfile() now returns io.BufferedReader objects.
The ExFileObject class was removed, some of its code went into _FileInFile.
2012-05-05 18:15:03 +02:00
Larry Hastings
76ad59b7e8 Issue #14127: Add ns= parameter to utime, futimes, and lutimes.
Removed futimens as it is now redundant.
Changed shutil.copystat to use st_atime_ns and st_mtime_ns from os.stat
and ns= parameter to utime--it once again preserves exact metadata on Linux!
2012-05-03 00:30:07 -07:00
Benjamin Peterson
49a69e4d48 strip is_ prefixes on clock_info fields 2012-05-01 09:38:34 -04:00
Georg Brandl
67c1444454 Update timeit documentation w.r.t default timer changes. 2012-05-01 11:59:36 +02:00