Skip to content

Deprecation warning due to invalid escape sequences in Doc/tools/extensions/peg_highlight.py #85845

Closed

Description

@tirkarthi
BPO 41679
Nosy @vstinner, @pablogsal, @miss-islington, @tirkarthi
PRs
  • bpo-41679: Fix invalid escape sequences in the peg_highlight Sphinx extension #22047
  • [3.9] bpo-41679: Fix invalid escape sequences in the peg_highlight Sphinx extension (GH-22047) #22065
  • 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 2020-09-02.16:53:39.137>
    created_at = <Date 2020-08-31.16:11:52.976>
    labels = ['type-bug', '3.10', 'build']
    title = 'Deprecation warning due to invalid escape sequences in Doc/tools/extensions/peg_highlight.py'
    updated_at = <Date 2020-09-02.16:53:39.136>
    user = 'https://github.com/tirkarthi'

    bugs.python.org fields:

    activity = <Date 2020-09-02.16:53:39.136>
    actor = 'pablogsal'
    assignee = 'none'
    closed = True
    closed_date = <Date 2020-09-02.16:53:39.137>
    closer = 'pablogsal'
    components = ['Build']
    creation = <Date 2020-08-31.16:11:52.976>
    creator = 'xtreak'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 41679
    keywords = ['patch']
    message_count = 2.0
    messages = ['376158', '376198']
    nosy_count = 4.0
    nosy_names = ['vstinner', 'pablogsal', 'miss-islington', 'xtreak']
    pr_nums = ['22047', '22065']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue41679'
    versions = ['Python 3.10']

    Activity

    1. tirkarthi commented on Aug 31, 2020

      @tirkarthi
      MemberAuthor

      Following warnings are caused in Doc/tools/extensions/peg_highlight.py . These warnings show up during doc builds since the extension is used in the build. This is an easy issue to fix.

      ./python -Wall -m py_compile /root/cpython/Doc/tools/extensions/peg_highlight.py
      /root/cpython/Doc/tools/extensions/peg_highlight.py:62: DeprecationWarning: invalid escape sequence \s
      r"^\s*" + _name + "\s*" + "(\[.*\])?" + "\s*" + "(\(.+\))?" + "\s*(:)",
      /root/cpython/Doc/tools/extensions/peg_highlight.py:62: DeprecationWarning: invalid escape sequence \[
      r"^\s*" + _name + "\s*" + "(\[.*\])?" + "\s*" + "(\(.+\))?" + "\s*(:)",
      /root/cpython/Doc/tools/extensions/peg_highlight.py:62: DeprecationWarning: invalid escape sequence \s
      r"^\s*" + _name + "\s*" + "(\[.*\])?" + "\s*" + "(\(.+\))?" + "\s*(:)",
      /root/cpython/Doc/tools/extensions/peg_highlight.py:62: DeprecationWarning: invalid escape sequence \(
      r"^\s*" + _name + "\s*" + "(\[.*\])?" + "\s*" + "(\(.+\))?" + "\s*(:)",
      /root/cpython/Doc/tools/extensions/peg_highlight.py:62: DeprecationWarning: invalid escape sequence \s
      r"^\s*" + _name + "\s*" + "(\[.*\])?" + "\s*" + "(\(.+\))?" + "\s*(:)",

    2. added
      buildThe build process and cross-build
      type-bugAn unexpected behavior, bug, or error
      on Aug 31, 2020
    3. vstinner commented on Sep 1, 2020

      @vstinner
      Member

      Do you want to propose a PR to fix these warnings?

    4. transferred this issue fromon Apr 10, 2022
    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

      3.10 (EOL)end of lifebuildThe build process and cross-buildtype-bugAn unexpected behavior, bug, or error

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions