Alyssa Coghlan

Results 501 comments of Alyssa Coghlan

See https://github.com/python/cpython/pull/119769 for further discussion (it may be possible to have `PyEval_GetLocals()` replicate the Python 3.13 `locals()` semantics rather than having to settle for it being the one place that...

We've now identified a few potential resolutions for the discrepancy, and could benefit from a release-manager-or-SC casting vote to resolve a disagreement between @gaogaotiantian and I as to which of...

That resolution sounds like a good option to me. I thought it had been ruled out during in-person discussions in Pittsburgh in favour of the sample code defining it in...

> If you want to fix code, heed the deprecation warning and don't call the function. I'll note that `PyEval_GetLocals` is the one API where I was disappointed we weren't...

As @carljm suggests, my own preferred option is to have `PyEval_GetLocals` be the only API that perpetuates the legacy Python 3.12 semantics, and explicitly deprecate it with folks being pointed...

I would still like to have a C API that's a direct mirror of `locals()` (as it makes the deprecation notice for `PyEval_GetLocals` much easier to write), but I also...

> However, I have some doubts to have a `PyEval_GetLocalsRef()` that behaves differently than `PyEval_GetLocals()` for two versions. I find that very confusing. It isn't ideal, but it's important to...

Note that the beta2 docs cover the impact on `exec()` and other code execution APIs: https://docs.python.org/dev/whatsnew/3.13.html#whatsnew313-locals-semantics It's also called out explicitly in the porting notes: https://docs.python.org/dev/whatsnew/3.13.html#pep667-porting-notes-py Affected functions further have...

Thanks folks. I think that means the beta2 docs are correct as written, but I'll double check them to make sure. @gaogaotiantian As far as the backwards compatibility section in...

@pablogsal Just confirming this point, since the SC comment didn't specifically address it, although it had come up earlier in the thread as something to consider changing: * the C...