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

Freeze the runpy module. #89817

Closed
ericsnowcurrently opened this issue Oct 28, 2021 · 6 comments
Closed

Freeze the runpy module. #89817

ericsnowcurrently opened this issue Oct 28, 2021 · 6 comments
Labels
3.11 only security fixes build The build process and cross-build type-bug An unexpected behavior, bug, or error

Comments

@ericsnowcurrently
Copy link
Member

BPO 45654
Nosy @gvanrossum, @tiran, @ericsnowcurrently, @FFY00, @kumaraditya303
PRs
  • bpo-45654: freeze runpy module #29903
  • bpo-45654: No need to freeze types (GH-30028) #30028
  • 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-12-09.16:55:11.802>
    created_at = <Date 2021-10-28.18:13:50.416>
    labels = ['type-bug', 'build', '3.11']
    title = 'Freeze the runpy module.'
    updated_at = <Date 2021-12-10.18:09:15.717>
    user = 'https://github.com/ericsnowcurrently'

    bugs.python.org fields:

    activity = <Date 2021-12-10.18:09:15.717>
    actor = 'christian.heimes'
    assignee = 'none'
    closed = True
    closed_date = <Date 2021-12-09.16:55:11.802>
    closer = 'gvanrossum'
    components = ['Build']
    creation = <Date 2021-10-28.18:13:50.416>
    creator = 'eric.snow'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 45654
    keywords = ['patch']
    message_count = 6.0
    messages = ['405212', '405235', '408140', '408142', '408210', '408235']
    nosy_count = 5.0
    nosy_names = ['gvanrossum', 'christian.heimes', 'eric.snow', 'FFY00', 'kumaraditya']
    pr_nums = ['29903', '30028']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue45654'
    versions = ['Python 3.11']

    @ericsnowcurrently
    Copy link
    Member Author

    Currently we are freezing the modules that are imported during startup. However, if someone uses "python -m module" then the runtime imports the runpy module and uses it. Given that this case is quite common, runpy and its dependencies should be frozen.

    @ericsnowcurrently ericsnowcurrently added 3.11 only security fixes build The build process and cross-build type-bug An unexpected behavior, bug, or error labels Oct 28, 2021
    @ericsnowcurrently
    Copy link
    Member Author

    @gvanrossum
    Copy link
    Member

    New changeset 44b0e76 by Kumar Aditya in branch 'main':
    bpo-45654: Freeze the runpy module and stuff it imports (GH-29903)
    44b0e76

    @gvanrossum
    Copy link
    Member

    Thanks Kumar!

    @tiran
    Copy link
    Member

    tiran commented Dec 10, 2021

    I noticed that the types module is only used for ModuleType. PR #74214 gets rid of 205 kB object code:

    205K Python/deepfreeze/types.o

    @tiran
    Copy link
    Member

    tiran commented Dec 10, 2021

    New changeset 16638a4 by Christian Heimes in branch 'main':
    bpo-45654: No need to freeze types (GH-30028)
    16638a4

    @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 build The build process and cross-build type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants