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

pathlib path.match misshandles multiple ** #78912

Closed
RonnyPfannschmidt mannequin opened this issue Sep 19, 2018 · 3 comments
Closed

pathlib path.match misshandles multiple ** #78912

RonnyPfannschmidt mannequin opened this issue Sep 19, 2018 · 3 comments
Labels
stdlib Python modules in the Lib dir

Comments

@RonnyPfannschmidt
Copy link
Mannequin

RonnyPfannschmidt mannequin commented Sep 19, 2018

BPO 34731
Nosy @RonnyPfannschmidt, @berkerpeksag
Superseder
  • bpo-29249: Pathlib glob ** bug
  • 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 2018-09-19.08:13:51.650>
    created_at = <Date 2018-09-19.05:34:46.266>
    labels = ['library']
    title = 'pathlib path.match misshandles multiple `**`'
    updated_at = <Date 2018-09-19.09:01:05.042>
    user = 'https://github.com/RonnyPfannschmidt'

    bugs.python.org fields:

    activity = <Date 2018-09-19.09:01:05.042>
    actor = 'berker.peksag'
    assignee = 'none'
    closed = True
    closed_date = <Date 2018-09-19.08:13:51.650>
    closer = 'Ronny.Pfannschmidt'
    components = ['Library (Lib)']
    creation = <Date 2018-09-19.05:34:46.266>
    creator = 'Ronny.Pfannschmidt'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 34731
    keywords = []
    message_count = 3.0
    messages = ['325701', '325703', '325734']
    nosy_count = 2.0
    nosy_names = ['Ronny.Pfannschmidt', 'berker.peksag']
    pr_nums = []
    priority = 'normal'
    resolution = 'duplicate'
    stage = 'resolved'
    status = 'closed'
    superseder = '29249'
    type = None
    url = 'https://bugs.python.org/issue34731'
    versions = []

    @RonnyPfannschmidt
    Copy link
    Mannequin Author

    RonnyPfannschmidt mannequin commented Sep 19, 2018

    when porting parts of pytest to pathlib we noted that path.match does not quite match normal fnmatch for usages of **

    i believe this is related to always splitting the patter completely and not handling ** in that case

    Bruno wrote https://github.com/pytest-dev/pytest/pull/3980/files#diff-63fc5ed688925b327a5af20405bf4b09R19 as a workaround

    @RonnyPfannschmidt RonnyPfannschmidt mannequin added the stdlib Python modules in the Lib dir label Sep 19, 2018
    @berkerpeksag
    Copy link
    Member

    Thanks for the report. This looks like a duplicate of bpo-29249.

    @RonnyPfannschmidt
    Copy link
    Mannequin Author

    RonnyPfannschmidt mannequin commented Sep 19, 2018

    indeed it is, thanks for the reference i searched only for match and missed the glob

    @RonnyPfannschmidt RonnyPfannschmidt mannequin closed this as completed Sep 19, 2018
    @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
    stdlib Python modules in the Lib dir
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant