Skip to main content

Generic Path Protocol based pathlib

Project description

pathlib_next

Version Python versions License: MIT Docs CI

Generic Path Protocol based pathlib implementation for URI paths with file access support for sftp, http, file schemes.

Features

  • Unified URI Interface — Access resources on sftp, http, or local file schemes using python's familiar pathlib syntax.
  • In-memory filesystemMemPath provides a lightweight, virtual file system helper for mock files, testing, or transient storage.
  • Path synchronizationPathSyncer allows syncing directory structures across different paths with customizable checksums.
  • Query & Source Parsing — Parse and serialize complex URL query strings and URI sources easily.

Installation

pip install pathlib_next

Optional features/extras:

Extra/flag Adds Needed for
uri uritools URI parsing capabilities
http requests, bs4, htmllistparse Read and list files over HTTP/HTTPS
sftp paramiko SFTP path operations and transfers

Quick start

Unified Path Operations

from pathlib_next import Path
from pathlib_next.uri import UriPath

# Use the unified path interface
local_path = Path("./my_folder")
http_path = UriPath("http://example.com/data.txt")

# Read and print text if it exists
if http_path.exists():
    print(http_path.read_text())

API overview

Module/Package Purpose
pathlib_next.path Base Path implementation and protocols
pathlib_next.uri URI/URL specific path support and Query utils
pathlib_next.mempath In-memory transient path structure
pathlib_next.utils.sync Synchronization functions and PathSyncer class

Supported Python versions

Python >= 3.9

Development

See AGENTS.md (and the language-specific directive it points to, e.g. PYTHON.md) for environment setup, dependency install, and test commands.

Releasing

This project follows Semantic Versioning and keeps a CHANGELOG.md. Pushing a tag matching v* triggers the release workflow: test gate → build → publish → docs deploy (see AGENTS.md's "Repository Structure" section and the language-specific CI/CD notes for the concrete jobs).

Documentation site

MkDocs builds the API reference from docs/, published on every release. To preview locally: mkdocs serve.

License

MIT — see LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pathlib_next-0.4.0.tar.gz (22.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pathlib_next-0.4.0-py3-none-any.whl (27.3 kB view details)

Uploaded Python 3

File details

Details for the file pathlib_next-0.4.0.tar.gz.

File metadata

  • Download URL: pathlib_next-0.4.0.tar.gz
  • Upload date:
  • Size: 22.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pathlib_next-0.4.0.tar.gz
Algorithm Hash digest
SHA256 cbee305e299012986abb19c923d564450ed9aa28822ea4c048291d0519934ba0
MD5 05812ef8f3347b7b5d03e24aa39360d1
BLAKE2b-256 429845eefbcf2bd3ee0d9101b178606cceadcbbc3e40144f6b270b1d6ef869f1

See more details on using hashes here.

Provenance

The following attestation bundles were made for pathlib_next-0.4.0.tar.gz:

Publisher: release.yml on jose-pr/pathlib_next

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pathlib_next-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: pathlib_next-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 27.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pathlib_next-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ad7c1e65ad769a8bceb1e9f9a1aecf3d2e9b5b4b2cb9b07a55005c6cd5551799
MD5 3c2ad967ca8795c463989613946a6614
BLAKE2b-256 98c272fbf389a17d5b7fc704d83396f19282716a8bf8ac3f4d47ffa37752f8a7

See more details on using hashes here.

Provenance

The following attestation bundles were made for pathlib_next-0.4.0-py3-none-any.whl:

Publisher: release.yml on jose-pr/pathlib_next

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page