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

unicodeobject.c doesn't compile when defined EXPERIMENTAL_ISOLATED_SUBINTERPRETERS, variable "interned" not found #90988

Closed
moytrage mannequin opened this issue Feb 23, 2022 · 3 comments
Labels
3.10 only security fixes 3.11 only security fixes build The build process and cross-build topic-subinterpreters

Comments

@moytrage
Copy link
Mannequin

moytrage mannequin commented Feb 23, 2022

BPO 46832
Nosy @vstinner, @ericsnowcurrently, @kumaraditya303
Files
  • unicodeobject.c
  • 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 = None
    created_at = <Date 2022-02-23.06:12:09.073>
    labels = ['expert-subinterpreters', 'build', '3.10']
    title = 'unicodeobject.c doesn\'t compile when defined EXPERIMENTAL_ISOLATED_SUBINTERPRETERS, variable "interned" not found'
    updated_at = <Date 2022-03-03.11:29:31.887>
    user = 'https://bugs.python.org/moytrage'

    bugs.python.org fields:

    activity = <Date 2022-03-03.11:29:31.887>
    actor = 'kumaraditya'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Subinterpreters']
    creation = <Date 2022-02-23.06:12:09.073>
    creator = 'moytrage'
    dependencies = []
    files = ['50637']
    hgrepos = []
    issue_num = 46832
    keywords = []
    message_count = 3.0
    messages = ['413774', '414429', '414431']
    nosy_count = 4.0
    nosy_names = ['vstinner', 'eric.snow', 'kumaraditya', 'moytrage']
    pr_nums = []
    priority = 'normal'
    resolution = None
    stage = None
    status = 'open'
    superseder = None
    type = 'compile error'
    url = 'https://bugs.python.org/issue46832'
    versions = ['Python 3.10']

    @moytrage
    Copy link
    Mannequin Author

    moytrage mannequin commented Feb 23, 2022

    1. Downloaded https://www.python.org/ftp/python/3.10.2/Python-3.10.2.tar.xz

    2. Compiled under MSVC 2019 with define EXPERIMENTAL_ISOLATED_SUBINTERPRETERS

    3. Got compilation error of file Objects/unicodeobject.c at line 15931, about undefined variable "interned", it is function _PyUnicode_ClearInterned(), uncompilable code is "if (interned == NULL) {".

    This happens because when EXPERIMENTAL_ISOLATED_SUBINTERPRETERS is defined then INTERNED_STRINGS is undefined hence global variable "static PyObject *interned = NULL;" is not created, and _PyUnicode_ClearInterned() uses this global variable "interned".

    For reference attaching my version of "unicodeobject.c" which has compilation error at line 15931.

    @moytrage moytrage mannequin added 3.10 only security fixes topic-subinterpreters build The build process and cross-build labels Feb 23, 2022
    @vstinner
    Copy link
    Member

    vstinner commented Mar 3, 2022

    This build flag is experimental and unsupported. If you care, you should target Python 3.11 which is currently under development.

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    @ezio-melotti ezio-melotti moved this to Todo in Subinterpreters Apr 15, 2022
    @kumaraditya303 kumaraditya303 added 3.11 only security fixes 3.10 only security fixes and removed 3.10 only security fixes labels Apr 15, 2022
    @kumaraditya303
    Copy link
    Contributor

    Closing as EXPERIMENTAL_ISOLATED_SUBINTERPRETERS was removed in #93185

    @kumaraditya303 kumaraditya303 closed this as not planned Won't fix, can't repro, duplicate, stale Jul 10, 2022
    Repository owner moved this from Todo to Done in Subinterpreters Jul 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.10 only security fixes 3.11 only security fixes build The build process and cross-build topic-subinterpreters
    Projects
    Status: Done
    Development

    No branches or pull requests

    2 participants