summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* bpo-36298: Raise ModuleNotFoundError in pyclbr when a module can't be found ↵Brett Cannon2019-03-223-4/+29
| | | | | | | | (GH-12358) Before, an `AttributeError` was raised due to trying to access an attribute that exists on specs but having received `None` instead for a non-existent module. https://bugs.python.org/issue36298
* bpo-35155: clarify protocol handler method naming (GH-10313)Denton Liu2019-03-221-19/+39
| | | | | | | Clarify that the naming of protocol handler methods shouldn't be literally called "protocol" but should be named after the actual protocol. https://bugs.python.org/issue35155
* bpo-30670: Add pp function to the pprint module (GH-11769)Rémi Lapeyre2019-03-225-35/+84
|
* asyncio: PendingDeprecationWarning -> DeprecationWarning (GH-12494)Inada Naoki2019-03-223-13/+13
| | | `Task.current_task()` and `Task.all_tasks()` will be removed in 3.9.
* bpo-21269: Provide args and kwargs attributes on mock call objects GH11807Kumar Akshay2019-03-225-11/+51
|
* Raise the timeout in test_multiprocessing_* for slow buildbots (GH-12489)Pablo Galindo2019-03-221-1/+1
|
* bpo-35284: Fix the error handling in the compiler's compiler_call(). (GH-10625)Zackery Spytz2019-03-221-2/+5
| | | | | compiler_call() needs to check if an error occurred during the maybe_optimize_method_call() call.
* bpo-36398: Fix a possible crash in structseq_repr(). (GH-12492)Zackery Spytz2019-03-222-1/+2
| | | | | If the first PyUnicode_DecodeUTF8() call fails in structseq_repr(), _PyUnicodeWriter_Dealloc() will be called on an uninitialized _PyUnicodeWriter.
* bpo-36256: Fix bug in parsermodule when parsing if statements (GH-12477)Pablo Galindo2019-03-213-5/+23
| | | | | | bpo-36256: Fix bug in parsermodule when parsing if statements In the parser module, when validating nodes before starting the parsing with to create a ST in "parser_newstobject" there is a problem that appears when two arcs in the same DFA state has transitions with labels with the same type. For example, the DFA for if_stmt has a state with two labels with the same type: "elif" and "else" (type NAME). The algorithm tries one by one the arcs until the label that starts the arc transition has a label with the same type of the current child label we are trying to accept. In this case, the arc for "elif" comes before the arc for "else"and passes this test (because the current child label is "else" and has the same type as "elif"). This lead to expecting a namedexpr_test (305) instead of a colon (11). The solution is to compare also the string representation (in case there is one) of the labels to see if the transition that we have is the correct one.
* Fix registry key for Windows SDK detection (GH-12445)Isuru Fernando2019-03-211-1/+1
|
* bpo-35978: Correctly skips venv tests in venvs (GH-12220)Steve Dower2019-03-212-12/+22
| | | Also fixes venvs from the build directory on Windows.
* bpo-36245: Avoid problems when building in a directory containing spaces. ↵Jess2019-03-211-3/+3
| | | | (GH-12241)
* Fix table formatting in itertools doc (GH-12228)Benedikt Werner2019-03-211-4/+9
|
* bpo-36268: Change default tar format to pax from GNU. (GH-12355)CAM Gerlach2019-03-215-10/+30
|
* bpo-36385: Add ``elif`` sentence on to avoid multiple ``if`` (GH-12478)Emmanuel Arias2019-03-211-2/+2
| | | | | | | | | | | Currently, when arguments on Parser/asdl_c.py are parsed ``ìf`` sentence is used. This PR Propose to use ``elif`` to avoid multiple evaluting of the ifs. https://bugs.python.org/issue36385
* bpo-36324: NormalDist() add more tests and update comments (GH-12476)Raymond Hettinger2019-03-201-24/+44
| | | | | | | * Improve coverage. * Note inherent limitations of the accuracy tests https://bugs.python.org/issue36324
* bpo-36285: Fix integer overflow in the array module. (GH-12317)sth2019-03-203-4/+146
|
* bpo-36312: Fix decoders for some code pages. (GH-12369)Serhiy Storchaka2019-03-203-5/+27
|
* bpo-8677: use PY_DWORD_MAX instead of INT_MAX (GH-12469)Inada Naoki2019-03-201-5/+3
|
* bpo-8677: use PY_SSIZE_T_CLEAN in PC/winreg.c (GH-12466)Inada Naoki2019-03-201-0/+6
|
* bpo-8677: use PY_SSIZE_T_CLEAN in socketmodule.c (GH-12467)Inada Naoki2019-03-201-1/+2
|
* bpo-8677: use PY_SSIZE_T_CLEAN in Modules/_gdbmodule.c (GH-12464)Inada Naoki2019-03-201-9/+27
|
* bpo-36374: Fix a possible null pointer dereference (GH-12449)Zackery Spytz2019-03-202-1/+3
| | | https://bugs.python.org/issue36374
* bpo-36301: Add _PyPreCmdline internal API (GH-12458)Victor Stinner2019-03-203-47/+99
| | | | _PyCoreConfig_ReadFromArgv() now reuses the code parsing command line options from preconfig.c.
* bpo-23984: Improve descriptor documentation (GH-1034)Shubham Aggarwal2019-03-201-2/+2
| | | https://bugs.python.org/issue23984
* bpo-36356: Fix _PyCoreConfig_Read() (GH-12454)Victor Stinner2019-03-201-23/+32
| | | Don't override parameters which are already set by the user.
* bpo-36301: Add _PyRuntime.pre_initialized (GH-12457)Victor Stinner2019-03-206-25/+75
| | | | | | | | | * Add _PyRuntime.pre_initialized: set to 1 when Python is pre-initialized * Add _Py_PreInitialize() and _Py_PreInitializeFromPreConfig(). * _PyCoreConfig_Read() now calls _Py_PreInitialize(). * Move _PyPreConfig_GetGlobalConfig() and _PyCoreConfig_GetGlobalConfig() calls from main.c to preconfig.c and coreconfig.c.
* bpo-36362: Avoid unused variables when HAVE_DYNAMIC_LOADING is not defined ↵Stéphane Wirtel2019-03-191-2/+3
| | | | | (GH-12430) https://bugs.python.org/issue36362
* bpo-36365: Rewrite structseq_repr() using _PyUnicodeWriter (GH-12440)Victor Stinner2019-03-192-58/+69
| | | | | No longer limit repr(structseq) to 512 bytes. Use _PyUnicodeWriter for better performance and to write directly Unicode rather than encoding repr() value to UTF-8 and then decoding from UTF-8.
* bpo-35388: Fix _PyRuntime_Finalize() (GH-12443)Victor Stinner2019-03-191-3/+4
| | | | | Calling _PyRuntime_Initialize() after _PyRuntime_Finalize() now re-initializes _PyRuntime structure. Previously, _PyRuntime_Initialize() did nothing in that case.
* bpo-36324: Improved code formatting for the NormalDist.inv_cdf rational ↵Raymond Hettinger2019-03-191-46/+48
| | | | | approximation (GH-12448) https://bugs.python.org/issue36324
* NormalDist.inv_cdf(): In-line constants because the variable names were not ↵Raymond Hettinger2019-03-191-59/+46
| | | | informative (GH-12446)
* bpo-36236: Fix _PyPathConfig_ComputeSysPath0() for empty argv (GH-12441)Victor Stinner2019-03-191-55/+63
| | | | | * _PyPathConfig_ComputeSysPath0() now returns 0 if argv is empty. * Cleanup also _PyPathConfig_ComputeSysPath0() code: move variables definitions closer to where they are used.
* bpo-36367: Free buffer if realloc fails in tokenize.c (GH-12442)Pablo Galindo2019-03-191-2/+8
|
* bpo-36236: Handle removed cwd at Python init (GH-12424)Victor Stinner2019-03-195-28/+51
| | | | | | | | At Python initialization, the current directory is no longer prepended to sys.path if it has been removed. Rename _PyPathConfig_ComputeArgv0() to _PyPathConfig_ComputeSysPath0() to avoid confusion between argv[0] and sys.path[0].
* bpo-36356: pymain_free() calls _PyRuntime_Finalize() (GH-12435)Victor Stinner2019-03-192-0/+3
| | | | Ensure that _PyRuntime_Finalize() is always call. This change fix a few memory leaks when running "python3 -V".
* bpo-36356: Release Unicode interned strings on Valgrind (#12431)Victor Stinner2019-03-193-29/+42
| | | | | | | | | | | When Python is compiled with Valgrind support, release Unicode interned strings at exit in _PyUnicode_Fini(). * Rename _Py_ReleaseInternedUnicodeStrings() to unicode_release_interned() and make it private. * unicode_release_interned() is now called from _PyUnicode_Fini(): it must be called with a running Python thread state for TRASHCAN, it cannot be called from pymain_free(). * Don't display statistics on interned strings at exit anymore
* bpo-36333, bpo-36356: Fix _PyEval_FiniThreads() (GH-12432)Victor Stinner2019-03-191-2/+11
| | | _PyEval_FiniThreads() now free the pending lock.
* bpo-8677: use PY_SSIZE_T_CLEAN in sqlite (GH-12434)Inada Naoki2019-03-199-0/+9
| | | | Modules/_sqlite/cursor.c uses "y#" format. It didn't declare PY_SSIZE_T_CLEAN, but the argument is Py_ssize_t already.
* bpo-36333: Fix leak _PyRuntimeState_Fini (GH-12400)Stéphane Wirtel2019-03-192-0/+6
|
* bpo-36356: Fix memory leak in _PyPreConfig_Read() (GH-12425)btharper2019-03-192-0/+2
| | | _PyPreConfig_Read() now free 'old_old' at exit.
* Add docstrings to the arithmetic methods in NormalDist() (GH-12426)Raymond Hettinger2019-03-191-14/+44
|
* bpo-36324: Add inv_cdf() to statistics.NormalDist() (GH-12377)Raymond Hettinger2019-03-194-0/+182
|
* bpo-36352: Avoid hardcoded MAXPATHLEN size in getpath.c (GH-12423)Victor Stinner2019-03-194-157/+245
| | | | * Use Py_ARRAY_LENGTH() rather than hardcoded MAXPATHLEN in getpath.c. * Pass string length to functions modifying strings.
* bpo-36301: Error if decoding pybuilddir.txt fails (GH-12422)Victor Stinner2019-03-195-16/+32
| | | | | | | | Python initialization now fails if decoding pybuilddir.txt configuration file fails at startup. _PyPathConfig_Calculate() now reports memory allocation failure and decoding error on decoding pybuilddir.txt content from UTF-8/surrogateescape.
* bpo-36352: Add error handling to getpath.c (GH-12421)Victor Stinner2019-03-181-69/+233
| | | | Replace Py_FatalError() with _PyInitError to let the caller handle the fatal error.
* bpo-36301: Fix Py_Main() memory leaks (GH-12420)Victor Stinner2019-03-183-2/+12
| | | | | | | | | | bpo-36301, bpo-36333: * Fix memory allocator used by _PyPathConfig_ClearGlobal(): force the default allocator. * _PyPreConfig_ReadFromArgv(): free init_ctype_locale memory. * pymain_main(): call pymain_free() on init error Co-Authored-By: Stéphane Wirtel <stephane@wirtel.be>
* bpo-36292: Mark unreachable code as such in long bitwise ops (GH-12333)stratakis2019-03-181-4/+2
|
* bpo-36320: Switch typing.NamedTuple from OrderedDict to regular dict (GH-12396)Raymond Hettinger2019-03-184-13/+28
| | | | | | Also, deprecate the *_field_types* attributes which duplicated the information in *\__annotations__*. https://bugs.python.org/issue36320
* bpo-36352: Clarify fileutils.h documentation (GH-12406)Victor Stinner2019-03-182-17/+30
| | | | | | | The last parameter of _Py_wreadlink(), _Py_wrealpath() and _Py_wgetcwd() is a length, not a size: number of characters including the trailing NUL character. Enhance also documentation of error conditions.