GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add os.path.isreserved() function · Issue #88569 · python/cpython

Add os.path.isreserved() function #88569

New issue
Copy link
New issue
Copy link
Closed
Closed
Add os.path.isreserved() function#88569
Copy link
Labels
stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytopic-pathlibtype-featureA feature request or enhancementA feature request or enhancement

Description

barneygale
mannequin
opened on Jun 12, 2021
Issue body actions
BPO 44403
Nosy @barneygale

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 = None
created_at = <Date 2021-06-12.19:52:47.516>
labels = ['type-feature', 'library']
title = 'Add os.path.isreserved() function'
updated_at = <Date 2021-06-12.19:52:47.516>
user = 'https://github.com/barneygale'

bugs.python.org fields:

activity = <Date 2021-06-12.19:52:47.516>
actor = 'barneygale'
assignee = 'none'
closed = False
closed_date = None
closer = None
components = ['Library (Lib)']
creation = <Date 2021-06-12.19:52:47.516>
creator = 'barneygale'
dependencies = []
files = []
hgrepos = []
issue_num = 44403
keywords = []
message_count = 1.0
messages = ['395702']
nosy_count = 1.0
nosy_names = ['barneygale']
pr_nums = []
priority = 'normal'
resolution = None
stage = None
status = 'open'
superseder = None
type = 'enhancement'
url = 'https://bugs.python.org/issue44403'
versions = []

Linked PRs

  • gh-88569: add ntpath.isreserved() #95486

Activity

  1. barneygale commented on Jun 12, 2021

    @barneygale
    barneygalemannequin
    on Jun 12, 2021
    MannequinAuthor
    More actions

    Windows reserves certain filenames like 'NUL'. Checking for these names is part of a small handful of functionality that is available in pathlib but not in os.path.

    I propose that we add an os.path.isreserved() function, encorporating Eryk Sun's work on bpo-27827. We then adjust pathlib to call the new function.

    By doing so, we move one of the few remaining OS-specific implementations in pathlib to low-level libraries (posixpath, ntpath) where it arguably belongs.

    We also make this functionality available to the segment of people using traditional string-based path operations who don't want to dip their toes into pathlib just for reserved names.

  2. barneygale
    added
    stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directory
    type-featureA feature request or enhancementA feature request or enhancement
    on Jun 12, 2021
  3. ezio-melotti
    transferred this issue fromon Apr 10, 2022
  4. barneygale
    added a commit that references this issue on Jul 31, 2022

    pythongh-88569: add `os.path.isreserved()`

    6b89ecc
  5. barneygale
    added
    topic-pathlib
    on Jan 8, 2024
  6. barneygale
    added a commit that references this issue on Jan 26, 2024

    gh-88569: add `ntpath.isreserved()` (#95486)

    7e31d6d
  7. barneygale commented on Jan 26, 2024

    @barneygale
    barneygale
    on Jan 26, 2024
    ContributorAuthor
    More actions

    Resolved in 3.13 / 7e31d6d / #95486

  8. barneygale
    closed this as completedon Jan 26, 2024
  9. aisk
    added a commit that references this issue on Feb 11, 2024

    pythongh-88569: add `ntpath.isreserved()` (python#95486)

    ebe7553
  10. Glyphack
    added a commit that references this issue on Sep 2, 2024

    pythongh-88569: add `ntpath.isreserved()` (python#95486)

    802d9a3
  11. The-Compiler
    added a commit that references this issue on Dec 9, 2024

    py313: Avoid deprecated pathlib.PurePath.is_reserved()

    68eacd2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytopic-pathlibtype-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

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.