Skip to content
Permalink
master

Commits on Feb 21, 2021

  1. bpo-43269: Clean up sqlite3 file scope (GH-24578)

    erlend-aasland committed Feb 21, 2021

Commits on Feb 20, 2021

  1. 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.
    pablogsal committed Feb 20, 2021
  2. 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().
    vstinner committed Feb 20, 2021
  3. Fix typo in launcher.c (GH-24497)

    eltociear committed Feb 20, 2021
  4. Fix typo in dis module doc (GH-24509)

    iritkatriel committed Feb 20, 2021
  5. bpo-43042: Augment tutorial sentence (GH-24514)

    Calling same function also gets new local namespace.
    terryjreedy committed Feb 20, 2021

Commits on Feb 19, 2021

  1. bpo-42825: Enable /OPT:REF (GH-24098)

    We explicitly disable /OPT:ICF as some manual optimisations depend on some functions still having distinct pointers (such as wrap_binary_func and wrap_binary_func_l).
    Austin-Lamb committed Feb 19, 2021
  2. closes bpo-43266: Improve array formatting. (GH-24573)

    erlend-aasland committed Feb 19, 2021
  3. 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.
    nw0 committed Feb 19, 2021
  4. bpo-43268: local_clear() uses _PyInterpreterState_GET() (GH-24583)

    Cleanup also the code.
    vstinner committed Feb 19, 2021
  5. bpo-43268: Pass interp rather than tstate to internal functions (GH-2…

    …4580)
    
    Pass the current interpreter (interp) rather than the current Python
    thread state (tstate) to internal functions which only use the
    interpreter.
    
    Modified functions:
    
    * _PyXXX_Fini() and _PyXXX_ClearFreeList() functions
    * _PyEval_SignalAsyncExc(), make_pending_calls()
    * _PySys_GetObject(), sys_set_object(), sys_set_object_id(), sys_set_object_str()
    * should_audit(), set_flags_from_config(), make_flags()
    * _PyAtExit_Call()
    * init_stdio_encoding()
    * etc.
    vstinner committed Feb 19, 2021
  6. bpo-43270: Remove private _PyErr_OCCURRED() macro (GH-24579)

    Remove the private _PyErr_OCCURRED() macro: use the public
    PyErr_Occurred() function instead.
    
    CPython internals must use the internal _PyErr_Occurred(tstate)
    function instead: it is the most efficient way to check if an
    exception was raised.
    vstinner committed Feb 19, 2021
  7. bpo-43268: Remove abusive usage of tstate in sysmodule.c (#24581)

    Remove explicit tstate usage in sysmodule.c when it's only used raise
    exceptions: get it implicitly using PyErr_XXX() functions.
    vstinner committed Feb 19, 2021
  8. bpo-43268: _Py_IsMainInterpreter() now expects interp (GH-24577)

    The _Py_IsMainInterpreter() function now expects interp rather than
    tstate.
    vstinner committed Feb 19, 2021
  9. bpo-40522: Replace PyThreadState_GET() with PyThreadState_Get() (GH-2…

    …4575)
    
    Use directly the PyThreadState_Get() function in public header files,
    since PyThreadState_GET() macro is just an alias to it in pratice in
    these files.
    vstinner committed Feb 19, 2021
  10. bpo-43268: Replace _PyThreadState_GET() with _PyInterpreterState_GET() (

    GH-24576)
    
    Replace _PyThreadState_GET() with _PyInterpreterState_GET() in
    functions which only need the current interpreter, but don't need the
    current Python thread state.
    
    Replace also _PyThreadState_UncheckedGet() with _PyThreadState_GET()
    in faulthandler.c, since _PyThreadState_UncheckedGet() is just an
    alias to _PyThreadState_GET() in practice.
    vstinner committed Feb 19, 2021
  11. bpo-43258: Make sqlite3 callback functions static (GH-24574)

    erlend-aasland committed Feb 19, 2021
  12. closes bpo-43254: Fix *snprintf() man page refs. (GH-24563)

    erlend-aasland committed Feb 19, 2021
  13. bpo-39448: Add regen-frozen makefile target. (GH-18174)

    Add the "regen-frozen" makefile target that regenerates the code for the
    frozen __hello__ module.
    nascheme committed Feb 19, 2021

Commits on Feb 18, 2021

  1. 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
    ucodery committed Feb 18, 2021
  2. 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.
    vstinner committed Feb 18, 2021
  3. 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.
    vstinner committed Feb 18, 2021

Commits on Feb 17, 2021

  1. bpo-35134: Move Include/{pyarena.h,pyctype.h} to Include/cpython/ (GH…

    …-24550)
    
    Move non-limited C API headers pyarena.h and pyctype.h
    into Include/cpython/ directory.
    nw0 committed Feb 17, 2021
  2. bpo-40170: Always define PyExceptionClass_Name() as a function (GH-24553

    )
    
    Remove macro variant of PyExceptionClass_Name().
    erlend-aasland committed Feb 17, 2021
  3. 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.
    vstinner committed Feb 17, 2021
  4. Update urllib2.rst (GH-24236)

    fixed a minor glitch in the order of two words.
    creich committed Feb 17, 2021

Commits on Feb 16, 2021

  1. bpo-35134, Include: Move pytime.h to cpython/pytime.h (GH-23988)

    This change is backward compatible since C extension modules
    must not include "pytime.h" directly, but only include "Python.h".
    nw0 committed Feb 16, 2021
  2. bpo-43155: Add PyCMethod_New to PC/python3dll.c (GH-24500)

    ZackerySpytz committed Feb 16, 2021
Older