summaryrefslogtreecommitdiffstats
path: root/Python
Commit message (Collapse)AuthorAgeFilesLines
* [3.5] bpo-29778: Ensure python3.dll is loaded from correct locations when ↵Steve Dower2020-08-041-2/+0
| | | | | Python is embedded (GH-21297) (#21377) bpo-29778: Ensure python3.dll is loaded from correct locations when Python is embedded.
* Version bump & copyright year update for 3.5.7rc1.v3.5.7rc1Larry Hastings2019-03-041-1/+1
|
* Bump version and copyright year for 3.5.5rc1.Larry Hastings2018-01-231-1/+1
|
* bpo-31095: fix potential crash during GC (GH-2974) (#3196)INADA Naoki2017-09-261-0/+2
| | | (cherry picked from commit a6296d34a478b4f697ea9db798146195075d496c)
* [3.5] Backport bpo-30876 (GH-2639), bpo-18018 and bpo-26367. (#2677)Serhiy Storchaka2017-07-232-373/+368
| | | | | | | | | | | | | | | | * bpo-30876: Relative import from unloaded package now reimports the package instead of failing with SystemError. Relative import from non-package now fails with ImportError rather than SystemError. (cherry picked from commit 8a9cd20edca7d01b68292036029ae3735ce65edd) * bpo-18018: Import raises ImportError instead of SystemError if a relative import is attempted without a known parent package. * bpo-26367: importlib.__init__() raises ImportError like builtins.__import__() when ``level`` is specified but without an accompanying package specified.
* [3.5] bpo-13617: Reject embedded null characters in wchar* strings. ↵Serhiy Storchaka2017-06-282-8/+19
| | | | | | | | | | (GH-2302) (#2463) Based on patch by Victor Stinner. Add private C API function _PyUnicode_AsUnicode() which is similar to PyUnicode_AsUnicode(), but checks for null characters.. (cherry picked from commit f7eae0adfcd4c50034281b2c69f461b43b68db84)
* [3.5] bpo-30765: Avoid blocking when PyThread_acquire_lock() is asked not to ↵Antoine Pitrou2017-06-261-45/+50
| | | | | | | | | | | | | (GH-2403) (#2419) * bpo-30765: Avoid blocking when PyThread_acquire_lock() is asked not to lock This is especially important if PyThread_acquire_lock() is called reentrantly (for example from a signal handler). * Update 2017-06-26-14-29-50.bpo-30765.Q5iBmf.rst * Avoid core logic when taking the mutex failed. (cherry picked from commit f84ac420c2af98339678744953869cad3c253281)
* [3.5] bpo-30626: Fix error handling in PyImport_Import(). (GH-2103) (#2222)Serhiy Storchaka2017-06-151-2/+6
| | | | | In rare circumstances PyImport_Import() could return NULL without raising an error. (cherry picked from commit 145541c)
* [3.5] bpo-30567: Fix refleak in sys.getwindowsversion (GH-1940) (#1971)Serhiy Storchaka2017-06-061-4/+4
| | | (cherry picked from commit 48fb766)
* bpo-30281: Fix the default value for stop in PySlice_Unpack() (#1530) (#1480)Xiang Zhang2017-05-101-1/+1
|
* bpo-30225: Fix is_valid_fd() on macOS Tiger (#1443) (#1450)Victor Stinner2017-05-041-0/+9
| | | | | | is_valid_fd() now uses fstat() instead of dup() on macOS to return 0 on a pipe when the other side of the pipe is closed. fstat() fails with EBADF in that case, whereas dup() succeed. (cherry picked from commit 1c4670ea0cc3d208121af11b9b973e6bb268e570)
* bpo-29935: Fixed error messages in the index() method of tuple, list and ↵Serhiy Storchaka2017-03-301-5/+21
| | | | | | | deque (#887) (#907) (#909) when pass indices of wrong type. (cherry picked from commit d4edfc9abffca965e76ebc5957a92031a4d6c4d4) (cherry picked from commit bf4bb2e43030661e568d5d4b046e8b9351cc164c)
* [3.5] bpo-8256: Fixed possible failing or crashing input() (#642)Serhiy Storchaka2017-03-121-5/+16
| | | | | | | if attributes "encoding" or "errors" of sys.stdin or sys.stdout are not set or are not strings. (cherry picked from commit c2cf12857187aa147c268651f10acd6da2c9cb74)
* bpo-29746: Update marshal docs to Python 3. (#547) (#630)Serhiy Storchaka2017-03-121-14/+12
| | | (cherry picked from commit c611a5b1d4fab0123bf622f06c3bfa510221dc32)
* bpo-29770: remove outdated PYO related info (GH-590) (GH-613)Xiang Zhang2017-03-111-1/+1
|
* [3.5] bpo-29537: Tolerate legacy invalid bytecode (#169)Nick Coghlan2017-03-084-2597/+2662
| | | | | | | | | | | | | | | | | | bpo-27286 fixed a problem where BUILD_MAP_UNPACK_WITH_CALL could be emitted with an incorrect oparg value, causing the eval loop to access the wrong stack entry when attempting to read the function name. The associated magic number change caused significant problems when attempting to upgrade to 3.5.3 for anyone that relies on pre-cached bytecode remaining valid across maintenance releases. This patch restores the ability to import legacy bytecode generated by 3.5.0, 3.5.1 or 3.5.2, and modifies the eval loop to avoid any harmful consequences from the potentially malformed legacy bytecode. Original import patch by Petr Viktorin, eval loop patch by Serhiy Storchaka, and tests and integration by Nick Coghlan.
* [3.5] bpo-27593: Get SCM build info from git instead of hg. (#446) (#454) (#455)Ned Deily2017-03-041-3/+3
| | | | | | | | | | | | * bpo-27593: Get SCM build info from git instead of hg. (#446) sys.version and the platform module python_build(), python_branch(), and python_revision() functions now use git information rather than hg when building from a repo. Based on original patches by Brett Cannon and Steve Dower. (cherry picked from commit 5c4b0d063aba0a68c325073f5f312a2c9f40d178) (cherry picked from commit 95c50e5aed9e5683676e18349dd94b11901a66b3)
* bpo-29655: Fixed possible reference leaks in `import *`. (#301) (#349)Berker Peksag2017-02-271-1/+4
| | | | | Patch by Matthias Bussonnier. (cherry picked from commit 160edb43571311a3785785c1dfa784afc52d87be)
* bpo-28598: Support __rmod__ for RHS subclasses of str in % string formatting ↵Martijn Pieters2017-02-271-3/+9
| | | | operations (#94)
* Issue #26729: Fixed __text_signature__ for sorted().Serhiy Storchaka2017-01-231-1/+1
| | | | Patch by Erik Welch.
* Issue #29157: Prefer getrandom() over getentropy()Victor Stinner2017-01-091-200/+294
| | | | | | | | | | | Copy and then adapt Python/random.c from default branch. Difference between 3.5 and default branches: * Python 3.5 only uses getrandom() in non-blocking mode: flags=GRND_NONBLOCK * If getrandom() fails with EAGAIN: py_getrandom() immediately fails and remembers that getrandom() doesn't work. * Python 3.5 has no _PyOS_URandomNonblock() function: _PyOS_URandom() works in non-blocking mode on Python 3.5
* only include sys/random.h if it seems like it might have something useful ↵Benjamin Peterson2017-01-021-1/+1
| | | | (#29057)
* merge 3.4Benjamin Peterson2017-01-021-1/+1
|\
| * merge 3.3Benjamin Peterson2017-01-021-1/+1
| |\
| | * ring in 2017 for PythonBenjamin Peterson2017-01-021-1/+1
| | |
* | | add a specific configure check for sys/random.h (closes #28932)Benjamin Peterson2016-12-201-1/+1
| | |
* | | Issue #25677: Correct syntax error caret for indented blocks.Martin Panter2016-12-112-5/+2
| | | | | | | | | | | | Based on patch by Michael Layzell.
* | | Issue #28512: Fixed setting the offset attribute of SyntaxError bySerhiy Storchaka2016-12-111-8/+4
| | | | | | | | | | | | PyErr_SyntaxLocationEx() and PyErr_SyntaxLocationObject().
* | | Issue #28715: Added error checks for PyUnicode_AsUTF8().Serhiy Storchaka2016-11-202-3/+9
| | |
* | | Issue #28701: Replace _PyUnicode_CompareWithId with _PyUnicode_EqualToASCIIId.Serhiy Storchaka2016-11-162-2/+2
| | | | | | | | | | | | | | | | | | The latter function is more readable, faster and doesn't raise exceptions. Based on patch by Xiang Zhang.
* | | Issue #28701: Replace PyUnicode_CompareWithASCIIString with ↵Serhiy Storchaka2016-11-167-31/+25
| | | | | | | | | | | | | | | | | | _PyUnicode_EqualToASCIIString. The latter function is more readable, faster and doesn't raise exceptions.
* | | Issue #28676: Prevent missing 'getentropy' declaration warning on macOS.Ned Deily2016-11-121-2/+3
| | | | | | | | | | | | Patch by Gareth Rees.
* | | Fixed possible abort in ceval loop if _PyUnicode_FromId() fails.Serhiy Storchaka2016-11-081-1/+1
| | | | | | | | | | | | Every opcode should end with DISPATCH() or goto error.
* | | Issue #28616: Correct help for sys.version_info releaselevel component.Ned Deily2016-11-041-1/+1
| | | | | | | | | | | | Patch by Anish Tambe.
* | | Issue #28410: Keep the traceback of original exception in ↵Serhiy Storchaka2016-10-211-1/+4
| | | | | | | | | | | | _PyErr_ChainExceptions().
* | | Issue #23782: Fixed possible memory leak in _PyTraceback_Add() and exceptionSerhiy Storchaka2016-10-181-20/+26
| | | | | | | | | | | | loss in PyTraceBack_Here().
* | | Issue #28257: Improved error message when pass a non-mapping as a var-keywordSerhiy Storchaka2016-10-071-4/+17
| | | | | | | | | | | | argument.
* | | Issue #24098: Fixed possible crash when AST is changed in process ofSerhiy Storchaka2016-10-071-0/+216
| | | | | | | | | | | | compiling it.
* | | Issue #27942: String constants now interned recursively in tuples and ↵Serhiy Storchaka2016-09-302-867/+865
| | | | | | | | | | | | frozensets.
* | | Silence GCC warning.Serhiy Storchaka2016-09-221-2/+2
| | | | | | | | | | | | The code was correct, but GCC is not enough clever.
* | | Catch EPERM error in py_getrandom()Victor Stinner2016-09-201-7/+8
| | | | | | | | | | | | | | | Issue #27955: Fallback on reading /dev/urandom device when the getrandom() syscall fails with EPERM, for example when blocked by SECCOMP.
* | | Cleanup random.cVictor Stinner2016-09-201-28/+53
| | | | | | | | | | | | | | | | | | | | | Issue #27955: modify py_getrnadom() and dev_urandom() * Add comments from Python 3.7 * PEP 7 style: add {...}
* | | Issue #27932: Prevent memory leak in win32_ver().Steve Dower2016-09-181-0/+37
| | |
* | | improve type-safe of and prevent double-frees in get_locale_info (#28119)Benjamin Peterson2016-09-141-17/+9
| | |
* | | Issue #26020: Fix evaluation order for set literalsRaymond Hettinger2016-09-081-2/+4
| | |
* | | Issue #27895: Spelling fixes (Contributed by Ville Skyttä).Martin Panter2016-09-072-2/+2
| | |
* | | [backport to 3.5] - issue26896 - Disambiguate uses of "importer" with "finder".Senthil Kumaran2016-09-071-3/+4
| | |
* | | Issue 27936: Fix inconsistent round() behavior between float and intRaymond Hettinger2016-09-031-1/+1
| | |
* | | Issue #27909: Fix INCREF for possible NULL valueRaymond Hettinger2016-08-311-1/+1
| | |
* | | Issue 19504: Change "customise" to "customize" American spelling.Raymond Hettinger2016-08-261-2/+2
| | |