Commit Graph

22199 Commits

Author SHA1 Message Date
Victor Stinner d12e75734d
Revert "bpo-36084: Add native thread ID to threading.Thread objects (GH-11993)" (GH-13458)
This reverts commit 4959c33d25.
2019-05-21 12:44:57 +02:00
Xtreak e7cb23bf20 Fix RuntimeWarning in unittest.mock asyncio example (GH-13449)
* This PR fixes the `RuntimeWarning` in `inspect.isawaitable(mock())` where `mock()` was not awaited.
* Fix typo in asynctest project.
2019-05-21 01:47:17 -07:00
Matthias Bussonnier d0ebf13e50 bpo-36932: use proper deprecation-removed directive (GH-13349)
.. And update some deprecation warnings with version numbers.




https://bugs.python.org/issue36932
2019-05-20 23:20:10 -07:00
Andre Delfino 3099ae4075 Remove workaround for defaults in namedtuple now that we have the defaults parameter (GH-13263) 2019-05-20 20:52:17 -04:00
Cheryl Sabella 6220c02e09
bpo-35563: Add reference links to warnings.rst (GH-11289) 2019-05-20 18:45:05 -04:00
Matthias Bussonnier 1a3faf9d97 bpo-36952: Remove the bufsize parameter in fileinput.input(). (GH-13400)
This parameter is marked as deprecated since 3.6 and for removal in 3.8.
It already had no effects.
2019-05-20 23:44:11 +03:00
Thomas Moreau c09a9f56c0 bpo-36888: Add multiprocessing.parent_process() (GH-13247) 2019-05-20 21:37:05 +02:00
Lisa Roach 77b3b7701a
bpo-26467: Adds AsyncMock for asyncio Mock library support (GH-9296) 2019-05-20 09:19:53 -07:00
Geoff Shannon 522ccef869 bpo-22865: Expand on documentation for the pty.spawn function (GH-11980) 2019-05-20 17:06:16 +02:00
Terry Jan Reedy 6d965b39b7
bpo-36958: In IDLE, print exit message (GH-13435)
Print any argument other than None or int passed to SystemExit
or sys.exit().
2019-05-19 22:52:22 -04:00
Xtreak 287b84de93 bpo-34580: Update sqlite3 examples to call close() explicitly (GH-9079)
The sqlit3.Connection object doesn't call its close() method when it's used
as a context manager.
2019-05-20 00:52:20 +03:00
Boštjan Mejak 1d5bdef550 Orthographical fix (GH-13418)
Add a missing comma.
2019-05-19 02:01:36 -07:00
Jelle Zijlstra 9892f454d1 bpo-33519: clarify that .copy() is not part of the MutableSequence ABC (GH-6965) 2019-05-18 20:17:56 -04:00
Batuhan Taşkaya eab9965079 bpo-36567: Use manpages_url to create links for man pages (GH-13339) 2019-05-19 00:53:53 +03:00
Abhishek Kumar Singh 56027ccd6b bpo-19376: Added doc mentioning `datetime.strptime()` without a year fails for Feb 29. (GH-10243) 2019-05-18 16:36:19 -04:00
Raymond Hettinger e917f2ed9a
bpo-36546: Add more tests and expand docs (#13406) 2019-05-18 10:18:29 -07:00
Mark Dickinson 73934b9da0
bpo-36887: add math.isqrt (GH-13244)
* Add math.isqrt function computing the integer square root.

* Code cleanup: remove redundant comments, rename some variables.

* Tighten up code a bit more; use Py_XDECREF to simplify error handling.

* Update Modules/mathmodule.c

Co-Authored-By: Serhiy Storchaka <storchaka@gmail.com>

* Update Modules/mathmodule.c

Use real argument clinic type instead of an alias

Co-Authored-By: Serhiy Storchaka <storchaka@gmail.com>

* Add proof sketch

* Updates from review.

* Correct and expand documentation.

* Fix bad reference handling on error; make some variables block-local; other tidying.

* Style and consistency fixes.

* Add missing error check; don't try to DECREF a NULL a

* Simplify some error returns.

* Another two test cases:

- clarify that floats are rejected even if they happen to be
  squares of small integers
- TypeError beats ValueError for a negative float

* Documentation and markup improvements; thanks Serhiy for the suggestions!

* Cleaner Misc/NEWS entry wording.

* Clean up (with one fix) to the algorithm explanation and proof.
2019-05-18 12:29:50 +01:00
Toshio Kuratomi e7b1136ec3 Document a workaround for a curses bug (GH-13209) 2019-05-17 15:54:02 -07:00
Géry Ogam 51a860ee01 Correct typos in the Barrier specification (GH-9395) 2019-05-17 18:44:57 -04:00
redshiftzero f98c3c59c0 docs 36789: resolve incorrect note regarding UTF-8 (GH-13111) 2019-05-17 06:44:17 -04:00
Ned Batchelder 6faad355db bpo-36908: 'This module is always available' isn't helpful. (#13297)
Makes the documentation of math and cmath module
more helpful for the beginners.
2019-05-17 15:29:13 +05:30
Stéphane Wirtel cbb6484573 Doc: Replace the deprecated highlightlang directive by highlight. (#13377)
highlightlang is deprecated since April 2018 in Sphinx.
See https://github.com/sphinx-doc/sphinx/pull/4845
2019-05-17 15:25:34 +05:30
Stefan Hoelzl 245f528a92 Doc: Add link threading.settrace to sys.settrace (GH-13345) 2019-05-17 10:50:03 +02:00
Pablo Galindo aee19f54f6
bpo-36751: Undeprecate getfullargspec (GH-13245) 2019-05-16 21:08:15 +01:00
Andrew Svetlov 68b34a7204 bpo-36921: Deprecate @coroutine for sake of async def (GH-13346)
The second attempt. Now deprecate `@coroutine` only, keep `yield from fut` as is.


https://bugs.python.org/issue36921
2019-05-16 07:52:10 -07:00
Terry Jan Reedy 8a533ffb49
Fix typos in documentation. Patch by tirkarthi. (GH-13354) 2019-05-16 01:20:37 -04:00
Xtreak 9b5a0efcdc Fix typos in documentation (#13344) 2019-05-16 00:34:24 -04:00
‮zlohhcuB treboR d9e006bcef bpo-33123: pathlib: Add missing_ok parameter to Path.unlink (GH-6191)
Similarly to how several pathlib file creation functions have an "exists_ok" parameter, we should introduce "missing_ok" that makes removal functions not raise an exception when a file or directory is already absent.  IMHO, this should cover Path.unlink and Path.rmdir.  Note, Path.resolve() has a "strict" parameter since 3.6 that does the same thing. Naming this of this new parameter tries to be consistent with the "exists_ok" parameter as that is more explicit about what it does (as opposed to "strict").


https://bugs.python.org/issue33123
2019-05-15 15:02:11 -07:00
Antoine Pitrou 1a2dd82f56
bpo-36786: Run compileall in parallel during "make install" (GH-13078) 2019-05-15 23:45:18 +02:00
Jon Janzen c981ad16b0 bpo-26707: Enable plistlib to read UID keys. (GH-12153)
Plistlib currently throws an exception when asked to decode a valid
.plist file that was generated by Apple's NSKeyedArchiver. Specifically,
this is caused by a byte 0x80 (signifying a UID) not being understood.

This fixes the problem by enabling the binary plist reader and writer
to read and write plistlib.UID objects.
2019-05-15 23:14:38 +03:00
Xtreak e307e5cd06 Reference zipimport source code from docs. (GH-13310) 2019-05-15 19:18:35 +03:00
Yavor Konstantinov 133fc89ca0 bpo-36799: Fix typo in ctypes.rst (GH-13104) 2019-05-15 17:02:13 +02:00
Gregory P. Smith e883091abf
bpo-36760: Clarify subprocess capture_output docs. (GH-13322)
Clarify how to capture stdout and stderr combined into one stream.
2019-05-14 12:33:17 -07:00
Vinodhini Balusamy c0a1a07c7e bpo-32995 - Added context variable in glossary (GH-9741) 2019-05-14 08:11:41 -04:00
Nick Coghlan dae1229729
bpo-36797: Prune more legacy distutils documentation (GH-13092)
Removes more legacy distutils documentation, and more clearly
marks what is left as potentially outdated, with references to
setuptools as a replacement.
2019-05-14 22:04:30 +10:00
Stéphane Wirtel 0a52d73dde Doc: Update pip and setuptools when creating the virtual environment (GH-13307)
Add a new pip install before `sphinx` etc.. because we should use the last version of `pip` and `setuptools`
2019-05-14 04:49:49 -07:00
wim glenn 1a10a6b980 Simplify the ``LastUpdatedOrderedDict`` example recipe (GH-13296) 2019-05-13 18:10:13 -07:00
Anders Hovmöller 8da5ebe11e bpo-35138: Added an example for timeit.timeit with callable arguments (GH-9787)
* Update timeit.rst
2019-05-13 21:27:17 +02:00
Matthias Bussonnier b6a09ae287 bpo-36895: Undocument removed time.clock (GH-13286) 2019-05-13 21:23:07 +02:00
Brad be6939fb02 Docs: Add bz2 usage examples (GH-13258)
* Docs: Add bz2 usage examples

- Adds an "Examples of usage" section inspired by the one
  found in the gzip docs
- Corrects the descriptions for ``compresslevel`` and ``data``:
    - ``compresslevel`` must be an `int`, not any number.  For
      instance, passing a float will raise ``TypeError``
    - Notes that `data` must be bytes-like
2019-05-13 11:09:49 -07:00
Pierre Glaser 50466c6650 bpo-36867: DOC update multiprocessing.rst (GH-13289)
Followup to bpo-36867.
2019-05-13 19:20:48 +02:00
Victor Stinner c1f7262f70
bpo-36728: Remove PyEval_ReInitThreads documentation (GH-13282) 2019-05-13 16:22:51 +02:00
divyag9 778a910758 bpo-34682: Wording and grammatical changes to the doc(https://docs.python.org/3) (GH-13120)
https://bugs.python.org/issue34682
2019-05-13 06:05:20 -07:00
Utkarsh Gupta 3e2afd78ba bpo-36008: Doc update for 3.8 migration (GH-12887) 2019-05-13 08:29:39 -04:00
Kexuan Sun 32d1458b2e Changes to the documentation of normcase (GH-4725) 2019-05-13 07:38:20 -04:00
Victor Stinner d5d9e81ce9
bpo-36728: Remove PyEval_ReInitThreads() from C API (GH-13241)
Remove the PyEval_ReInitThreads() function from the Python C API.
It should not be called explicitly: use PyOS_AfterFork_Child()
instead.

Rename PyEval_ReInitThreads() to _PyEval_ReInitThreads() and add a
'runtime' parameter.
2019-05-13 12:35:37 +02:00
Victor Stinner 3aef48e315
bpo-36778: Update cp65001 codec documentation (GH-13240)
Remove cp65001 from the codecs table, list it as an alias of utf_8
and add a versionchanged markup.
2019-05-13 10:42:31 +02:00
Zackery Spytz cf599f6f6f bpo-6584: Add a BadGzipFile exception to the gzip module. (GH-13022)
Co-Authored-By: Filip Gruszczyński <gruszczy@gmail.com>
Co-Authored-By: Michele Orrù <maker@tumbolandia.net>
2019-05-13 10:50:52 +03:00
Edison A d28772ab69 bpo-36783: Add new references for C API Documentation changes (GH-13204) 2019-05-13 09:23:38 +02:00
Johnny Gérard 4ef9b8e505 Correct misspelling (GH-11470) 2019-05-12 23:39:32 -04:00