Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Allow path-like objects in fnmatch.filter on POSIX platforms #123135

Copy link
Copy link
Closed as not planned
@picnixz

Description

@picnixz
Issue body actions

In fnmatch.filter, it says that

# normcase on posix is NOP. Optimize it away from the loop.

This is not the case. os.path.normcase actually calls os.fspath on POSIX, meaning that path-like objects are allowed. Thus, we cannot optimize it away from the loop. I'll update #123122 accordingly.

Related: #123122 (comment)

CPython versions tested on:

CPython main branch

Operating systems tested on:

No response

Linked PRs

Metadata

Metadata

Assignees

Labels

stdlibPython modules in the Lib dirPython modules in the Lib dirtype-featureA feature request or enhancementA feature request or enhancement

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.