Sitelet https://github.com/python/cpython/issues/100210
Skip to content

Link in code comment no longer relevant for HTML unescaping #100210

Description

@jcamiel

Documentation

The link in

# see http://www.w3.org/TR/html5/syntax.html#tokenizing-character-references
is not longer relevant and should be replace:

The link should explain the source of the replacements table:

# see http://www.w3.org/TR/html5/syntax.html#tokenizing-character-references

_invalid_charrefs = {
    0x00: '\ufffd',  # REPLACEMENT CHARACTER
    0x0d: '\r',      # CARRIAGE RETURN
    0x80: '\u20ac',  # EURO SIGN
    0x81: '\x81',    # <control>
    0x82: '\u201a',  # SINGLE LOW-9 QUOTATION MARK
    0x83: '\u0192',  # LATIN SMALL LETTER F WITH HOOK
    0x84: '\u201e',  # DOUBLE LOW-9 QUOTATION MARK
    0x85: '\u2026',  # HORIZONTAL ELLIPSIS
    0x86: '\u2020',  # DAGGER
    0x87: '\u2021',  # DOUBLE DAGGER
    0x88: '\u02c6',  # MODIFIER LETTER CIRCUMFLEX ACCENT
    0x89: '\u2030',  # PER MILLE SIGN
    0x8a: '\u0160',  # LATIN CAPITAL LETTER S WITH CARON

Linked PRs

Activity

  1. changed the title [-]Link in code no longer relevant[/-] [+]Link in code comment no longer relevant for HTML unescaping[/+] on Dec 13, 2022
  2. self-assigned this
    on Dec 16, 2022
  3. added a commit that references this issue on Feb 19, 2023
  4. added 3 commits that reference this issue on Feb 19, 2023
  5. added a commit that references this issue on Feb 20, 2023
  6. added a commit that references this issue on Feb 20, 2023
  7. ezio-melotti commented on Feb 20, 2023

    @ezio-melotti
    Member

    Fixed, thanks for the report and then PR!

  8. added a commit that references this issue on Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

docsDocumentation in the Doc dir

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions