summaryrefslogtreecommitdiffstats
path: root/Doc
Commit message (Collapse)AuthorAgeFilesLines
* bpo-32248: Implement importlib.abc.ResourceReader (GH-4892)Brett Cannon2017-12-161-0/+66
|
* Minor wording tweak for itertools documentation (#4893)Raymond Hettinger2017-12-151-2/+2
|
* F-strings docs: link to Format Specifiers (GH-4888)Mariatta2017-12-151-1/+2
| | | Link to the Format Specification Mini Language section from f-strings' documentation.
* bpo-32329: Add versionchanged to -R option doc (#4884)Victor Stinner2017-12-151-0/+3
|
* bpo-32265: Classify class and static methods of builtin types. (#4776)Serhiy Storchaka2017-12-151-0/+8
| | | | Add types.ClassMethodDescriptorType for unbound class methods.
* bpo-32240: Add the const qualifier to declarations of PyObject* array ↵Serhiy Storchaka2017-12-151-1/+1
| | | | arguments. (#4746)
* bpo-28393: Update encoding lookup docs wrt bpo-27938 (#4871)Ville Skyttä2017-12-151-4/+8
|
* bpo-32311: Implement asyncio.create_task() shortcut (#4848)Andrew Svetlov2017-12-151-4/+21
| | | | | * Implement functionality * Add documentation
* bpo-32327: Convert asyncio functions documented as coroutines to coroutines. ↵Yury Selivanov2017-12-151-30/+24
| | | | (#4872)
* bpo-32329: Fix -R option for hash randomization (#4873)Victor Stinner2017-12-141-2/+3
| | | | | | | | | | | | bpo-32329, bpo-32030: * The -R option now turns on hash randomization when the PYTHONHASHSEED environment variable is set to 0 Previously, the option was ignored. * sys.flags.hash_randomization is now properly set to 0 when hash randomization is turned off by PYTHONHASHSEED=0. * _PyCoreConfig_ReadEnv() now reads the PYTHONHASHSEED environment variable. _Py_HashRandomization_Init() now only apply the configuration, it doesn't read PYTHONHASHSEED anymore.
* bpo-32143: add f_fsid to os.statvfs() (#4571)Giuseppe Scrivano2017-12-141-1/+4
| | | Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
* bpo-32314: Implement asyncio.run() (#4852)Yury Selivanov2017-12-141-9/+22
|
* bpo-32297: Few misspellings found in Python source code comments. (#4803)Mike2017-12-141-1/+1
| | | | | | | | * Fix multiple typos in code comments * Add spacing in comments (test_logging.py, test_math.py) * Fix spaces at the beginning of comments in test_logging.py
* bpo-32225: Implementation of PEP 562 (#4731)Ivan Levkivskyi2017-12-142-0/+63
| | | | | Implement PEP 562: module __getattr__ and __dir__. The implementation simply updates module_getattro and module_dir.
* bpo-29469: Move constant folding to AST optimizer (GH-2858)INADA Naoki2017-12-141-0/+3
|
* bpo-30241: implement contextlib.AbstractAsyncContextManager (#1412)Jelle Zijlstra2017-12-142-2/+14
|
* trivial: link updates in documentation (#2765)jimmy2017-12-134-5/+5
|
* bpo-29240: PEP 540: Add a new UTF-8 Mode (#855)Victor Stinner2017-12-135-4/+63
| | | | | | | | | | | | | | | | | | | | | | * Add -X utf8 command line option, PYTHONUTF8 environment variable and a new sys.flags.utf8_mode flag. * If the LC_CTYPE locale is "C" at startup: enable automatically the UTF-8 mode. * Add _winapi.GetACP(). encodings._alias_mbcs() now calls _winapi.GetACP() to get the ANSI code page * locale.getpreferredencoding() now returns 'UTF-8' in the UTF-8 mode. As a side effect, open() now uses the UTF-8 encoding by default in this mode. * Py_DecodeLocale() and Py_EncodeLocale() now use the UTF-8 encoding in the UTF-8 Mode. * Update subprocess._args_from_interpreter_flags() to handle -X utf8 * Skip some tests relying on the current locale if the UTF-8 mode is enabled. * Add test_utf8mode.py. * _Py_DecodeUTF8_surrogateescape() gets a new optional parameter to return also the length (number of wide characters). * pymain_get_global_config() and pymain_set_global_config() now always copy flag values, rather than only copying if the new value is greater than the old value.
* bpo-32284: Fix documentation of BinaryIO and TextIO (#4832)Sebastian Rittau2017-12-131-3/+3
|
* bpo-32230: Set sys.warnoptions with -X dev (#4820)Victor Stinner2017-12-123-13/+38
| | | | | | | | | | | | | | Rather than supporting dev mode directly in the warnings module, this instead adjusts the initialisation code to add an extra 'default' entry to sys.warnoptions when dev mode is enabled. This ensures that dev mode behaves *exactly* as if `-Wdefault` had been passed on the command line, including in the way it interacts with `sys.warnoptions`, and with other command line flags like `-bb`. Fix also bpo-20361: have -b & -bb options take precedence over any other warnings options. Patch written by Nick Coghlan, with minor modifications of Victor Stinner.
* bpo-32241: Add the const qualifire to declarations of umodifiable strings. ↵Serhiy Storchaka2017-12-121-2/+2
| | | | (#4748)
* bpo-31942: Document optional support of start and stop attributes in ↵Nitish Chandra2017-12-121-3/+3
| | | | Sequence.index method (#4277)
* bpo-32227: functools.singledispatch supports registering via type ↵Łukasz Langa2017-12-111-7/+21
| | | | annotations (#4733)
* bpo-32258: Replace 'yield from' to 'await' in asyncio docs (#4779)Andrew Svetlov2017-12-116-72/+60
| | | | | | * Replace 'yield from' to 'await' in asyncio docs * Fix docstrings
* Add asyncio.get_running_loop() function. (#4782)Yury Selivanov2017-12-111-0/+7
|
* bpo-32272: Remove asyncio.async() function. (#4784)Yury Selivanov2017-12-112-9/+0
|
* bpo-22671: Clarify and test default read method implementations (#4568)Sanyam Khurana2017-12-111-5/+8
| | | Original patch written by Martin Panter, enhanced by Sanyam Khurana.
* bpo-32114: Updated the documentation for get_event_loop to reflect the ↵Pablo Galindo2017-12-101-4/+9
| | | | policy change (#4510)
* closes bpo-31650: PEP 552 (Deterministic pycs) implementation (#4575)Benjamin Peterson2017-12-097-4/+158
| | | | | | | | | | | | | | | | | | | | | | | | | Python now supports checking bytecode cache up-to-dateness with a hash of the source contents rather than volatile source metadata. See the PEP for details. While a fairly straightforward idea, quite a lot of code had to be modified due to the pervasiveness of pyc implementation details in the codebase. Changes in this commit include: - The core changes to importlib to understand how to read, validate, and regenerate hash-based pycs. - Support for generating hash-based pycs in py_compile and compileall. - Modifications to our siphash implementation to support passing a custom key. We then expose it to importlib through _imp. - Updates to all places in the interpreter, standard library, and tests that manually generate or parse pyc files to grok the new format. - Support in the interpreter command line code for long options like --check-hash-based-pycs. - Tests and documentation for all of the above.
* bpo-32253: Deprecate with statement and bare await for asyncio locks (GH-4764)Andrew Svetlov2017-12-091-42/+52
| | | | | * Add test for 'with (yield from lock)' * Deprecate with statement for asyncio locks * Document the deprecation
* bpo-32212: Updated logging documentation to make parameter names more ↵Vinay Sajip2017-12-091-20/+21
| | | | consistent with source. (GH-4765)
* bpo-32208: update threading.Semaphore docs and add unit test (#4709)Garrett Berg2017-12-071-13/+13
| | | | | | | | | | * fix issue32208: update threading.Semaphore docs and add unit test to validate correct behavior * add test for blocking * Update threading.rst * semaphore: remove documentation validation tests and move 'return value' test to BaseSemaphore
* bpo-25910: Fixes redirection from http to https (#4674)Sanyam Khurana2017-12-0624-39/+39
|
* Add a missing space in tkinter documentation. (GH-4692)Julien Palard2017-12-051-1/+1
|
* bpo-19610: Warn if distutils is provided something other than a list to some ↵Neil Schemenauer2017-12-052-7/+5
| | | | | | | | | | | | | | | fields (#4685) * Rather than raise TypeError, warn and call list() on the value. * Fix tests, revise NEWS and whatsnew text. * Revise documentation, a string is okay as well. * Ensure 'requires' and 'obsoletes' are real lists. * Test that requires and obsoletes are turned to lists.
* Revert "bpo-32197: Try to fix a compiler error on OS X introduced in ↵Victor Stinner2017-12-041-3/+2
| | | | | | | | | | | | | | | | | | | | | | | bpo-32030. (#4681)" (#4694) * Revert "bpo-32197: Try to fix a compiler error on OS X introduced in bpo-32030. (#4681)" This reverts commit 13badcbc60cdbfae1dba1683fd2fae9d70717143. Re-apply commits: * "bpo-32030: _PyPathConfig_Init() sets home and program_name (#4673)" commit af5a895073c24637c094772b27526b94a12ec897. * "bpo-32030: Fix config_get_program_name() on macOS (#4669)" commit e23c06e2b03452c9aaf0dae52296c85e572f9bcd. * "bpo-32030: Add Python/pathconfig.c (#4668)" commit 0ea395ae964c9cd0f499e2ef0d0030c971201220. * "bpo-32030: Don't call _PyPathConfig_Fini() in Py_FinalizeEx() (#4667)" commit ebac19dad6263141d5db0a2c923efe049dba99d2. * "bpo-32030: Fix Py_GetPath(): init program_name (#4665)" commit 9ac3d8882712c9675c3d2f9f84af6b5729575cde. * Fix compilation error on macOS
* bpo-25054, bpo-1647489: Added support of splitting on zerowidth patterns. ↵Serhiy Storchaka2017-12-042-30/+37
| | | | | | (#4471) Also fixed searching patterns that could match an empty string.
* bpo-31589 : Build PDF using xelatex for better UTF8 support. (#3940)Julien Palard2017-12-021-3/+2
| | | Also addresses doc build failures documented in bpo-32200.
* bpo-32197: Try to fix a compiler error on OS X introduced in bpo-32030. (#4681)Serhiy Storchaka2017-12-021-2/+3
| | | | | | | | | | | | | | | | | | | | | | * Revert "bpo-32030: _PyPathConfig_Init() sets home and program_name (#4673)" This reverts commit af5a895073c24637c094772b27526b94a12ec897. * Revert "bpo-32030: Fix config_get_program_name() on macOS (#4669)" This reverts commit e23c06e2b03452c9aaf0dae52296c85e572f9bcd. * Revert "bpo-32030: Add Python/pathconfig.c (#4668)" This reverts commit 0ea395ae964c9cd0f499e2ef0d0030c971201220. * Revert "bpo-32030: Don't call _PyPathConfig_Fini() in Py_FinalizeEx() (#4667)" This reverts commit ebac19dad6263141d5db0a2c923efe049dba99d2. * Revert "bpo-32030: Fix Py_GetPath(): init program_name (#4665)" This reverts commit 9ac3d8882712c9675c3d2f9f84af6b5729575cde.
* bpo-32030: _PyPathConfig_Init() sets home and program_name (#4673)Victor Stinner2017-12-021-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | _PyPathConfig_Init() now also initialize home and program_name: * Rename existing _PyPathConfig_Init() to _PyPathConfig_Calculate(). Add a new _PyPathConfig_Init() function in pathconfig.c which handles the _Py_path_config variable and call _PyPathConfig_Calculate(). * Add home and program_name fields to _PyPathConfig.home * _PyPathConfig_Init() now initialize home and program_name from main_config * Py_SetProgramName(), Py_SetPythonHome() and Py_GetPythonHome() now calls Py_FatalError() on failure, instead of silently ignoring failures. * config_init_home() now gets directly _Py_path_config.home to only get the value set by Py_SetPythonHome(), or NULL if Py_SetPythonHome() was not called. * config_get_program_name() now gets directly _Py_path_config.program_name to only get the value set by Py_SetProgramName(), or NULL if Py_SetProgramName() was not called. * pymain_init_python() doesn't call Py_SetProgramName() anymore, _PyPathConfig_Init() now always sets the program name * Call _PyMainInterpreterConfig_Read() in pymain_parse_cmdline_envvars_impl() to control the memory allocator * C API documentation: it's no more safe to call Py_GetProgramName() before Py_Initialize().
* bpo-10544: Deprecate "yield" in comprehensions and generator expressions. ↵Serhiy Storchaka2017-12-012-8/+65
| | | | | | | | | | | | | | (GH-4579) The current behaviour of yield expressions inside comprehensions and generator expressions is essentially an accident of implementation - it arises implicitly from the way the compiler handles yield expressions inside nested functions and generators. Since the current behaviour wasn't deliberately designed, and is inherently confusing, we're deprecating it, with no current plans to reintroduce it. Instead, our advice will be to use a named nested generator definition for cases where this behaviour is desired.
* bpo-20891: Fix PyGILState_Ensure() (#4650)Victor Stinner2017-11-301-2/+3
| | | | | | | When PyGILState_Ensure() is called in a non-Python thread before PyEval_InitThreads(), only call PyEval_InitThreads() after calling PyThreadState_New() to fix a crash. Add an unit test in test_embed.
* bpo-32101: Add PYTHONDEVMODE environment variable (#4624)Victor Stinner2017-11-304-4/+26
| | | | | | * bpo-32101: Add sys.flags.dev_mode flag Rename also the "Developer mode" to the "Development mode". * bpo-32101: Add PYTHONDEVMODE environment variable Mention it in the development chapiter.
* bpo-32121: Add most_recent_first parameter to tracemalloc.Traceback.format ↵Jesse-Bakker2017-11-292-6/+16
| | | | | | | | (#4534) * Add most_recent_first parameter to tracemalloc.Traceback.format to allow reversing the order of the frames in the output * Reversed default sorting of tracemalloc.Traceback frames * Allowed negative limit, truncating from the other side.
* bpo-32030: Rework memory allocators (#4625)Victor Stinner2017-11-292-19/+47
| | | | | | | | | | | | | | | | | | | | * Fix _PyMem_SetupAllocators("debug"): always restore allocators to the defaults, rather than only caling _PyMem_SetupDebugHooks(). * Add _PyMem_SetDefaultAllocator() helper to set the "default" allocator. * Add _PyMem_GetAllocatorsName(): get the name of the allocators * main() now uses debug hooks on memory allocators if Py_DEBUG is defined, rather than calling directly malloc() * Document default memory allocators in C API documentation * _Py_InitializeCore() now fails with a fatal user error if PYTHONMALLOC value is an unknown memory allocator, instead of failing with a fatal internal error. * Add new tests on the PYTHONMALLOC environment variable * Add support.with_pymalloc() * Add the _testcapi.WITH_PYMALLOC constant and expose it as support.with_pymalloc(). * sysconfig.get_config_var('WITH_PYMALLOC') doesn't work on Windows, so replace it with support.with_pymalloc(). * pythoninfo: add _testcapi collector for pymem
* bpo-32107 - Improve MAC address calculation and fix test_uuid.py (#4600)Barry Warsaw2017-11-281-4/+12
| | | | | | | | ``uuid.getnode()`` now preferentially returns universally administered MAC addresses if available, over locally administered MAC addresses. This makes a better guarantee for global uniqueness of UUIDs returned from ``uuid.uuid1()``. If only locally administered MAC addresses are available, the first such one found is returned. Also improve internal code style by being explicit about ``return None`` rather than falling off the end of the function. Improve the test robustness.
* Use raw strings in the re module examples. (#4616)Serhiy Storchaka2017-11-281-4/+4
|
* bpo-32154: Remove asyncio.windows_utils.socketpair (#4609)Victor Stinner2017-11-284-12/+9
|
* bpo-32071: Fix regression and add What's New entry (#4589)Jonas Haag2017-11-281-0/+9
| | | | | | * bpo-32071: Fix an undocumented behaviour regression * bpo-32071: Add 3.7 release note entry for unittest -k
* bpo-32046: Update 2to3 when converts operator.isCallable(obj). (#4417)Dong-hee Na2017-11-281-1/+1
|