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

Refactor usage of sys._getframe at typing module #88910

Closed
uriyyo opened this issue Jul 27, 2021 · 3 comments
Closed

Refactor usage of sys._getframe at typing module #88910

uriyyo opened this issue Jul 27, 2021 · 3 comments
Labels
3.11 only security fixes stdlib Python modules in the Lib dir type-feature A feature request or enhancement

Comments

@uriyyo
Copy link
Member

uriyyo commented Jul 27, 2021

BPO 44747
Nosy @ambv, @uriyyo
PRs
  • bpo-44747: Refactor usage of sys._getframe at typing module #27387
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2021-07-30.13:50:29.888>
    created_at = <Date 2021-07-27.09:04:49.953>
    labels = ['type-feature', 'library', '3.11']
    title = 'Refactor usage of sys._getframe at typing module'
    updated_at = <Date 2021-07-30.13:50:29.887>
    user = 'https://github.com/uriyyo'

    bugs.python.org fields:

    activity = <Date 2021-07-30.13:50:29.887>
    actor = 'lukasz.langa'
    assignee = 'none'
    closed = True
    closed_date = <Date 2021-07-30.13:50:29.888>
    closer = 'lukasz.langa'
    components = ['Library (Lib)']
    creation = <Date 2021-07-27.09:04:49.953>
    creator = 'uriyyo'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 44747
    keywords = ['patch']
    message_count = 3.0
    messages = ['398286', '398550', '398551']
    nosy_count = 2.0
    nosy_names = ['lukasz.langa', 'uriyyo']
    pr_nums = ['27387']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue44747'
    versions = ['Python 3.11']

    @uriyyo
    Copy link
    Member Author

    uriyyo commented Jul 27, 2021

    While I was working with typing I have notice that there are duplication of _getframe usage. While In scope of bpo-44353 I introduced typing._callee function which allow to return module name of a caller function.

    In scope of this issue we will reduce the usage of _getframe usage. It will be used only in one place, at _callee function.

    @uriyyo uriyyo added 3.11 only security fixes stdlib Python modules in the Lib dir type-feature A feature request or enhancement labels Jul 27, 2021
    @Fidget-Spinner Fidget-Spinner changed the title Reduce usage of sys._getframe at typing module Refactor usage of sys._getframe at typing module Jul 28, 2021
    @Fidget-Spinner Fidget-Spinner changed the title Reduce usage of sys._getframe at typing module Refactor usage of sys._getframe at typing module Jul 28, 2021
    @ambv
    Copy link
    Contributor

    ambv commented Jul 30, 2021

    New changeset ea4673e by Yurii Karabas in branch 'main':
    bpo-44747: Refactor usage of sys._getframe at typing module (bpo-27387)
    ea4673e

    @ambv
    Copy link
    Contributor

    ambv commented Jul 30, 2021

    Thanks, Yurii! ✨ 🍰 ✨

    @ambv ambv closed this as completed Jul 30, 2021
    @ambv ambv closed this as completed Jul 30, 2021
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.11 only security fixes stdlib Python modules in the Lib dir type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants