mo2-vfs.py
Python workarounds for MO2's Universal Virtual Filesystem (UVFS) on Windows 11 24H2.
Replaces broken stdlib functions (Path.is_file, Path.is_dir, os.makedirs,
glob.glob) with direct Win32 API calls via ctypes. No external dependencies.
See ModOrganizer2/modorganizer#2174 for background.
Installation
pip install mo2-vfs.py
Usage
import mo2_vfs
# Apply monkey-patches to os.makedirs and Path.is_file
mo2_vfs.patch_all()
# Direct API
mo2_vfs.is_file(path)
mo2_vfs.is_dir(path)
mo2_vfs.mkdir(path) # creates parent dirs automatically
mo2_vfs.glob(path, "*.swf", recursive=True)
# Restore originals
mo2_vfs.unpatch_all()
What is fixed
| Broken stdlib API | Replacement | Win32 API used |
|---|---|---|
Path.is_file() |
mo2_uvfs.is_file() |
GetFileAttributesW |
Path.is_dir() |
mo2_uvfs.is_dir() |
GetFileAttributesW |
os.makedirs() / Path.mkdir() |
mo2_uvfs.mkdir() |
CreateDirectoryW |
glob.glob() / Path.glob() |
mo2_uvfs.glob() |
FindFirstFileW / FindNextFileW |
License
Metadata
Release files for mo2-vfs.py 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mo2_vfs_py-1.0.0.tar.gz | 7.0 kB | Without provenance | Details for mo2_vfs_py-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mo2_vfs_py-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for mo2_vfs_py-1.0.0-py3-none-any.whl |
Total release size: 16.2 kB
Release files / mo2_vfs_py-1.0.0.tar.gz
| Download URL | mo2_vfs_py-1.0.0.tar.gz |
|---|---|
| Size | 7.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6114fdb9429683087dc8d86c21ca2aa82b875c89fcd99213360a05f8bf6a0004
|
|
BLAKE2b-256 checksum How to use checksums |
41655303c215eeb540959638cc3e793d554e49ac1d75d8cc3f2c7ee7db91601e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"12","id":"bookworm","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / mo2_vfs_py-1.0.0-py3-none-any.whl
| Download URL | mo2_vfs_py-1.0.0-py3-none-any.whl |
|---|---|
| Size | 9.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6d404328117c932683630bb6ceff9e06924b2d7101cf7a63d9b51198e4cc577c
|
|
BLAKE2b-256 checksum How to use checksums |
b99aa1ec7be1257a1ae6eaf081d0e7ab2f06e75c49db8387ba2a8135c55d88c0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"12","id":"bookworm","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for mo2-vfs.py 1.0.0
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.