Commit Graph

24019 Commits

Author SHA1 Message Date
Terry Jan Reedy 2827e8a177
bpo-43283: Add IDLE doc paragraph about print speed (GH-24615)
Printing to IDLE's Shell is often slower than printing to a system
terminal, but it can be made faster by pre-formatting a single
string before printing.
2021-02-23 19:39:51 -05:00
Inada Naoki 2d6f2eed14
bpo-36346: Document removal schedule of deprecate APIs (GH-20879)
We will remove wstr cache in Python 3.12. See PEP 623.
2021-02-23 08:06:51 +09:00
Inada Naoki 5a4aa4c03e
bpo-23882: Doc: Clarify unittest discovery document (GH-21560)
Unittest discovery support namespace package as start
directory. But it doesn't find namespace package in
the start directory automatically.

Otherwise, unittest discovery search into unexpected
directories like `vendor/` or `node_modules/`.
2021-02-22 15:14:26 +09:00
Terry Jan Reedy 4cf7bb8e22
bpo-43283: Rearrange some IDLE doc paragraphs. (GH-24604)
In the Running User Code section, gather together paragraphs about two
processes and the sys.stdstream replacements, preparing to add another.
2021-02-21 02:44:11 -05:00
Terry Jan Reedy 2f9ef514fb
bpo-27646: Say that 'yield from' expression can be any iterable (GH-24595)
Previously, the doc at least strongly implied that it had to be an iterator.
2021-02-20 21:33:25 -05:00
Pablo Galindo d439fb304c
bpo-43277: Add PySet_CheckExact to the C-API (GH-24598)
For some mysterious reason we have PySet_Check, PyFrozenSet_Check, PyAnySet_Check, PyAnySet_CheckExact and PyFrozenSet_CheckExact but no PySet_CheckExact.
2021-02-20 18:03:08 +00:00
Victor Stinner 46496f9d12
bpo-42990: Functions inherit current builtins (GH-24564)
The types.FunctionType constructor now inherits the current builtins
if the globals dictionary has no "__builtins__" key, rather than
using {"None": None} as builtins: same behavior as eval() and exec()
functions.

Defining a function with "def function(...): ..." in Python is not
affected, globals cannot be overriden with this syntax: it also
inherits the current builtins.

PyFrame_New(), PyEval_EvalCode(), PyEval_EvalCodeEx(),
PyFunction_New() and PyFunction_NewWithQualName() now inherits the
current builtins namespace if the globals dictionary has no
"__builtins__" key.

* Add _PyEval_GetBuiltins() function.
* _PyEval_BuiltinsFromGlobals() now uses _PyEval_GetBuiltins() if
  builtins cannot be found in globals.
* Add tstate parameter to _PyEval_BuiltinsFromGlobals().
2021-02-20 15:17:18 +01:00
Irit Katriel 292f23186c
Fix typo in dis module doc (GH-24509) 2021-02-20 09:52:37 +05:30
Terry Jan Reedy b30fcba3a8
bpo-43042: Augment tutorial sentence (GH-24514)
Calling same function also gets new local namespace.
2021-02-19 19:26:21 -05:00
Erlend Egeberg Aasland 2d3e463e4a
closes bpo-43266: Improve array formatting. (GH-24573) 2021-02-19 09:32:31 -06:00
Nicholas Sim 4a6bf276ed
bpo-35134: Move non-limited C API files to Include/cpython/ (GH-24561)
Include/{odictobject.h,parser_interface.h,picklebufobject.h,pydebug.h,pyfpe.h}
into Include/cpython/.

Parser: peg_api: include Python.h instead of parser_interface.h.
2021-02-19 15:55:46 +01:00
Erlend Egeberg Aasland e92d67dfbb
closes bpo-43254: Fix *snprintf() man page refs. (GH-24563) 2021-02-18 19:53:33 -06:00
Jeremy Paige 743932d508
Remove all links to mingw.org (GH-24552)
This lease on this domain has lapsed. This not only makes these dead links, but a potential attack vector for readers of python.org as the domain can be obtained by an untrustworthy party.


I considered redirecting these links to http://mingw-w64.org/ which is a maintained fork of mingw, but beyond my unfamiliarity with the exact level of compatibility, at the time of this PR that site had an expired cert and so is not much of a vulnerability fix.

Automerge-Triggered-By: GH:Mariatta
2021-02-18 11:43:35 -08:00
Victor Stinner 44085a3fc9
bpo-42990: Refactor _PyFrame_New_NoTrack() (GH-24566)
* Refactor _PyFrame_New_NoTrack() and PyFunction_NewWithQualName()
  code.
* PyFrame_New() checks for _PyEval_BuiltinsFromGlobals() failure.
* Fix a ref leak in _PyEval_BuiltinsFromGlobals() error path.
* Complete PyFunction_GetModule() documentation: it returns a
  borrowed reference and it can return NULL.
* Move _PyEval_BuiltinsFromGlobals() definition to the internal C
  API.
* PyFunction_NewWithQualName() uses _Py_IDENTIFIER() API for the
  "__name__" string to make it compatible with subinterpreters.
2021-02-18 19:20:16 +01:00
David CARLIER 7be00ee64a
bpo-42960: Add resource.RLIMIT_KQUEUES constant from FreeBSD (GH-24251) 2021-02-18 16:26:20 +01:00
Victor Stinner a3c3ffa68e
bpo-42990: Add __builtins__ attribute to functions (GH-24559)
Expose the new PyFunctionObject.func_builtins member in Python as a
new __builtins__ attribute on functions.

Document also the behavior change in What's New in Python 3.10.
2021-02-18 12:35:37 +01:00
Victor Stinner 801bb0b503
bpo-43103: Add configure --without-static-libpython (GH-24418)
Add a new configure --without-static-libpython option to not build
the libpythonMAJOR.MINOR.a static library and not install the
python.o object file.

Fix smelly.py and stable_abi.py tools when libpython3.10.a is
missing.
2021-02-17 11:14:42 +01:00
Erlend Egeberg Aasland cc54001c2e
bpo-40170: Always define PyIter_Check() as a function (GH-24548) 2021-02-16 16:05:58 +01:00
Erlend Egeberg Aasland 871eb4237b
bpo-40170: Convert PyDescr_IsData() to static inline function (GH-24535) 2021-02-16 08:50:00 +01:00
Pablo Galindo 813db24f7c
Add a warning block around the get_referrers() documentation (GH-24511) 2021-02-15 23:03:38 +00:00
Ken Jin a2f0654b0a
bpo-42967: Fix urllib.parse docs and make logic clearer (GH-24536) 2021-02-15 09:00:20 -08:00
Erlend Egeberg Aasland 4bb2a1ebc5
bpo-43181: Convert PyObject_TypeCheck to static inline function (GH-24533) 2021-02-15 17:19:24 +01:00
Adam Goldschmidt fcbe0cb04d
bpo-42967: only use '&' as a query string separator (#24297)
bpo-42967: [security] Address a web cache-poisoning issue reported in urllib.parse.parse_qsl().

urllib.parse will only us "&" as query string separator by default instead of both ";" and "&" as allowed in earlier versions. An optional argument seperator with default value "&" is added to specify the separator.


Co-authored-by: Éric Araujo <merwok@netwok.org>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Co-authored-by: Éric Araujo <merwok@netwok.org>
2021-02-14 14:41:57 -08:00
Zackery Spytz 762fe7deed
bpo-43200: Fix link to shutil.copy() in the shutil doc (GH-24505)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2021-02-12 23:57:12 -05:00
Gregory P. Smith fd053fdd39
bpo-43172: readline now passes its tests when built against libedit (GH-24499)
bpo-43172: readline now passes its tests when built against libedit.

Existing irreconcilable API differences remain in readline.get_begidx
and readline.get_endidx behavior based on libreadline vs libedit use.
A note about that has been documented.
2021-02-12 12:04:46 -08:00
Tom Forbes 749d40a53f
Fix link to sqlite3 enable_shared_cache documentation (GH-24496) 2021-02-10 19:56:16 +02:00
Ken Jin da21f7b6e1
bpo-41824: Add versionadded for typing.ForwardRef docs (#24224) 2021-02-08 17:58:50 -08:00
Ken Jin 5f77dee056
Improve docs of PEP 604 Union (#24301) 2021-02-08 17:57:11 -08:00
Raymond Hettinger 30a8b28396
bpo-43147: Remove archaic terminology. (GH-24462) 2021-02-07 16:44:42 -08:00
Terry Jan Reedy 0ec57e25c9
bpo-16781: In 'exec' doc, add 'nonlocal' to 'yield' and 'return' (GH-2446)
These 3 statements cannot be used at module scope -- nor in exec with one namespace.
2021-02-07 00:28:50 -05:00
Andrew Tennikoff 5f18c22339
Simple typo fix (GH-24448) 2021-02-05 10:17:01 -08:00
Raymond Hettinger 755c6e637a
Minor readability improvements. Also note performance impact of __slots__. (GH-24456) 2021-02-04 22:05:42 -08:00
Dong-hee Na f917c243c5
bpo-43106: Add os.O_EVTONLY/O_FSYNC/O_SYMLINK/O_NOFOLLOW_ANY (GH-24428) 2021-02-04 08:32:55 +09:00
Pablo Galindo 8d998f140e Python 3.10.0a5
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEz9yiRbEEPPKl+Xhl/+h0BBaL2EcFAmAZufEACgkQ/+h0BBaL
 2EeK0BAAsOwjU6I7Rqg6qOIVaOmTS/WuZIvGFPb8sP6AXFrHSsjU4o93ekn+fsQe
 qYqrOEDwKHLDT4hLKOMohJBzX++Y4o/yUYqgg+HTeHgBV0f6zMVJcC8PuMsxzWfC
 /tjgUZRjgC6v7yN8KTHrslC2me1ayN9hJHMB4MKwvnTsmekWLauqaQJ7KEedfaQa
 lcDUf8ceu7t/riPZQFnoo6jdlt1A83pmGpLw05I/BEOiNktiow3f8fEDTQ0bkDdZ
 FC8RGGXoSVtwE2+O0w0j0LiHOLd6/9C4dcxtKZw0JfU6Ns8dnnJaX+gpvzKFz0MK
 vQQGw0eNovNFuvBq6GxCsZfwwNKPl2hjlntFXzXUIXqNeWGmfj7Bc1ZWDl7RNUjl
 2XB6jTCXppAfrUPNt5OROKdhxzuAdaO6gZDtuc641ikhGk9GPlgqakmf81uZ++ow
 QnUhMeeJm0b2+lSQTotlq7EzlbwywOu0la9dxYFrOsgiez6e9HVpbwiFSrLySZ5t
 7tvFLZH80A7ScmrQvc57fTZVt+jLsfwgPxITuz0GYbRsd7I6UzA0gvLdMIhciazt
 sdoKkV8NiPfk/A1IlvU/bggC1K/Vxq5MeuPNSaGY8ghe2907w2l308GajjlSOn6v
 wGPbc3QwiNugE1UTiqunQW6DbO7AfG54p4FCnEL9PqMatnajIVg=
 =SPAs
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEz9yiRbEEPPKl+Xhl/+h0BBaL2EcFAmAaP0MACgkQ/+h0BBaL
 2EdeMg//dk70PDP4yakQD2GUSg9ZG1spfA5JyYNauZwaDtHC/XbJLn4d6hbXilKR
 F9Xye18j14fIjRmD7swVumF+c1BP5qxAKkpAB7/hn6xcNmmuHFQnNvwRO50s49EZ
 Btu3mhigf+e4Nymdptw01SQGYhU5ntlHLnsP/NKYqpAihwlBhiZPwvmdgNgUm/Or
 d1MYG7lCcrjIRHJwu1SfJFqpmWfd79JR72HKchvukrvmg+LN3dfDQCAIznwt4G/C
 aZlERAMC9mFMtVKRkcimMDqOUhOrFXcKb7UMqVmIGKwSiwASl24J240aMB0aOnSl
 7BmvIzFnzhtXK4yh+Jd8zyuGjgv2kiir17nRWf5KL6OWiWnNyqnNVgHC5JtkjpQs
 iow+7d3EwwQ/X7UEzg8njcwsY/H+BhaIZFircHQvQ7T3G8BUAzOj+LXoI5C+NI99
 1rTf3KGcNIb4TjyJ/jVQiOkV+JLh54BretrplkkqCJY7h3Obir+PkDVYVd0UBJrf
 wegHfomHOPo9+IHRgKb3RPygSlTRHRgCbN9tc3ciZeMH+4uNS/W2KW1BxYpdezdT
 zUm5NakK5eksggtd3kH9gcLh+2LmjYWPP+IZ76xvBNZK3JfaCqAaC42HyY1WtLak
 NRUCkmY7kPr3RE04f+xMnMSkMBV5Tkugc4FuL02OMvVbnFi8gHI=
 =w2k/
 -----END PGP SIGNATURE-----

Merge tag 'v3.10.0a5'

Python 3.10.0a5
2021-02-03 06:14:25 +00:00
diegoe a98fe02d73
bpo-43082: Remove redundant 'the' in Descriptor howto (GH-24394) 2021-02-02 19:28:36 -08:00
Steve Dower 1ba08a121a
Add link to Microsoft docs for limitations in Windows Store package (GH-24422) 2021-02-03 01:13:43 +00:00
Ken Jin 2edaf6a4fb
bpo-8264: Document hasattr and getattr behavior for private attributes (GH-23513)
Clarify ``getattr`` and ``setattr`` requirements for accessing name-mangled attributes

Co-Authored-By: Catalin Iacob <iacobcatalin@gmail.com>
2021-02-02 13:06:57 -08:00
Pablo Galindo b0478d738a
Fix Sphynx syntax in the memory.rst document 2021-02-02 20:45:36 +00:00
Pablo Galindo 58fb156edd
bpo-42997: Improve error message for missing : before suites (GH-24292)
* Add to the peg generator a new directive ('&&') that allows to expect
  a token and hard fail the parsing if the token is not found. This
  allows to quickly emmit syntax errors for missing tokens.

* Use the new grammar element to hard-fail if the ':' is missing before
  suites.
2021-02-02 19:54:22 +00:00
Aviral Srivastava 000cde5984
bpo-38307: Add end_lineno attribute to pyclbr Objects (GH-24348)
For back-compatibility, make the new constructor parameter for public classes Function and Class
keyword-only with a default of None.

Co-authored-by: Aviral Srivastava <aviralsrivastava@Avirals-MacBook-Air.local
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2021-02-01 12:38:44 -05:00
Pablo Galindo a776da90b8
bpo-42927: Update the What's new entry for LOAD_ATTR optimizations (GH-24383) 2021-01-31 22:55:48 +00:00
Adorilson Bezerra 89294e30ff
Doc: errors tutorial improvements (GH-16269)
Improvements:

- Improvements in how try clause works section
  This suggestion is because the execution continues after *except*, not after *try* but before *except*. I guess this form more clear.

- Surrounding some keywords with \*...\*
  For uniformity the highlighted terms  

- Adjust the number of chars per line to 80
2021-01-30 22:07:11 -08:00
L e603443642
bpo-43059: Remove reference to legacy external sqlite3 repository (GH-24364) 2021-01-31 07:19:07 +02:00
Ian Wienand 62437a2fa9
bpo-43047: logging.config formatters documentation update (GH-24358)
The documentation for some parts of the logging.config formatters has
fallen behind the code.  For example, the dictionary-schema section
does not list the "class" attribute, however it is discussed in the
file/ini discussion; and neither references the style argument which
has been added.

This modifies the dictionary-schema formatters documentation to list
the keys available and overall makes it clearer these are passed to
create a logging.Formatter object.

The logging.Formatter documentation describes the default values of
format/datefmt and the various formatting options.  Since we have now
more clearly described how the configuration is created via this type
of object, we remove the discussion in this document to avoid
duplication and rely on users reading the referenced logging.Formatter
documenation directly for such details.

Instead of duplicating the discussion for the two config types, the
file/ini section is modified to link back to the dictionary-schema
discussion, making it clear the same arguments are accepted.

Automerge-Triggered-By: GH:vsajip
2021-01-30 02:37:15 -08:00
Steve Dower 62949f697f
bpo-41282: Add deprecation warning and docs for distutils (PEP 632) (GH-24355) 2021-01-29 21:48:55 +00:00
Jules Lasne 6baaae589d
Fixing typos in turtle.rst (GH-24376)
Automerge-Triggered-By: GH:JulienPalard
2021-01-29 13:40:45 -08:00
Jules Lasne 6372a4ceba
Fixed typo in turtle.rst (GH-24371)
Found it while translating it to french 🤷

Automerge-Triggered-By: GH:JulienPalard
2021-01-29 09:46:39 -08:00
Victor Stinner 64fc105b2d
bpo-42955: Remove sub-packages from sys.stdlib_module_names (GH-24353) 2021-01-28 00:03:23 +01:00
Ken 7a34380ad7
bpo-43008: Make IDLE respect sys.excepthook (GH-24302)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2021-01-26 18:55:52 -05:00
Irit Katriel dea5bf9d15
bpo-33387: update documentation for exception handling opcode changes (GH-24334)
* bpo-33387: remove obsolete comment

* bpo-33387: update SETUP_WITH opcode documentation
2021-01-26 10:17:13 +00:00
Pablo Galindo c92cd0f3c8
Fix minor typo in the rest format in the enum docs (GH-24335) 2021-01-25 23:23:30 +00:00
Pablo Galindo 7c8e0b0336
Document new parenthesized with statements (GH-24281) 2021-01-25 23:15:51 +00:00
Ethan Furman 7aaeb2a3d6
bpo-38250: [Enum] single-bit flags are canonical (GH-24215)
Flag members are now divided by one-bit verses multi-bit, with multi-bit being treated as aliases. Iterating over a flag only returns the contained single-bit flags.

Iterating, repr(), and str() show members in definition order.

When constructing combined-member flags, any extra integer values are either discarded (CONFORM), turned into ints (EJECT) or treated as errors (STRICT). Flag classes can specify which of those three behaviors is desired:

>>> class Test(Flag, boundary=CONFORM):
...     ONE = 1
...     TWO = 2
...
>>> Test(5)
<Test.ONE: 1>

Besides the three above behaviors, there is also KEEP, which should not be used unless necessary -- for example, _convert_ specifies KEEP as there are flag sets in the stdlib that are incomplete and/or inconsistent (e.g. ssl.Options). KEEP will, as the name suggests, keep all bits; however, iterating over a flag with extra bits will only return the canonical flags contained, not the extra bits.

Iteration is now in member definition order.  If member definition order
matches increasing value order, then a more efficient method of flag
decomposition is used; otherwise, sort() is called on the results of
that method to get definition order.


``re`` module:

repr() has been modified to support as closely as possible its previous
output; the big difference is that inverted flags cannot be output as
before because the inversion operation now always returns the comparable
positive result; i.e.

   re.A|re.I|re.M|re.S is ~(re.L|re.U|re.S|re.T|re.DEBUG)

in both of the above terms, the ``value`` is 282.

re's tests have been updated to reflect the modifications to repr().
2021-01-25 14:26:19 -08:00
Victor Stinner 9852cb3811
bpo-42955: Rename module_names to sys.stdlib_module_names (GH-24332)
* Rename _Py_module_names to _Py_stdlib_module_names.
* Rename Python/module_names.h to Python/stdlib_module_names.h.
2021-01-25 23:12:50 +01:00
Serhiy Storchaka f066bd94b9
bpo-37319: Improve documentation, code and tests of randrange. (GH-19112) 2021-01-25 23:02:04 +02:00
Julien Palard 5c1f15b4b1
bpo-42843: Keep Sphinx 1.8 and Sphinx 2 compatibility (GH-24282) 2021-01-25 15:46:06 +01:00
Victor Stinner 483359174e
bpo-42955: Fix sys.module_names doc (GH-24329)
Replace versionchanged markup with versionadded.
2021-01-25 13:59:02 +01:00
Victor Stinner db584bdad3
bpo-42955: Add sys.modules_names (GH-24238)
Add sys.module_names, containing the list of the standard library
module names.
2021-01-25 13:24:42 +01:00
Serhiy Storchaka cf19cc3b92
bpo-27772: Make preceding width with 0 valid in string format. (GH-11270)
Previously it was an error with confusing error message.
2021-01-25 11:56:33 +02:00
Illia Volochii b745a6143a
bpo-42996: Update a reference to PKCS #5 in hashlib docs to version 2.1 (GH-24289)
RFC 8018 superseded RFC 8018.

Automerge-Triggered-By: GH:tiran
2021-01-22 04:06:00 -08:00
Борис Верховский 644d52818a
bpo-40304: Correct type(name, bases, dict) doc (GH-19553)
Co-authored-by: Éric Araujo <merwok@netwok.org>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Tal Einat <532281+taleinat@users.noreply.github.com>
2021-01-22 00:47:23 -05:00
Pablo Galindo 805ede8ae8
Add a What's New entry for the new parser error improvements (GH-24280) 2021-01-21 17:36:35 +00:00
ravcio 6cd5b0117e
Fix typo in what's new. bidst_wheel -> bdist_wheel (GH-24234)
bidst_wheel -> bdist_wheel

Automerge-Triggered-By: GH:Mariatta
2021-01-21 02:23:46 -08:00
Ken Jin dcea78ff53
bpo-42392: Mention loop removal in whatsnew for 3.10 (GH-24256)
@vstinner [noticed on python-dev](https://mail.python.org/archives/list/python-dev@python.org/thread/O3T7SK3BGMFWMLCQXDODZJSBL42AUWTR/) that there is no what's new or porting entry for removal of asyncio ``loop`` parameter. 

This patch adds a basic guide.

Co-Authored-By: Kyle Stanley <aeros167@gmail.com>
2021-01-20 16:16:12 -08:00
Victor Stinner 75e59a97f5
bpo-42856: Add --with-wheel-pkg-dir=PATH configure option (GH-24210)
Add --with-wheel-pkg-dir=PATH option to the ./configure script. If
specified, the ensurepip module looks for setuptools and pip wheel
packages in this directory: if both are present, these wheel packages
are used instead of ensurepip bundled wheel packages.

Some Linux distribution packaging policies recommend against bundling
dependencies. For example, Fedora installs wheel packages in the
/usr/share/python-wheels/ directory and don't install the
ensurepip._bundled package.

ensurepip: Remove unused runpy import.
2021-01-20 17:07:21 +01:00
Conchylicultor e0e398ef18
Fix typos in unittest documentation (GH-24194)
* addCleanupClass  -> addClassCleanup
* doCleanupsClass -> doClassCleanups
2021-01-20 18:38:37 +05:30
Erlend Egeberg Aasland e982fe496b
bpo-42048: Clinic Howto: Document AC's defining_class converter (GH-23978) 2021-01-20 12:19:57 +01:00
Hong Xu 1459fed92c
Doc: os.path.abspath and Path.resolve are also different (GH-23276) 2021-01-20 11:20:00 +01:00
Pablo Galindo e485be5b6b
Add a clarification for the object-domain allocators regarding pointer validity (GH-24253) 2021-01-19 13:09:06 +00:00
Pablo Galindo bc450f9694
Add a paragraph about allocation domains to the C-API docs (GH-24252) 2021-01-18 22:20:57 +00:00
Irit Katriel 4c94d74152
bpo-42877: add the 'compact' param to TracebackException's __init__ (#24179)
Use it to reduce the time and memory taken up by several of traceback's module-level functions.
2021-01-14 18:45:02 -08:00
Ken Jin 9712358277
Docs: Remove stray semicolon in init.rst (GH-23974)
Removed stray semicolon which was causing the docs to render weirdly (it's the function right under the one [here](https://docs.python.org/3/c-api/init.html#c._PyInterpreterState_GetEvalFrameFunc)).
2021-01-14 07:57:08 -08:00
Zackery Spytz 14cfa325c2
bpo-39273: Expose BUTTON5_* constants in the curses module if available (GH-17996) 2021-01-14 11:40:09 +02:00
Hugo van Kemenade c47c78b878
bpo-37324: Remove ABC aliases from collections (GH-23754)
Remove deprecated aliases to Abstract Base Classes from the
collections module.
2021-01-13 00:16:37 +01:00
Tomáš Hrnčiar fb35fa49d1
bpo-42870: Document change in argparse help output. (GH-24190) 2021-01-11 16:41:35 -08:00
Ken Jin ace008c531
Fix various ParamSpec errors in typing (GH-24176)
1. ParamSpec -> TypeVar for ``typing.Concatenate``
2. ParamSpec's call signature should align with its documentation.
Noticed in GH-24169
2021-01-10 16:11:41 -08:00
Victor Stinner 0e2a0f72cc
bpo-42802: Remove distutils bdist_wininst command (GH-24043)
The distutils bdist_wininst command deprecated in Python 3.8 has been
removed. The distutils bidst_wheel command is now recommended to
distribute binary packages on Windows.

* Remove Lib/distutils/command/bdist_wininst.py
* Remove PC/bdist_wininst/ project
* Remove Lib/distutils/command/wininst-*.exe programs
* Remove all references to bdist_wininst
2021-01-09 00:35:01 +01:00
Johan Dahlin 68e1f259be
Fix a typo in docs for typing.Concatenate (#24169)
Return param spec should be R, not T
2021-01-08 10:08:21 -08:00
Simon Willison 5c30145afb
bpo-42783: Documentation for asyncio.sleep(0) (#24002)
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
2021-01-07 12:03:18 +10:00
Yair Frid ff8458b918
bpo-42811: Update importlib.utils.resolve_name() docs to use __spec__.parent (GH-24100)
Automerge-Triggered-By: GH:brettcannon
2021-01-06 09:42:10 -08:00
Antonio Cuni 315fc52db1
bpo-42528: Improve the docs of most Py*_Check{,Exact} API calls (GH-23602)
I think that none of these API calls can fail, but only few of them are
documented as such. Add the sentence "This function always succeeds" (which is
the same already used e.g. by PyNumber_Check) to all of them.
2021-01-06 12:38:26 +01:00
Berker Peksag 1a9f51ed12
bpo-14014: Clarify StreamWriter.reset() documentation (GH-13716) 2021-01-06 04:14:42 +02:00
Erlend Egeberg Aasland ddb5e11683
bpo-24464: Deprecate sqlite3.enable_shared_cache (GH-24008) 2021-01-06 02:36:04 +02:00
Vladimir f9949f82e1
bpo-38413: Remove outdated section about multithreading in sqlite3 (GH-23159) 2021-01-06 02:18:46 +02:00
Erlend Egeberg Aasland cf0b23908c
bpo-40810: Require SQLite 3.7.15 (GH-24106) 2021-01-06 02:02:43 +02:00
Pablo Galindo de833b6013
Fix 'make suspicious' for the itertools module (GH-24097) 2021-01-04 17:24:22 +00:00
Serhiy Storchaka 1470edd613
bpo-42681: Fix range checks for color and pair numbers in curses (GH-23874) 2021-01-03 22:51:11 +02:00
Zackery Spytz 6613676861
bpo-38308: Fix the "versionchanged" for the *weights* of harmonic_mean() (GH-23919) 2021-01-03 14:35:26 +02:00
Pablo Galindo 9e8fe1986c
bpo-42093: Tweak the what's new message about the new LOAD_ATTR opcode cache (GH-24070) 2021-01-03 04:37:46 +00:00
Ken Jin 11276cd9c4
bpo-41559: Documentation for PEP 612 (GH-24000) 2021-01-01 16:45:50 -08:00
Dong-hee Na de6f20a6de
Bring Python into the new year. (GH-24036) 2021-01-02 00:37:23 +09:00
Raymond Hettinger c8a7b8fa1b
bpo-42781: Document the mechanics of cached_property from a user viewpoint (GH-24031) 2020-12-31 17:05:58 -08:00
Tao He 3631d6deab
Fixes a typo in importlib.metadata. (#23921)
Signed-off-by: Tao He <sighingnow@gmail.com>
2020-12-31 11:37:53 -08:00
Jason R. Coombs dfdca85dfa
bpo-42382: In importlib.metadata, `EntryPoint` objects now expose `dist` (#23758)
* bpo-42382: In importlib.metadata, `EntryPoint` objects now expose a `.dist` object referencing the `Distribution` when constructed from a `Distribution`.

Also, sync importlib_metadata 3.3:

- Add support for package discovery under package normalization rules.
- The object returned by `metadata()` now has a formally-defined protocol called `PackageMetadata` with declared support for the `.get_all()` method.

* Add blurb

* Remove latent footnote.
2020-12-31 12:56:43 -05:00
Erlend Egeberg Aasland f4936ad1c4
bpo-42393: Raise OverflowError iso. DeprecationWarning on overflow in socket.ntohs and socket.htons (GH-23980) 2020-12-31 15:16:50 +02:00
Raymond Hettinger f421bfce80
Minor improvements to the convolve() recipe (GH-24012)
* Minor improvement to speed and space efficiency for the convolve() recipe
* Don't require convolve's kernel to be a sequence.
2020-12-30 12:51:19 -08:00
pxinwr 277ce3060b
bpo-27640: Add --disable-test-modules configure option (GH-23886)
Added --disable-test-modules option to the configure script:
don't build nor install test modules.

Patch by Xavier de Gaye, Thomas Petazzoni and Peixing Xin.

Co-Authored-By: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Co-Authored-By: Xavier de Gaye <xdegaye@gmail.com>
2020-12-30 13:50:39 +01:00
Yurii Karabas c56387f80c
bpo-27794: Add `name` attribute to `property` class (GH-23967) 2020-12-30 01:51:24 -08:00
Andre Delfino 2edfc86f69
bpo-41224: Add versionadded for Symbol.is_annotated (GH-23861) 2020-12-29 15:32:10 +02:00
Michael Wayne Goodman 84402eb110
bpo-42700: Swap descriptions in pyexpat.errors (GH-23876)
The descriptions of the `codes` and `messages` dictionaries in
`xml.parsers.expat.errors` were swapped, and this commit swaps them
back. For example, `codes` maps string descriptions of errors to numeric
error codes, not the other way around.
2020-12-29 14:33:15 +02:00
Zackery Spytz c56988b88f
bpo-42770: Fix a typo in the email.headerregistry docs (GH-23982)
Automerge-Triggered-By: GH:zware
2020-12-28 20:12:37 -08:00
Raymond Hettinger a9621bb301
bpo-42222: Modernize integer test/conversion in randrange() (#23064) 2020-12-28 11:10:34 -08:00
Erlend Egeberg Aasland abba83b4b9
bpo-42755: Fix sqlite3.Connection.backup docs (GH-23965)
The `pages` argument default value now reflects the implementation.
2020-12-27 22:35:17 +00:00
Raymond Hettinger 77fde8dc16
Add convolve() to the itertools recipes (GH-23928) 2020-12-25 16:43:20 -08:00
Ken Jin f0853bcedf
Sync what's new in 3.9 with 3.9 branch (GH-23943) 2020-12-25 23:08:17 +00:00
Desmond Cheong 36a779e64c
bpo-35728: Add root parameter to tkinter.font.nametofont() (GH-23885) 2020-12-25 23:18:06 +02:00
Gregory P. Smith 64abf37344
bpo-42388: Fix subprocess.check_output input=None when text=True (GH-23467)
When the modern text= spelling of the universal_newlines= parameter was added
for Python 3.7, check_output's special case around input=None was overlooked.
So it behaved differently with universal_newlines=True vs text=True.  This
reconciles the behavior to be consistent and adds a test to guarantee it.

Also clarifies the existing check_output documentation.

Co-authored-by: Alexey Izbyshev <izbyshev@ispras.ru>
2020-12-24 20:57:21 -08:00
Raymond Hettinger cc3467a57b
bpo-38308: Add optional weighting to statistics.harmonic_mean() (GH-23914) 2020-12-23 19:52:09 -08:00
Batuhan Taskaya eee1c7745a
bpo-41960: Add globalns and localns parameters to inspect.signature and Signature.from_callable (GH-22583) 2020-12-24 01:45:13 +03:00
Raymond Hettinger 41b223d29c
bpo-9694: Fix misleading phrase "optional arguments" (GH-23858) 2020-12-23 09:40:56 -08:00
Matt Fowler d90ff37681
BPO-42703: Fix incorrect documentation links for asyncio.Event (GH-23881) 2020-12-23 12:44:52 +02:00
Raymond Hettinger 6afb730e2a
bpo-29030: Document interaction between *choices* and *metavar*. (GH-23884) 2020-12-22 09:24:26 -08:00
Andre Delfino 60eccd0956
[doc] Fix missing commas in signatures (#23693)
* Fix star in signatures

* Fix comma in signatures
2020-12-22 11:02:52 -05:00
Batuhan Taskaya fbc7723778
bpo-39159: Declare error that might be raised from literal_eval (GH-19899) 2020-12-21 16:15:40 -08:00
Géry Ogam d515c610c6
bpo-35790: Correct the description of sys.exc_info() and add a code example (GH-11625) 2020-12-21 14:13:08 +01:00
Colin Watson c95f8bc270
bpo-42669: Document that `except` rejects nested tuples (GH-23822)
In Python 2, it was possible to use `except` with a nested tuple, and occasionally natural.  For example, `zope.formlib.interfaces.InputErrors` is a tuple of several exception classes, and one might reasonably think to do something like this:

    try:
        self.getInputValue()
        return True
    except (InputErrors, SomethingElse):
        return False

As of Python 3.0, this raises `TypeError: catching classes that do not inherit from BaseException is not allowed` instead: one must instead either break it up into multiple `except` clauses or flatten the tuple.  However, the reference documentation was never updated to match this new restriction.  Make it clear that the definition is no longer recursive.

Automerge-Triggered-By: GH:ericvsmith
2020-12-20 10:24:10 -08:00
Raymond Hettinger b0398a4b7f
bpo-42572: Improve argparse docs for the type parameter. (GH-23849) 2020-12-20 10:14:54 -08:00
sblondon 09a36cdfb7
bpo-41724: Explain when the conversion is not possible with detect_types enabled (GH-23855)
* Explain when the conversion is not possible with detect_types enabled
2020-12-19 17:52:39 -05:00
Andre Delfino c56f9df049
[doc] Mention with and except clauses in globals() (GH-13232) 2020-12-19 16:48:06 +01:00
Raymond Hettinger 5646414ae1
bpo-42559: Not that getrandbits() is non-negative. (GH-23843) 2020-12-18 17:03:10 -08:00
Raymond Hettinger 51f4688254
bpo-34805: Guarantee that __subclasses__() is in definition order. (GH-23844) 2020-12-18 16:53:50 -08:00
Irit Katriel fb34096140
bpo-24792: Fix zipimporter masking the cause of import errors (GH-22204)
zipimport's _unmarshal_code swallows import errors and then _get_module_code doesn't know the cause of the error, and returns the generic, and sometimes incorrect, 'could not find...'.

Automerge-Triggered-By: GH:brettcannon
2020-12-18 16:09:54 -08:00
Andre Delfino e8d2264210
bpo-36769: Document that fnmatch.filter supports any kind of iterable (#13039) 2020-12-18 20:10:20 +01:00
Ammar Askar 8c5d0347ef
bpo-34398: Allow glossary results to show up on search page (GH-8773) 2020-12-18 20:00:51 +01:00
kj d75f6f78e6
bpo-42675: Document collections.abc.Callable changes (GH-23839) 2020-12-18 09:39:26 -08:00
Matt Wozniski 84ebcf271a
bpo-17140: Document multiprocessing's ThreadPool (GH-23812)
Up until now, the `multiprocessing.pool.ThreadPool` class has gone
undocumented, despite being a public class in multiprocessing that is
included in `multiprocessing.pool.__all__`.
2020-12-18 13:05:46 +00:00
Julien Palard b9735420aa
bpo-42238: Check Misc/NEWS.d/next/ for reStructuredText issues. (GH-23802) 2020-12-18 10:48:08 +01:00
Mark Dickinson 886b2e5c7a
bpo-39096: Format specification documentation fixes for numeric types (GH-23575) 2020-12-18 10:24:06 +01:00
Zackery Spytz 074ad5123f
bpo-42670: Fix a missing word in the itertools.product() docs (GH-23823) 2020-12-17 12:24:43 -08:00
Andre Delfino 96a09df644
[doc] Fix a few margins due to bad markup (GH-23619) 2020-12-17 09:25:55 -08:00
Mark Shannon bf353f3c2d
bpo-42246: Make sure that `f_lasti`, and thus `f_lineno`, is set correctly after raising or reraising an exception (GH-23803)
* Ensure that f_lasti is set correctly after an exception is raised to conform to PEP 626.

* Update importlib

* Add NEWS.
2020-12-17 13:55:28 +00:00
Andre Delfino dcc997cd28
[doc] Fix erroneous backslashes in signatures and names (GH-23658)
The issue being resolved is shown in the 3.10 docs (if you select docs for older versions you won't see a visual glitch).

The newer sphinx version that produces the 3.10 docs doesn't treat the backslash to escape things in some situations it previously did.
2020-12-16 17:37:28 -08:00
Matthew Suozzo a6ba2b9015
Fix indentation for get_stats_profile() docs (GH-23618)
The existing method is indented one too many times which
makes it look like a sub-method of print_callees().
2020-12-17 01:17:22 +02:00
Irit Katriel c590c2338e
bpo-23915: update and elucidate documentation of with_traceback (GH-23680) 2020-12-16 17:03:32 +01:00
Antoine fc3dca3e16
Clarify eval() doc from library/functions. (GH-22700) 2020-12-16 16:45:19 +01:00
Vladimir 3f9fe23c05
bpo-42179: Clarify exception chaining (GH-23160)
* Update errors.rst

Clarify exception chaining behaviour and give a reference to the library documentation.

* Update errors.rst

Wording

* Update errors.rst

Spelling

* Update errors.rst

Remove mentioning of special attributes as folks think it's too much for beginners.
2020-12-15 18:47:26 -08:00
Jason R. Coombs 928dbfc16c
bpo-42090: zipfile.Path.joinpath now accepts multiple arguments (GH-22976)
Automerge-Triggered-By: GH:jaraco
2020-12-15 18:12:54 -08:00
pxinwr e1e3c2dac3
bpo-31904: Disable os.popen and popen test cases on VxWorks (GH-21687) 2020-12-15 22:20:07 +01:00
Pablo Galindo 0911411e0c
Update stable ABI script for MacOS and update list of exported symbols (GH-23783) 2020-12-15 18:16:13 +00:00
Julien Palard c8a10d2fab
bpo-36675: Doc: Reveal doctest directives (GH-23620) 2020-12-15 17:23:03 +01:00
Victor Stinner 357704c9f2
bpo-42639: atexit now logs callbacks exceptions (GH-23771)
At Python exit, if a callback registered with atexit.register()
fails, its exception is now logged. Previously, only some exceptions
were logged, and the last exception was always silently ignored.

Add _PyAtExit_Call() function and remove
PyInterpreterState.atexit_func member. call_py_exitfuncs() now calls
directly _PyAtExit_Call().

The atexit module must now always be built as a built-in module.
2020-12-14 23:07:54 +01:00
sblondon da431f789b
Add two spaces around equal sign (#23719)
Fit to PEP8 coding style
2020-12-12 21:27:22 -08:00
Nick Gaya 4b8cdfcb22
bpo-41879: Doc: Fix description of async for statement (GH-23548)
Fix the wording in the documentation of `async for` to correctly describe asynchronous iterables.  This fix is relevant for version 3.7 onward.
2020-12-11 00:27:35 -08:00
Ethan Furman efb13be72c
bpo-42385: [Enum] add `_generate_next_value_` to StrEnum (GH-23735)
The default for auto() is to return an integer, which doesn't work for `StrEnum`.  The new `_generate_next_value_` for `StrEnum` returns the member name, lower cased.
2020-12-10 12:20:06 -08:00
vabr-g 9fc571359a
bpo-41877: Improve docs for assert misspellings check in mock (GH-23729)
This is a follow-up to
4662fa9bfe.
That original commit expanded guards against misspelling assertions on
mocks. This follow-up updates the documentation and improves the error
message by pointing out the potential cause and solution.

Automerge-Triggered-By: GH:gpshead
2020-12-10 10:35:28 -08:00
Ethan Furman 7cf0aad96d
bpo-42517: [Enum] do not convert private names into members (GH-23722)
private names, such as `_Color__hue` and `_Color__hue_` are now normal attributes, and do not become members nor raise exceptions
2020-12-09 17:12:11 -08:00
Andre Delfino 2a35137328
[doc] Link to issue regarding logging.disable level param default value (GH-23726) 2020-12-09 15:37:39 -08:00
Andre Delfino 35cacce525
[doc] Document logging.basicConfig default format (GH-23710)
Automerge-Triggered-By: GH:vsajip
2020-12-09 13:56:17 -08:00
Hai Shi 0f91f586ae
bpo-42599: Remove useless PyModule_GetWarningsModule() (GH-23691)
Removed PyModule_GetWarningsModule() which is useless due to 
the _warnings module was converted to a builtin module in 2.6.
2020-12-08 15:42:42 +01:00
Matěj Cepl b63a620014
bpo-42579: Make workaround for various versions of Sphinx more robust (GH-23662)
The solution in gh#python/cpython#13236 is too strict because it
effectively requires the use of Sphinx >= 2.0. It is not too difficult to
make the same solution more robust so it works with all normal versions
of Sphinx.
2020-12-07 20:05:13 +00:00
Victor Stinner 0ef96c2b2a
bpo-30459: Cast the result of PyCell_SET to void (GH-23654) 2020-12-07 11:56:20 +01:00
Raymond Hettinger 752cdf21eb
bpo-38843: Document behavior of default when the attribute is already set (GH-23653) 2020-12-06 18:29:08 -08:00
Brett Cannon 2de5097ba4
bpo-26131: Deprecate usage of load_module() (GH-23469)
Raise an ImportWarning when the import system falls back on load_module(). As for implementations of load_module(), raise a DeprecationWarning.
2020-12-04 15:39:21 -08:00
Pablo Galindo 85f1dedb8d
bpo-42545: Check that all symbols in the limited ABI are exported (GH-23616) 2020-12-04 22:05:58 +00:00
Zackery Spytz db68544122
bpo-42523: Fix supported versions in "Using Python on Windows" (GH-23603) 2020-12-03 17:22:04 +00:00
Victor Stinner 1867b462de
bpo-37221: PyCode_New() didn't change in Python 3.8 (GH-23595) 2020-12-01 16:22:25 +01:00
Andre Delfino bc662c0bd7
[doc] Fix abc.update_abstractmethods markup (GH-23576)
Add link to ABCMeta while at it.
2020-12-01 01:45:11 -08:00
Andre Delfino 80a429eae9
Fix bz2 examples markup (#23580) 2020-12-01 10:41:12 +01:00
Raymond Hettinger cc061d0e6f
bpo-38200: Add itertools.pairwise() (GH-23549) 2020-11-30 20:42:54 -08:00
Christian Heimes 5c73afc36e
bpo-28468: Add platform.freedesktop_os_release() (GH-23492)
Add platform.freedesktop_os_release() function to parse freedesktop.org
os-release files.

Signed-off-by: Christian Heimes <christian@python.org>
Co-authored-by: Victor Stinner <vstinner@python.org>
2020-11-30 22:34:45 +01:00
James Gerity bcc9579227
bpo-42485: [Doc] Link to PEP 617 from full grammar specification (GH-23532)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
2020-11-30 19:08:26 +00:00
Raymond Hettinger 7f82f22eba
bpo-42501: Revise the usage note for Enums with the choices (GH-23563) 2020-11-30 09:55:13 -08:00
Yasser A 9f004634a2
bpo-42451: Indicate that PyTuple_GetItem does not support negative indices (GH-23529) 2020-11-30 10:53:11 +01:00
Raymond Hettinger fc40b3020c
bpo-42450: Minor updates to the itertools recipes (GH-23555) 2020-11-29 10:47:22 -08:00
Yurii Karabas 86150d39c8
bpo-42392: Remove deprecated loop parameter from docs (GH-23552) 2020-11-29 14:50:57 +02:00
Mark Dickinson c642374b3e
bpo-39096: Improve description of 'e', 'f' and 'g' presentation types (#23537)
* Improve description of 'e', 'f' and 'g' presentation types

* Drop the 'E' from Scientific 'E' notation; remove >= 0 qualifications

* Fix false statement that the alternate form is valid for Decimal

* Nitpick: remove the Harvard/Oxford comma

* Add note that the decimal point is also removed if no digits follow it, except in alternate form
2020-11-29 09:34:36 +00:00
pxinwr a86a274b72
bpo-31904: add shell requirement for test_pipes (GH-23489)
VxWorks has no user space shell provided so it can't support pipes module. Also add shell requirement for running test_pipes.
2020-11-28 14:04:50 -08:00
Andre Delfino fa840cc81d
Fix dis markup (GH-23524) 2020-11-28 13:43:22 -08:00
Andre Delfino 4b44472966
Fix multiprocessing markup (GH-23525) 2020-11-28 13:42:23 -08:00
Zackery Spytz d41ec65ab7
bpo-42489: Fix the signature for list.sort() in the tutorial (GH-23538) 2020-11-28 16:53:39 +02:00
Volker-Weissmann c8aaf71dde
bpo-17852: Doc: Fix the tutorial about closing files (GH-23135)
Co-authored-by: Inada Naoki <songofacandy@gmail.com>
2020-11-27 09:41:32 +09:00
Shane Harvey a1652da2c8
Document optional 'task'/'asyncgen' fields in call_exception_handler (#21735) 2020-11-26 15:24:48 +02:00
basak 9d09e1719c
Typo: fix inverted sense of statement (GH-23288)
Looks like a "not" was inadvertently omitted in commit e6a7ea4.
Classmethods are useful when data stored in specific instances are *not*
needed.

Automerge-Triggered-By: GH:JulienPalard
2020-11-25 06:12:17 -08:00
Dong-hee Na be319c0c10
bpo-42299: Remove formatter module (GH-23476) 2020-11-25 22:17:30 +09:00
Yurii Karabas 7301979b23
bpo-42202: Store func annotations as a tuple (GH-23316)
Reduce memory footprint and improve performance of loading modules having many func annotations.

  >>> sys.getsizeof({"a":"int","b":"int","return":"int"})
  232
  >>> sys.getsizeof(("a","int","b","int","return","int"))
  88

The tuple is converted into dict on the fly when `func.__annotations__` is accessed first.

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Inada Naoki <songofacandy@gmail.com>
2020-11-25 19:43:18 +09:00
Raymond Hettinger 85c84920f5
Add more tests to the descriptor howto guide (GH-23506) 2020-11-25 01:54:24 -08:00
Julien Palard c9c6e9f89a
bpo-42238: Doc: Remove make suspicious from the CI and docs builds. (GH-23313)
It probably helped a lot a while back, but may not be as usefull
today.  We'll continue monitoring it before deletion, so true
positives can be migrated to rstlint.
2020-11-25 10:18:00 +01:00
kj 8d17d2bd0a
Doc: Minor fixes (GH-23422) 2020-11-25 13:59:59 +09:00
Raymond Hettinger 2d44a6bc4f
Add doctests to the descriptor HowTo (GH-23500) 2020-11-24 20:57:02 -08:00
Jesús Cea 989af25616
Typo (#23482) 2020-11-24 00:56:30 +01:00
Yaroslav Pankovych 79d2e62c00
Added support for negative indexes to PurePath.parents (GH-21799)
This commit also fixes up some of the overlapping documentation changed
in bpo-35498, which added support for indexing with slices.

Fixes bpo-21041.
https://bugs.python.org/issue21041

Co-authored-by: Paul Ganssle <p.ganssle@gmail.com>
Co-authored-by: Rémi Lapeyre <remi.lapeyre@henki.fr>
2020-11-23 15:06:22 -05:00
Raymond Hettinger ffae93248a
Descriptor HowTo: Improve the fidelity of the member object simulation (GH-23475) 2020-11-23 10:56:59 -08:00
Nick Crews 2f2f9d0b5c
bpo-15450: Allow subclassing of dircmp (GH-23424) (#23424)
Co-authored-by: Chris Jerdonek <chris.jerdonek@gmail.com>
2020-11-23 18:29:37 +02:00
John Belmonte 5ef53a88f3
Doc: fix typo in typing.Type docs (GH-23460) 2020-11-22 23:54:19 +09:00
Serhiy Storchaka 686c203cd4
bpo-42423: Accept single base class in PyType_FromModuleAndSpec() (GH-23441) 2020-11-22 13:25:02 +02:00
Ram Rachum bd8c22e1fa
bpo-42391: Clarify documentation of TestCase.assertIs (GH-23348)
Removing 'evaluate' makes it more consistent with other assertX entries.
2020-11-22 00:59:48 -05:00
Richard Levasseur 68f68fa423
Clarify that Set._from_iterable is not required to be a classmethod. (GH-23272) 2020-11-21 11:56:24 -08:00
David CARLIER 0e62efc51e
bpo-42232: mmap module add Darwin specific madvise options. (GH-23076) 2020-11-21 03:39:56 -08:00
Serhiy Storchaka 1db76394ea
bpo-42412: Fix possible leaks and check arguments in PyType_FromModuleAndSpec() (GH-23410)
* There were leaks if Py_tp_bases is used more than once or if some call is
  failed before setting tp_bases.
* There was a crash if the bases argument or the Py_tp_bases slot is not a tuple.
* The documentation was not accurate.
2020-11-21 12:02:53 +02:00
Quentin Hibon aa3a3521ce
bpo-42419: Correct 'deprecatations' is What's New 3.9 (GH-23421) 2020-11-20 23:07:22 -05:00
ArioA 6edf06b24a
bpo-42407: Use possessive appostrophe in multiprocessing doc (GH-23400) 2020-11-20 21:37:54 -05:00
Raymond Hettinger 9fc319dc03
bpo-42360: Add advice to help avoid pickling issues. (GH-23305) 2020-11-20 12:49:32 -08:00
Zhang Maiyun 4c24b08cd3
Fix wrong availability for signal.SIGCHLD (#23285)
I believe this is a mistake. SIGCHLD is only available on Unix systems, not Windows.
2020-11-20 20:16:46 +02:00
Joshua Cannon 4520584483
bpo-35498: Added slice support to PathLib parents attribute. (GH-11165)
Added slice support to the `pathlib.Path.parents` sequence. For a `Path` `p`, slices of `p.parents` should return the same thing as slices of `tuple(p.parents)`.
2020-11-20 10:40:39 -05:00
Christian Heimes 03c8ddd9e9
bpo-42413: socket.timeout is now an alias of TimeoutError (GH-23413)
Signed-off-by: Christian Heimes <christian@python.org>
2020-11-20 00:26:07 -08:00
kj e1dc0db8c7
bpo-42345: Add whatsnew and versionchanged for typing.Literal in 3.9 (GH-23386)
* Whatsnew entry in 3.9 same as the one in 3.10.
* versionchanged for typing.Literal docs

Needs backport to 3.9.
2020-11-19 09:37:26 -08:00
Yurii Karabas 1b54077ff6
bpo-42345: Fix hash implementation of typing.Literal (GH-23383)
Fix hash implementation of `typing.Literal`.

Update docs regarding `typing.Litaral` caching.

Base implementation was done in PR #23294.
2020-11-19 08:17:38 -08:00
kj 4687338d0e
bpo-42345: Add whatsnew for typing.Literal in 3.10 (GH-23385) 2020-11-18 20:44:24 -08:00
Lysandros Nikolaou a85fefe71b
bpo-42381: Document walrus-related syntax changes in whatsnew (GH-23382)
Automerge-Triggered-By: GH:lysnikolaou
2020-11-18 15:49:28 -08:00
Andre Delfino 829b177436
[doc] Fix smtplib and xml.dom.minidom mark-up (GH-22769) 2020-11-18 23:45:17 +01:00