Skip to content

Support PyEval_GetFrameBuiltins() #199

Closed

Description

@skirpichev

It's in the Limited API since v3.13. Not too different from PyEval_GetBuiltins(), which is deprecated.

I think that following should work in v3.10+:

PyObject *
PyEval_GetFrameBuiltins(void)
{   
    return Py_XNewRef(PyEval_GetBuiltins());
}

Activity

  1. added a commit that references this issue on Oct 12, 2026
    ce2d7a4
  2. vstinner commented on Oct 12, 2026

    @vstinner
    Member

    I didn't notice the 3 new functions of PEP 667. I added PyEval_GetFrameLocals(), PyEval_GetFrameGlobals() and PyEval_GetFrameBuiltins() functions with #200.

    The new functions return a strong reference, instead of a borrowed reference.

  3. vstinner commented on Oct 12, 2026

    @vstinner
    Member

    I also completed the list of "not supported" functions: b0feca0. I was surprised that PyEval_GetFrameBuiltins() wasn't in this list before I added it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions