Skip to content

Expressions with format specifiers in f-strings give wrong code position in AST #79393

Closed
@numirias

Description

@numirias
mannequin
BPO 35212
Nosy @blueyed, @ericvsmith, @asmeurer, @numirias, @yangyangxcf, @DanielNoord
PRs
  • bpo-35212: fix col_offset in f-strings #19398
  • bpo-44885: Correct the ast locations of f-strings with format specs and repeated expressions #27729
  • Superseder
  • bpo-44885: Incorrect exception highlighting for fstring format
  • 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 = 'https://github.com/ericvsmith'
    closed_at = <Date 2022-03-16.12:23:28.718>
    created_at = <Date 2018-11-11.12:34:00.842>
    labels = ['interpreter-core', 'type-bug', '3.7']
    title = 'Expressions with format specifiers in f-strings give wrong code position in AST'
    updated_at = <Date 2022-03-16.12:23:28.718>
    user = 'https://github.com/numirias'

    bugs.python.org fields:

    activity = <Date 2022-03-16.12:23:28.718>
    actor = 'eric.smith'
    assignee = 'eric.smith'
    closed = True
    closed_date = <Date 2022-03-16.12:23:28.718>
    closer = 'eric.smith'
    components = ['Interpreter Core']
    creation = <Date 2018-11-11.12:34:00.842>
    creator = 'arminius'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 35212
    keywords = ['patch']
    message_count = 4.0
    messages = ['329672', '353908', '376163', '415337']
    nosy_count = 6.0
    nosy_names = ['blueyed', 'eric.smith', 'asmeurer', 'arminius', 'fhsxfhsx', 'danielnoord']
    pr_nums = ['19398', '27729']
    priority = 'normal'
    resolution = 'duplicate'
    stage = 'resolved'
    status = 'closed'
    superseder = '44885'
    type = 'behavior'
    url = 'https://bugs.python.org/issue35212'
    versions = ['Python 3.7']

    Metadata

    Metadata

    Assignees

    Labels

    3.7 (EOL)end of lifeinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions