Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate PyTracebackObject struct #96709

Closed
5 tasks
kumaraditya303 opened this issue Sep 9, 2022 · 4 comments
Closed
5 tasks

Deprecate PyTracebackObject struct #96709

kumaraditya303 opened this issue Sep 9, 2022 · 4 comments
Assignees
Labels
3.12 bugs and security fixes type-feature A feature request or enhancement

Comments

@kumaraditya303
Copy link
Contributor

See https://discuss.python.org/t/leaky-abstractions-and-cpython-performance/18392 for discussion.


The entire struct would be deprecated under this issue. For deprecating PyTracebackObject the following changes will be performed under this issue in 3.12:

  • Mark the entire struct with Py_DEPRECATED(3.12)
  • Add C API function to access tb_lineno in C.
  • Document the changes in What's New with fallback code snippets for older versions.

Changes in 3.14:

  • The struct would be removed from the public C headers and moved to the internal C API.
  • The optimizations would be implemented.
@kumaraditya303 kumaraditya303 added type-feature A feature request or enhancement 3.12 bugs and security fixes labels Sep 9, 2022
@kumaraditya303 kumaraditya303 self-assigned this Sep 9, 2022
@gvanrossum
Copy link
Member

Hold your horses. I’m not convinced yet that we should do this.

@kumaraditya303
Copy link
Contributor Author

@gvanrossum What alternative do we have? Or do you mean this should be done at all as if it is not worth it ?

@gvanrossum
Copy link
Member

We can just choose to live with the status quo, can't we?

@kumaraditya303
Copy link
Contributor Author

We can just choose to live with the status quo, can't we?

That's what I asked, this has proven to be more controversial than I had hoped, the SC advised to deprecate this first hence I created this issue, I'll just close it now as it seems there isn't enough support for this now :(

@kumaraditya303 kumaraditya303 closed this as not planned Won't fix, can't repro, duplicate, stale Sep 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.12 bugs and security fixes type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

2 participants