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

Fix test_modulefinder #85212

Closed
serhiy-storchaka opened this issue Jun 19, 2020 · 4 comments
Closed

Fix test_modulefinder #85212

serhiy-storchaka opened this issue Jun 19, 2020 · 4 comments
Labels
3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes 3.10 only security fixes tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error

Comments

@serhiy-storchaka
Copy link
Member

BPO 41040
Nosy @serhiy-storchaka, @miss-islington
PRs
  • bpo-41040: Fix test_modulefinder. #20991
  • [3.9] bpo-41040: Fix test_modulefinder. (GH-20991) #20992
  • [3.8] bpo-41040: Fix test_modulefinder. (GH-20991) #20993
  • 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-06-22.07:42:11.920>
    created_at = <Date 2020-06-19.20:06:42.839>
    labels = ['type-bug', '3.8', '3.9', '3.10', '3.7', 'tests']
    title = 'Fix test_modulefinder'
    updated_at = <Date 2020-06-22.07:42:11.919>
    user = 'https://github.com/serhiy-storchaka'

    bugs.python.org fields:

    activity = <Date 2020-06-22.07:42:11.919>
    actor = 'serhiy.storchaka'
    assignee = 'none'
    closed = True
    closed_date = <Date 2020-06-22.07:42:11.920>
    closer = 'serhiy.storchaka'
    components = ['Tests']
    creation = <Date 2020-06-19.20:06:42.839>
    creator = 'serhiy.storchaka'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 41040
    keywords = ['patch']
    message_count = 4.0
    messages = ['371897', '371901', '371904', '371905']
    nosy_count = 2.0
    nosy_names = ['serhiy.storchaka', 'miss-islington']
    pr_nums = ['20991', '20992', '20993']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue41040'
    versions = ['Python 3.7', 'Python 3.8', 'Python 3.9', 'Python 3.10']

    @serhiy-storchaka
    Copy link
    Member Author

    There is a bug in test_modulefinder. The bytes string literal contains \u2090.

    1. Since \u is not recognized escape sequence in bytes literals, compiling the file emits a deprecation warning:

    /home/serhiy/py/cpython/Lib/test/test_modulefinder.py:281: DeprecationWarning: invalid escape sequence \u
    b"""\

    1. b"\u2090" is interpreted as b"\\u2090", but actually the test implies that it should be a bytes sequence b'\xe2\x82\x90' which is valid in UTF-8 but is not a valid in CP1252.

    @serhiy-storchaka serhiy-storchaka added 3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes 3.10 only security fixes tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error labels Jun 19, 2020
    @serhiy-storchaka
    Copy link
    Member Author

    New changeset a041e11 by Serhiy Storchaka in branch 'master':
    bpo-41040: Fix test_modulefinder. (GH-20991)
    a041e11

    @miss-islington
    Copy link
    Contributor

    New changeset 80651ab by Miss Islington (bot) in branch '3.8':
    bpo-41040: Fix test_modulefinder. (GH-20991)
    80651ab

    @miss-islington
    Copy link
    Contributor

    New changeset 7523886 by Miss Islington (bot) in branch '3.9':
    bpo-41040: Fix test_modulefinder. (GH-20991)
    7523886

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes 3.10 only security fixes tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants