Skip to main content

fs.proxy

Source PyPI Travis Codecov Codacy Format License

Requirements

pyfilesystem2

PyPI fs

Source fs

License fs

six

PyPI six

Source six

License six

psutil

PyPI psutil

Source psutil

License psutil

Installation

Install directly from PyPI, using pip

pip install fs.proxy

Usage

This module revolves around the notion of proxy filesystems, akin to wrapper filesystems from the core library, but using a proxy in combination with the delegate filesystem used by WrapFS. They also make it easier to create generic wrappers, as fs.proxy.base.Proxy subclasses will use the fs.base.FS method implementation, while actually deriving from WrapFS !

This extension includes a base fs.proxy.base.Proxy class, that requires only the essential filesystem methods to be implemented.

The fs.proxy.writer package also declares two classes that can be used to make any read-only filesystem writeable, using a secondary writeable filesystem: fs.proxy.writer.ProxyWriter and fs.proxy.writer.SwapWriter. ProxyWriter will always write modifications to the secondary filesystem (often a MemoryFS or a TempFS), while SwapWriter will use a third backup filesystem in case the memory footprint of the proxy filesystem becomes too large (swapping from a MemoryFS to an OSFS, etc.). For instance, let’s pretend we can write to the root:

>>> import fs.proxy.writer

>>> read_only_fs = fs.open_fs(u'/') # this is not actually read-only ;)
>>> writeable_fs = fs.proxy.writer.ProxyWriter(read_only_fs)
>>> writeable_fs.setbytes(u'/root.txt', b'I am writing in root !')

>>> writeable_fs.exists(u'/root.txt')
True
>>> read_only_fs.exists(u'/root.txt')
False

See also

  • fs, the core pyfilesystem2 library

  • fs.archive, enhanced archive filesystems for pyfilesystem2

  • fs.sshfs, a SFTP/SSH implementation for pyfilesystem2 using paramiko

  • fs.smbfs, Pyfilesystem2 over SMB using pysmb

Metadata

Release files for fs.proxy 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fs.proxy 0.1.4
File Size Uploaded Provenance Actions
fs.proxy-0.1.4.tar.gz 7.9 kB Without provenance Details for fs.proxy-0.1.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for fs.proxy 0.1.4
File Interpreter ABI Platform Actions
fs.proxy-0.1.4-py2.py3-none-any.whl Python 2, Python 3 none any Details for fs.proxy-0.1.4-py2.py3-none-any.whl

Total release size: 18.3 kB

Release files / fs.proxy-0.1.4.tar.gz

Download URL fs.proxy-0.1.4.tar.gz
Size 7.9 kB
Tags Source
SHA-256 checksum
How to use checksums
0a7a13ad8684a5fb29f9ead14a6218253b423c7f1c89de2ca8d226c851e52f3f
BLAKE2b-256 checksum
How to use checksums
45b424903dab54640aa681ed5e8c3017a8d9512b75ceec757191505f20c3857b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / fs.proxy-0.1.4-py2.py3-none-any.whl

Download URL fs.proxy-0.1.4-py2.py3-none-any.whl
Size 10.4 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
de2e0ec8496c6f6ccf57f714e2122f63f0c6f0eb0f7823b8e2910ae45c691a1d
BLAKE2b-256 checksum
How to use checksums
981cfc16b62bb2278aa8117dd7385e729c723fde24400bff1e81cc2f4c93657c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for fs.proxy 0.1.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page