summaryrefslogtreecommitdiffstats
path: root/Misc
Commit message (Collapse)AuthorAgeFilesLines
* bpo-23460: Fix documentation for decimal string :g formatting (GH-11850)Brennan D Baraban2019-09-111-0/+1
|
* bpo-37488 : Document a warning for datetime.utcnow() and utcfromtimestamp() ↵Joannah Nanjekye2019-09-111-0/+1
| | | | | | | | | (GH-15773) https://bugs.python.org/issue37488 Automerge-Triggered-By: @pganssle
* bpo-36919: make test_source_encoding.test_issue2301 ↵Pavel Koneski2019-09-111-0/+2
| | | | | | implementation-independent (#13639) * bpo-36919: make test_issue2301 implementation-independent
* closes bpo-37252: Fix devpoll tests. (GH-14017)Jakub Kulík2019-09-111-0/+2
|
* bpo-37305: add MIME type for Web App Manifest (#14199)Filip Š2019-09-111-0/+2
| | | | | | | | * bpo-37305: add MIME type for Web App Manifest * bpo-37305: add news entry * Restore indentation and sort by value
* bpo-31163: Added return values to pathlib.Path instance's rename and replace ↵hui shang2019-09-111-0/+2
| | | | | methods. (GH-13582) * bpo-31163: Added return values to pathlib.Path instance's rename and replace methods.
* bpo-33944: note about the intended use of code in .pth files (GH-10131)native-api2019-09-111-0/+1
| | | https://bugs.python.org/issue33944
* bpo-34519: Add additional aliases for HP Roman 8 (GH-8956)Michael Osipov2019-09-111-0/+1
| | | | | | | * bpo-34519: Add additional aliases for HP Roman 8 HP Roman 8 is known under mode aliases than listed in aliases.py. Patch by Michael Osipov.
* bpo-35640: Allow passing PathLike arguments to SimpleHTTPRequestHandler ↵Géry Ogam2019-09-111-0/+2
| | | | (GH-11398)
* bpo-35943: Prevent PyImport_GetModule() from returning a ↵Joannah Nanjekye2019-09-111-0/+2
| | | | partially-initialized module (GH-15057)
* bpo-20504 : in cgi.py, fix bug when a multipart/form-data request has… ↵Pierre Quentel2019-09-111-0/+2
| | | | | | | | | | | | (#10638) * bpo-20504 : in cgi.py, fix bug when a multipart/form-data request has no content-length header * Add Misc/NEWS.d/next file. * Add rst formatting for NEWS.d/next file * Reaplce assert by self.assertEqual
* bpo-35168: Make shlex.punctuation_chars read-only (#11631)Alex2019-09-111-0/+1
| | | | | | | | * bpo-35168: Documentation about shlex.punctuation_chars now states that it should be set in __init__.py * bpo-35168: Convert shlex.punctuation_chars to read-only property * Add NEWS.d entry
* bpo-32972: Document IsolatedAsyncioTestCase of unittest module (GH-15878)Xtreak2019-09-111-1/+1
| | | | | | | | | | | * Document `unittest.IsolatedAsyncioTestCase` API * Add a simple example with respect to order of evaluation of setup and teardown calls. https://bugs.python.org/issue32972 Automerge-Triggered-By: @asvetlov
* bpo-37151: remove special case for PyCFunction from PyObject_Call (GH-14684)Jeroen Demeyer2019-09-111-0/+1
| | | | | | | bpo-37151: remove special case for PyCFunction from PyObject_Call Alse, make the undocumented function PyCFunction_Call an alias of PyObject_Call and deprecate it.
* bpo-37409: fix relative import with no parent (#14956)Ben Lewis2019-09-112-0/+3
| | | | | | | | | | | | | Relative imports use resolve_name to get the absolute target name, which first seeks the current module's absolute package name from the globals: If __package__ (and __spec__.parent) are missing then import uses __name__, truncating the last segment if the module is a submodule rather than a package __init__.py (which it guesses from whether __path__ is defined). The __name__ attempt should fail if there is no parent package (top level modules), if __name__ is '__main__' (-m entry points), or both (scripts). That is, if both __name__ has no subcomponents and the module does not seem to be a package __init__ module then import should fail.
* bpo-38081: Fixes ntpath.realpath('NUL') (GH-15899)Steve Dower2019-09-111-0/+1
|
* bpo-37936: Systematically distinguish rooted vs. unrooted in .gitignore ↵Greg Price2019-09-111-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (GH-15823) A root cause of bpo-37936 is that it's easy to write a .gitignore rule that's intended to apply to a specific file (e.g., the `pyconfig.h` generated by `./configure`) but actually applies to all similarly-named files in the tree (e.g., `PC/pyconfig.h`.) Specifically, any rule with no non-trailing slashes is applied in an "unrooted" way, to files anywhere in the tree. This means that if we write the rules in the most obvious-looking way, then * for specific files we want to ignore that happen to be in subdirectories (like `Modules/config.c`), the rule will work as intended, staying "rooted" to the top of the tree; but * when a specific file we want to ignore happens to be at the root of the repo (like `platform`), then the obvious rule (`platform`) will apply much more broadly than intended: if someone tries to add a file or directory named `platform` somewhere else in the tree, it will unexpectedly get ignored. That's surprising behavior that can make the .gitignore file's behavior feel finicky and unpredictable. To avoid it, we can simply always give a rule "rooted" behavior when that's what's intended, by systematically using leading slashes. Further, to help make the pattern obvious when looking at the file and minimize any need for thinking about the syntax when adding new rules: separate the rules into one group for each type, with brief comments identifying them. For most of these rules it's clear whether they're meant to be rooted or unrooted, but in a handful of cases I've only guessed. In that case the safer default (the choice that won't hide information) is the narrower, rooted meaning, with a leading slash. If for some of these the unrooted meaning is desired after all, it'll be easy to move them to the unrooted section at the top.
* bpo-37424: Avoid a hang in subprocess.run timeout output capture (GH-14490)Gregory P. Smith2019-09-111-0/+5
| | | | | | | Fixes a possible hang when using a timeout on subprocess.run() while capturing output. If the child process spawned its own children or otherwise connected its stdout or stderr handles with another process, we could hang after the timeout was reached and our child was killed when attempting to read final output from the pipes.
* Overhaul datetime documentation (GH-13410)Brad2019-09-111-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a restructuring of the datetime documentation to hopefully make them more user-friendly and approachable to new users without losing any of the detail. Changes include: - Creating dedicated subsections for some concepts such as: - "Constants" - "Naive vs Aware" - "Determining if an Object is Aware" - Give 'naive vs aware' its own subsection - Give 'constants' their own subsection - Overhauling the strftime-strptime section by: - Breaking it into logical, linkable, and digestable parts - Adding a high-level comparison table - Moving the technical detail to bottom: readers come to this section primarily to remind themselves to things: - How do I write the format code for X? - strptime/strftime: which one is which again? - Touching up fromisoformat + isoformat sections by: - Revising fromisoformat + isoformat for date, time, and datetime - Adding basic examples - Enforcing consistency about putting formats (i.e. ``HH:MM``) in double backticks. This was previously done in some places but not all - Putting long 'supported formats', on their own line to improve readability - Moving the 'seealso' section to the top and add a link to dateutil Rationale: This doesn't really belong nested under the 'constants' section. Let readers know right away that datetime is one of several related tools. - Moving common features of several types into one place: Previously, each type went out of its way to note separately that it was hashable and picklable. These can be brought into one single place that is more prominent. - Reducing some verbose explanations to improve readability - Breaking up long paragraphs into digestable chunks - Displaying longer "equivalent to" examples, as short code blocks - Using the dot notation for datetime/time classes: Use :class:`.time` and :class:`.datetime` rather than :class:`time` and :class:`datetime`; otherwise, the generated links will route to the respective modules, not classes. - Rewording the tzinfo class description The top paragraph should get straight to the point of telling the reader what subclasses of tzinfo _do_. Previously, that was hidden in a later paragraph. - Adding a note on .today() versus .now() - Rearranging and expanding example blocks, including: - Moved long, multiline inline examples to standalone examples - Simplified the example block for timedelta arithmetic: - Broke the example into two logical sections: 1. normalization/parameter 'merging' 2. timedelta arithmetic - Reduced the complexity of the some of the examples. Show reasonable, real-world uses cases that are easy to follow along with and progres in difficult slightly. - Broke up the example sections for date and datetime sections by putting the easy examples first, progressing to more esoteric situations and breaking it up into logical sections based on what the methods are doing at a high level. - Simplified the KabulTz example: - Put the class definition itself into a non-REPL block since there is no interactive output involved there - Briefly explained what's happening before launching into the code - Broke the example section into visually separate chunks - Various whitespace, formatting, style and grammar fixes including: - Consistently using backctics for 'date_string' formats - Consistently using one space after periods. - Consistently using bold for vocab terms - Consistently using italics when referring to params: See https://devguide.python.org/documenting/#id4 - Using '::' to lead into code blocks Per https://devguide.python.org/documenting/#source-code, this will let the reader use the 'expand/collapse' top-right button for REPL blocks to hide or show the prompt. - Using consistent captialization schemes - Removing use of the default role - Put 'example' blocks in Markdown subsections This is a combination of 66 commits. See bpo-36960: https://bugs.python.org/issue36960
* bpo-37879: Suppress subtype_dealloc decref when base type is a C heap type ↵Eddie Elizondo2019-09-111-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (GH-15323) The instance destructor for a type is responsible for preparing an instance for deallocation by decrementing the reference counts of its referents. If an instance belongs to a heap type, the type object of an instance has its reference count decremented while for static types, which are permanently allocated, the type object is unaffected by the instance destructor. Previously, the default instance destructor searched the class hierarchy for an inherited instance destructor and, if present, would invoke it. Then, if the instance type is a heap type, it would decrement the reference count of that heap type. However, this could result in the premature destruction of a type because the inherited instance destructor should have already decremented the reference count of the type object. This change avoids the premature destruction of the type object by suppressing the decrement of its reference count when an inherited, non-default instance destructor has been invoked. Finally, an assertion on the Py_SIZE of a type was deleted. Heap types have a non zero size, making this into an incorrect assertion. https://github.com/python/cpython/pull/15323
* bpo-38089: Move Azure Pipelines to latest VM versions and make macOS tests ↵Steve Dower2019-09-101-0/+1
| | | | optional (GH-15851)
* bpo-32424: Deprecate xml.etree.ElementTree.Element.copy() in favor of ↵Gordon P. Hemsley2019-09-101-0/+3
| | | | copy.copy() (GH-12995)
* bpo-38086: Sync importlib.metadata with importlib_metadata 0.21. (GH-15840)Jason R. Coombs2019-09-101-0/+1
| | | https://gitlab.com/python-devs/importlib_metadata/-/tags/0.21
* bpo-38087: Fix case sensitivity in test_pathlib and test_ntpath (GH-15850)Steve Dower2019-09-101-0/+1
|
* bpo-38088: Fixes distutils not finding vcruntime140.dll with only v142 ↵Steve Dower2019-09-101-0/+2
| | | | toolset installed (GH-15849)
* bpo-36781: Optimize sum() for bools. (#13074)Serhiy Storchaka2019-09-101-0/+1
| | | | | | | | * Optimize sum() for bools. * Fix sum([], False). * Add a NEWS entry.
* bpo-38073: Make pwd module PEP-384 compatible (GH-15790)Dino Viehland2019-09-101-0/+1
| | | | | | | | | | Makes the pwd module PEP-384 compatible https://bugs.python.org/issue38073 Automerge-Triggered-By: @tiran
* bpo-38066: Hide internal Stream methods (GH-15762)Andrew Svetlov2019-09-101-0/+2
| | | | | | feed_eof(), feed_data(), set_exception(), and set_transport() are prefixed with underscore now. https://bugs.python.org/issue38066
* bpo-37619: update_one_slot() should not ignore wrapper descriptors for wrong ↵Jeroen Demeyer2019-09-101-0/+3
| | | | type (GH-14836)
* bpo-37251: Removes __code__ check from _is_async_obj. (GH-15830)Lisa Roach2019-09-101-0/+3
|
* bpo-38069: Convert _posixsubprocess to PEP-384 (GH-15780)Dino Viehland2019-09-101-0/+1
| | | | | | | | | | Summary: Eliminate uses of `_Py_IDENTIFIER` from `_posixsubprocess`, replacing them with interned strings. Also tries to find an existing version of the module, which will allow subinterpreters. https://bugs.python.org/issue38069
* bpo-38071: Make termios PEP-384 compatible (GH-15785)Dino Viehland2019-09-101-0/+1
| | | | Make the termios module PEP-384 compatible.
* bpo-38072: PEP-384 grpmodule (GH-15788)Dino Viehland2019-09-101-0/+1
| | | | Make the grp module PEP-384 compliant.
* Skip zoneinfo tests on VxWorks (#13535)hliu02019-09-101-0/+1
|
* bpo-38074: Make zlib extension module PEP-384 compatible (GH-15792)Dino Viehland2019-09-101-0/+1
| | | | Updated zlibmodule.c to be PEP 384 compliant.
* bpo-38076: Make struct module PEP-384 compatible (#15805)Dino Viehland2019-09-101-0/+1
| | | | | | | | | | * PEP-384 _struct * More PEP-384 fixes for _struct Summary: Add a couple of more fixes for `_struct` that were previously missed such as removing `tp_*` accessors and using `PyBytesWriter` instead of calling `PyBytes_FromStringAndSize` with `NULL`. Also added a test to confirm that `iter_unpack` type is still uninstantiable. * 📜🤖 Added by blurb_it.
* bpo-37725: have "make clean" remove PGO task data (#15033)Neil Schemenauer2019-09-101-0/+3
| | | | | Change "clean" makefile target to also clean the program guided optimization (PGO) data. Previously you would have to use "make clean" and "make profile-removal", or "make clobber".
* bpo-25237: Documentation for tkinter modules (GH-1870)Nikhil2019-09-101-0/+1
|
* bpo-38077: IDLE no longer adds 'argv' to the user namespace (GH-15818)Terry Jan Reedy2019-09-101-0/+2
| | | | This only happened when initializing the subprocess to run a module. This recent bug only affected 3.7.4 and 3.8.0b2 to 3.8.0b4.
* bpo-34293: Fix PDF documentation paper size (GH-8585)Jean-François B2019-09-091-0/+1
| | | | | The "A4" pdfs were previously the wrong size due to a change in the options in Sphinx 1.5. See also sphinx-doc/sphinx#5235
* bpo-38049: Add command-line interface for the ast module. (GH-15724)Serhiy Storchaka2019-09-091-0/+1
|
* bpo-38018: Increase code coverage for multiprocessing.shared_memory (GH-15662)Vinay Sharma2019-09-091-0/+1
|
* bpo-37995: Add an option to ast.dump() to produce a multiline output. (GH-15631)Serhiy Storchaka2019-09-091-0/+2
|
* bpo-37840: Fix handling of negative indices in bytearray_getitem() (GH-15250)Sergey Fedoseev2019-09-091-0/+2
|
* bpo-35803: Document and test dir=PathLike for tempfile (GH-11644)Anthony Sottile2019-09-091-0/+2
| | | Co-Authored-By: Ammar Askar <ammar_askar@hotmail.com>
* bpo-36279: Ensure os.wait3() rusage is initialized (GH-15111)Zackery Spytz2019-09-091-0/+1
| | | Co-Authored-By: David Wilson <dw@botanicus.net>
* bpo-20490: Improve circular import error message (GH-15308)Anthony Sottile2019-09-091-0/+2
|
* bpo-38006: Avoid closure in weakref.WeakValueDictionary (GH-15641)Victor Stinner2019-09-091-0/+3
| | | | | weakref.WeakValueDictionary defines a local remove() function used as callback for weak references. This function was created with a closure. Modify the implementation to avoid the closure.
* bpo-37876: Tests for ROT-13 codec (GH-15314)Zeth2019-09-091-0/+1
| | | | The Rot-13 codec is for educational use but does not have unit tests, dragging down test coverage. This adds a few very simple tests.
* Mark files as executable that are meant as scripts. (GH-15354)Greg Price2019-09-093-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | | This is the converse of GH-15353 -- in addition to plenty of scripts in the tree that are marked with the executable bit (and so can be directly executed), there are a few that have a leading `#!` which could let them be executed, but it doesn't do anything because they don't have the executable bit set. Here's a command which finds such files and marks them. The first line finds files in the tree with a `#!` line *anywhere*; the next-to-last step checks that the *first* line is actually of that form. In between we filter out files that already have the bit set, and some files that are meant as fragments to be consumed by one or another kind of preprocessor. $ git grep -l '^#!' \ | grep -vxFf <( \ git ls-files --stage \ | perl -lane 'print $F[3] if (!/^100644/)' \ ) \ | grep -ve '\.in$' -e '^Doc/includes/' \ | while read f; do head -c2 "$f" | grep -qxF '#!' \ && chmod a+x "$f"; \ done