GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — PEP 701 – Syntactic formalization of f-strings · Issue #102856 · python/cpython

PEP 701 – Syntactic formalization of f-strings #102856

New issue
Copy link
New issue
Copy link
Closed
Closed
PEP 701 – Syntactic formalization of f-strings#102856
Copy link

Description

@pablogsal
pablogsal
opened on Mar 20, 2023
Issue body actions
  • Changes in the C tokenizer
  • Categorize failing tests
  • Fix failing tests or modify/remove them as needed
  • Changes in Python tokenizer

Linked PRs

  • gh-102856: Initial implementation of PEP 701 #102855
  • gh-102856: Skip test_mismatched_parens in WASI builds #103633
  • gh-102856: Clean some of the PEP 701 tokenizer implementation #103634
  • gh-102856: Allow comments inside multi-line f-string expresions #104006
  • gh-102856: Python tokenizer implementation for PEP 701 #104323
  • gh-102856: Tokenize performance improvement #104731
  • gh-102856: Add changes related to PEP 701 in 3.12 What's New docs #104824
  • [3.12] gh-102856: Add changes related to PEP 701 in 3.12 What's New docs (GH-104824) #104847
  • gh-102856: Add missing quote to fix doctest #104852
  • [3.12] gh-102856: Add missing quote to fix doctest (GH-104852) #104854
  • gh-102856: Update "Formatted string literals" docs section after PEP701 #104861
  • [3.12] gh-102856: Update "Formatted string literals" docs section after PEP701 (GH-104861) #104865
Reacted by Jesse P. Johnson
Reacted by Alex Waygood, Batuhan Taskaya, Lysandros Nikolaou, Kirill Podoprigora, Oleg Iarygin, Vasily Ryabov, Charlie Zhao, Mohamed El Mouctar HAIDARA, Philippe Voinov and Mikhail Efimov

Activity

Next
  1. pablogsal commented on Mar 20, 2023

    @pablogsal
    pablogsal
    on Mar 20, 2023
    MemberAuthor
    More actions

    CC: @lysnikolaou @isidentical @mgmacias95

  2. pablogsal commented on Mar 20, 2023

    @pablogsal
    pablogsal
    on Mar 20, 2023
    MemberAuthor
    More actions

    See this for the latest report on errors from @isidentical

  3. pablogsal commented on Mar 20, 2023

    @pablogsal
    pablogsal
    on Mar 20, 2023
    MemberAuthor
    More actions

    Draft PR for the C tokenizer up: #102855

  4. pablogsal commented on Mar 20, 2023

    @pablogsal
    pablogsal
    on Mar 20, 2023
    MemberAuthor
    More actions

    Things for the cleanup of #102855:

    • Cleaning up the grammar and the action helpers (the names are still ridiculous and there are multiple rules commented out).
    • Remove the old parsing code and check that we didn't break anything 😅
    • Clean/refactor the tokenizer struct (better names, factor stuff into its own structure as needed).
    • Consider factoring out tok_get_fstring_mode because is a monster.
  5. pablogsal commented on Mar 20, 2023

    @pablogsal
    pablogsal
    on Mar 20, 2023
    MemberAuthor
    More actions

    Ok with #102855 we have the following failing tests:

    • test_ast
    • test_cmd_line_script
    • test_eof
    • test_exceptions
    • test_fstring
    • test_tokenize
    • test_type_comments
    • test_unparse

    Most of these are updating error messages, line numbers and other stuff but some may have actual bugs so we should check them. Please, mention which ones are you working on so we don't clash with one another.

  6. mgmacias95 commented on Mar 20, 2023

    @mgmacias95
    mgmacias95
    on Mar 20, 2023
    Contributor
    More actions

    Working on test_tokenize

    Reacted by Pablo Galindo Salgado
  7. Eclips4 commented on Mar 21, 2023

    @Eclips4
    Eclips4
    on Mar 21, 2023
    Member
    More actions

    Hello, Pablo!
    Can I get work on test_ast?
    Recently I sent some PR's about this file (for example, #102797). So, I have some experience in that =)

  8. ramvikrams commented on Mar 21, 2023

    @ramvikrams
    ramvikrams
    on Mar 21, 2023
    Contributor
    More actions

    I can work with test_type_comments and test_unparse.

  9. pablogsal commented on Mar 21, 2023

    @pablogsal
    pablogsal
    on Mar 21, 2023
    MemberAuthor
    More actions

    @Eclips4 @ramvikrams wonderful! Just make PRs against my fork!

    Report here or ping any of us if you find something that could be a bug (don't just fix the tests blindly because there may be bugs lurking).

    Reacted by Ram Vikram Singh and Kirill Podoprigora
  10. pablogsal commented on Mar 21, 2023

    @pablogsal
    pablogsal
    on Mar 21, 2023
    MemberAuthor
    More actions

    @lysnikolaou can you work on cleaning up the grammar + the actions?

    @isidentical can you work on cleaning up some of the tokenizer layers? (This is quite a lot so we can probably work together here).

  11. Eclips4 commented on Mar 21, 2023

    @Eclips4
    Eclips4
    on Mar 21, 2023
    Member
    More actions

    @pablogsal
    About test_ast.py
    Seems thats like there only a one test will be failed, and how I undestand, that's a bug:

    cpython/Lib/test/test_ast.py

    Lines 779 to 780 in 7f760c2

    with self.assertRaises(SyntaxError):
    ast.parse('f"{x=}"', feature_version=(3, 7))

    I think, there's two solutions:

    1. Remove this test, because support of python3.7 will be ended soon.
    2. Now errors raised by tokenizer.c instead of string_parser.c, so as I understand, we should change python_gram, is it right? ( We need access to feature_version, which in tokenizer inaccessible )
  12. pablogsal commented on Mar 21, 2023

    @pablogsal
    pablogsal
    on Mar 21, 2023
    MemberAuthor
    More actions

    2. Now errors raised by tokenizer.c instead of string_parser.c, so as I understand, we should change python_gram, is it right? ( We need access to feature_version, which in tokenizer inaccessible )

    Probably we can do this but on the other hand I would prefer to not overcomplicate this so I think (1) is better

    Reacted by Kirill Podoprigora and Lysandros Nikolaou
  13. lysnikolaou commented on Mar 21, 2023

    @lysnikolaou
    lysnikolaou
    on Mar 21, 2023
    Member
    More actions

    @lysnikolaou can you work on cleaning up the grammar + the actions?

    Will do!

  14. Eclips4 commented on Mar 21, 2023

    @Eclips4
    Eclips4
    on Mar 21, 2023
    Member
    More actions

    Also, I can take a look at test_cmd_line_script. Seems easy.

  15. pablogsal commented on Mar 21, 2023

    @pablogsal
    pablogsal
    on Mar 21, 2023
    MemberAuthor
    More actions

    Also, I can take a look at test_cmd_line_script. Seems easy.

    All yours!

  16. 52 remaining items

  17. pablogsal
    added a commit that references this issue on May 24, 2023

    [3.12] gh-102856: Add changes related to PEP 701 in 3.12 What's New d…

    a5c0ef8
  18. pablogsal commented on May 24, 2023

    @pablogsal
    pablogsal
    on May 24, 2023
    MemberAuthor
    More actions

    Closing this as we already have a What's New entry, C tokenizer, and Python tokenizer. Let's tackle any small remaining items in separate issues from now on.

    Probably we need to alter https://docs.python.org/3/reference/lexical_analysis.html#formatted-string-literals. @lysnikolaou can you take a go at that?

    Reacted by Lysandros Nikolaou
  19. pablogsal
    closed this as completedon May 24, 2023
  20. miss-islington
    added a commit that references this issue on May 24, 2023

    pythongh-102856: Add missing quote to fix doctest (pythonGH-104852)

    ec62b10
  21. hugovk
    added a commit that references this issue on May 24, 2023

    gh-102856: Add missing quote to fix doctest (#104852)

    3e97c00
  22. lysnikolaou commented on May 24, 2023

    @lysnikolaou
    lysnikolaou
    on May 24, 2023
    Member
    More actions

    Probably we need to alter https://docs.python.org/3/reference/lexical_analysis.html#formatted-string-literals. @lysnikolaou can you take a go at that?

    Sure!

  23. hugovk
    added a commit that references this issue on May 24, 2023

    [3.12] gh-102856: Add missing quote to fix doctest (GH-104852) (#104854)

    2d685ec
  24. lysnikolaou
    added 3 commits that reference this issue on May 24, 2023

    pythongh-102856: Update Formatted string literals docs section after …

    e437849

    pythongh-102856: Update "Formatted string literals" docs section afte…

    298a693

    gh-102856: Update "Formatted string literals" docs section after PEP7…

    8e5b3b9
  25. miss-islington
    added a commit that references this issue on May 24, 2023

    pythongh-102856: Update "Formatted string literals" docs section afte…

    e867088
  26. lysnikolaou
    added a commit that references this issue on May 24, 2023

    [3.12] gh-102856: Update "Formatted string literals" docs section aft…

    25890eb
  27. flying-sheep commented on Oct 2, 2023

    @flying-sheep
    flying-sheep
    on Oct 2, 2023
    Contributor
    More actions

    Ah great! I didn't know someone would continue PEP 536. Happy that it's happening!

    Shouldn't PEP 536 be mentioned in this one?

  28. pablogsal commented on Oct 3, 2023

    @pablogsal
    pablogsal
    on Oct 3, 2023
    MemberAuthor
    More actions

    Ah great! I didn't know someone would continue PEP 536. Happy that it's happening!

    Shouldn't PEP 536 be mentioned in this one?

    It's mentioned in the PEP:

    https://peps.python.org/pep-0701/

    Btw as heads up: We don't monitor normally closed issues so is very likely that people won't answer to comments when the issue is closed :)

    Reacted by Philipp A.
  29. flying-sheep commented on Oct 3, 2023

    @flying-sheep
    flying-sheep
    on Oct 3, 2023
    Contributor
    More actions

    Thanks! Seems like I missed the mention then. Perfect!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.