Commit Graph

9685 Commits

Author SHA1 Message Date
Serhiy Storchaka 231aad3849
bpo-37315: Deprecate accepting floats in math.factorial(). (GH-14147) 2019-06-17 16:57:27 +03:00
Victor Stinner 8bf08ee45b
bpo-37312: Remove _dummy_thread and dummy_threading modules (GH-14143)
Remove _dummy_thread and dummy_threading modules. These modules
were deprecated since Python 3.7 which requires threading support.
2019-06-17 14:18:43 +02:00
Alex Gaynor 6ef4d323bd Update link in colorsys docs to be https (GH-14062) 2019-06-15 07:09:36 -07:00
Géry Ogam f475729a71 Update weakref.rst (GH-14098) 2019-06-15 04:33:23 -07:00
Victor Stinner 7efc526e5c
bpo-36707: Document "m" removal from sys.abiflags (GH-14090) 2019-06-15 03:24:41 +02:00
Victor Stinner 066e5b1a91
bpo-37266: Daemon threads are now denied in subinterpreters (GH-14049)
In a subinterpreter, spawning a daemon thread now raises an
exception. Daemon threads were never supported in subinterpreters.
Previously, the subinterpreter finalization crashed with a Pyton
fatal error if a daemon thread was still running.

* Add _thread._is_main_interpreter()
* threading.Thread.start() now raises RuntimeError if the thread is a
  daemon thread and the method is called from a subinterpreter.
* The _thread module now uses Argument Clinic for the new function.
* Use textwrap.dedent() in test_threading.SubinterpThreadingTests
2019-06-14 18:55:22 +02:00
Victor Stinner 212646cae6
bpo-37261: Document sys.unraisablehook corner cases (GH-14059)
Document reference cycle and resurrected objects issues in
sys.unraisablehook() and threading.excepthook() documentation.

Fix test.support.catch_unraisable_exception(): __exit__() no longer
ignores unraisable exceptions.

Fix test_io test_writer_close_error_on_close(): use a second
catch_unraisable_exception() to catch the BufferedWriter unraisable
exception.
2019-06-14 18:03:22 +02:00
Géry Ogam 431478d5d7 Update concurrent.futures.rst (GH-14061)
This PR adds missing details in the [`concurrent.futures`](https://docs.python.org/3/library/concurrent.futures.html) documentation:

* the mention that `Future.cancel` also returns `False` if the call finished running;
* the mention of the states for `Future` that did not complete: pending or running.
2019-06-14 07:39:43 -07:00
Michael Felt d0eeb936d8 bpo-37077: Add native thread ID (TID) for AIX (GH-13624)
This is the followup  for issue36084



https://bugs.python.org/issue37077
2019-06-13 15:34:46 -07:00
Makdon 95492032c4 bpo-6689: os.path.commonpath raises ValueError for different drives isn't documented (GH-14045)
It would raise ValueError("Paths don't have the same drive") if the paths on different drivers, which is not documented.


os.path.commonpath raises ValueError when the *paths* are in different drivers, but it is not documented.
Update the document according @Windsooon 's suggestion.
It actually raise ValueError according line 355 of [test of path](https://github.com/python/cpython/blob/master/Lib/test/test_ntpath.py) 


https://bugs.python.org/issue6689
2019-06-13 06:59:49 -07:00
Victor Stinner 6d22cc8e90
bpo-37261: Fix support.catch_unraisable_exception() (GH-14052)
The __exit__() method of test.support.catch_unraisable_exception
context manager now ignores unraisable exception raised when clearing
self.unraisable attribute.
2019-06-13 14:44:54 +02:00
David Carlier 5287022eee bpo-37160: Thread native ID NetBSD support (GH-13835) 2019-06-12 17:37:56 +02:00
Yao Zuo 405f648db7 bpo-32625: Updated documentation for EXTENDED_ARG. (GH-13985)
Python 3.6 changed the size of bytecode instruction, while the documentation for `EXTENDED_ARG` was not updated accordingly.
2019-06-12 06:46:09 +03:00
Guido van Rossum 10b55c1643 bpo-35766: Change format for feature_version to (major, minor) (GH-13992)
(A single int is still allowed, but undocumented.)



https://bugs.python.org/issue35766
2019-06-11 17:23:12 -07:00
Serhiy Storchaka e042a4553e
Do not use explicit inheritance from object in the documentation. (GH-13936) 2019-06-10 13:35:52 +03:00
Raymond Hettinger e119b3d136
bpo-37178: Allow a one argument form of math.perm() (GH-13905) 2019-06-08 08:58:11 -07:00
Pablo Galindo de76c07a8c
bpo-37134: Add PEP570 notation to the signature of byte{array}.translate (GH-13874) 2019-06-07 00:38:41 +01:00
Pablo Galindo c4c421d619
bpo-37134: Use PEP570 syntax for sum() (GH-13851) 2019-06-06 00:11:46 +01:00
Ashwin Ramaswami c4c15ed7a2 bpo-35551: encodings update (GH-11446) 2019-06-05 18:18:06 -04:00
Pablo Galindo 54edb04aa6 bpo-37134: Add PEP570 notation to the documentation (GH-13743) 2019-06-05 13:24:28 -07:00
Victor Stinner 1e77ab0a35
bpo-33725, multiprocessing doc: rephase warning against fork on macOS (GH-13841)
Co-Authored-By: Barry Warsaw <barry@python.org>
2019-06-05 21:59:33 +02:00
Serhiy Storchaka 142566c028
[3.9] bpo-37116: Use PEP 570 syntax for positional-only parameters. (GH-12620)
Turn deprecation warnings added in 3.8 into TypeError.
2019-06-05 18:22:31 +03:00
Victor Stinner ccf0efbb21 bpo-26836: Document os.memfd_create() name parameter (GH-13838)
https://bugs.python.org/issue26836
2019-06-05 03:24:52 -07:00
Benjamin Yeh d4cf099dff Fix documentation (GH-13721)
Based on the source code 4a686504eb/Lib/multiprocessing/pool.py (L755) AsyncResult.successful() raises a ValueError, not an AssertionError.
2019-06-05 02:08:04 -07:00
Abhilash Raj 46d88a1131 bpo-35805: Add parser for Message-ID email header. (GH-13397)
* bpo-35805: Add parser for Message-ID header.

This parser is based on the definition of Identification Fields from RFC 5322
Sec 3.6.4.

This should also prevent folding of Message-ID header using RFC 2047 encoded
words and hence fix bpo-35805.

* Prevent folding of non-ascii message-id headers.
* Add fold method to MsgID token to prevent folding.
2019-06-04 10:41:34 -07:00
Mario Corchero f0b5ae4567 bpo-30699: Improve example on datetime tzinfo instances (GH-4290)
* Improve example on tzinfo instances

Move from GMTX to TZX when naming the classes, as GMT1 might be rather
confusing as seen in the reported issue.
In addition, move to UTC over GMT and improve the tzname implementation.

* Simplify datetime with tzinfo example

Move the example in the documentation to just use timezone.utc and a
user defined Kabul timezone rather than having two user defined
timezones with DST.

Kabul timezone is still interesting as it changes its offset but not
based on DST. This is more accurate as the previous example was missing
information about the fold attribute. Additionally, implementing the fold
attribute was rather complex and probably not relevant enough for the
section "datetime with tzinfo".
2019-06-04 17:18:10 +02:00
Łukasz Langa 7f9a2ae780
Revert "bpo-34037, asyncio: add BaseEventLoop.wait_executor_on_close (GH-13786)" (#13802)
This reverts commit 0f0a30f4da.
2019-06-04 13:03:20 +02:00
Raymond Hettinger 8f4bbb5d62
Fix grammar (GH-13801) 2019-06-04 03:40:23 -07:00
Raymond Hettinger 963eb0f473
bpo-35431: Drop the k <= n requirement (GH-13798) 2019-06-04 01:23:06 -07:00
Victor Stinner 0f0a30f4da
bpo-34037, asyncio: add BaseEventLoop.wait_executor_on_close (GH-13786)
Add BaseEventLoop.wait_executor_on_close attribute: true by default.

loop.close() now waits for the default executor to finish by default.
Set loop.wait_executor_on_close attribute to False to not wait for
the executor.
2019-06-03 23:31:04 +02:00
Christian Heimes 78c7d52779
bpo-37120: Add SSLContext.num_tickets (GH-13719)
Signed-off-by: Christian Heimes <christian@python.org>
2019-06-03 21:00:10 +02:00
David Carlier 0b9956e916 bpo-37087: Adding native ID support for OpenBSD (GH-13654) 2019-06-03 17:43:33 +02:00
Julien Palard 141da44bb4
Doc fix: duplicate object description of email.message (GH-13742) 2019-06-03 17:17:03 +02:00
Matthias Bussonnier 13136e83a6 bpo-36896: Clarify that some types constructors are unstable (GH-13271) 2019-06-03 02:43:21 +02:00
Xtreak 0d70227e41 Fix typos in docs and docstrings (GH-13745) 2019-06-03 01:12:33 +02:00
Michele Angrisano e1179a5096 bpo-19184: Update the documentation of dis module. (GH-13652)
* bpo-19184: Update the documentation of dis module

* Explain the behavior of the number of arguments of RAISE_VARGARGS
  opcode.

* bpo-19184: Update blurb.

* bpo-19184: Fix typo in the dis Documentation.

* bpo-19184: Address review comments and improve the doc

* bpo-19184: Remove news file.
2019-06-02 23:34:12 +02:00
Michele Angrisano aca273e240 bpo-37014: Update docstring and Documentation of fileinput.FileInput(). (GH-13545)
* bpo-37014: Update docstring and Documentation of fileinput.FileInput()

* Explain the behavior of fileinput.FileInput() when reading stdin.

* Update blurb.

* bpo-37014: Fix typo in the docstring and documentation.
2019-06-02 23:01:49 +02:00
Mark Dickinson c52996785a
bpo-36027: Extend three-argument pow to negative second argument (GH-13266) 2019-06-02 10:24:06 +01:00
Serhiy Storchaka 5ae299ac78
bpo-37128: Add math.perm(). (GH-13731) 2019-06-02 11:16:49 +03:00
Anthony Sottile b7daabd711 Improve version added references in `typing` module docs (GH-13457) 2019-06-02 01:13:25 +01:00
Raymond Hettinger b7fade4f87
Put math.comb() docs is correct place alphabetically (GH-13734) 2019-06-01 15:01:46 -07:00
Serhiy Storchaka bdbad71b9d
bpo-20092. Use __index__ in constructors of int, float and complex. (GH-13108) 2019-06-02 00:05:48 +03:00
Evan 56624a99a9 bpo-28595: Allow shlex whitespace_split with punctuation_chars (GH-2071) 2019-06-01 20:09:22 +01:00
Serhiy Storchaka 2b843ac0ae
bpo-35431: Refactor math.comb() implementation. (GH-13725)
* Fixed some bugs.
* Added support for index-likes objects.
* Improved error messages.
* Cleaned up and optimized the code.
* Added more tests.
2019-06-01 22:09:02 +03:00
Anthony Shaw 059b9ea5ac bpo-31968: Documentation -- add clarification on the globals dict for exec() (GH-13140) 2019-06-01 08:51:58 -07:00
Stéphane Wirtel 66501058fe Doc: Correct the creation year and the credits of the Logo Programming language (GH-13520) 2019-06-01 07:41:33 -04:00
Serhiy Storchaka 70c5f2ae6e
Use more PEP 570 syntax in the documentation. (GH-13720) 2019-06-01 11:38:24 +03:00
Serhiy Storchaka 2085bd0877
bpo-37116: Use PEP 570 syntax for positional-only parameters. (GH-13700) 2019-06-01 11:00:15 +03:00
Yash Aggarwal 4a686504eb bpo-35431: Implemented math.comb (GH-11414) 2019-06-01 00:21:27 -07:00
Windson yang 5ac0b988fd bpo-18911: clarify that the minidom XML writer receives texts but not bytes (GH-13352) 2019-06-01 08:33:16 +02:00