Skip to content

Conversation

barneygale
Copy link
Contributor

Methods like full_match(), glob(), etc, are difficult to make work with byte paths, and it's not worth the effort. This patch makes PurePathBase raise TypeError when given non-str path segments, like PurePath.

Methods like `full_match()`, `glob()`, etc, are difficult to make work with
byte paths, and it's not worth the effort. This patch makes `PurePathBase`
raise `ValueError` when given non-`str` path segments.
@barneygale barneygale enabled auto-merge (squash) January 31, 2024 00:38
@barneygale barneygale merged commit 5742919 into python:main Jan 31, 2024
aisk pushed a commit to aisk/cpython that referenced this pull request Feb 11, 2024
…s. (python#114777)

Methods like `full_match()`, `glob()`, etc, are difficult to make work with
byte paths, and it's not worth the effort. This patch makes `PurePathBase`
raise `TypeError` when given non-`str` path segments.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant