API Reference¶
Complete reference for all public symbols exported by pyfs_watcher.
Summary¶
| Symbol | Category | Description |
|---|---|---|
walk() |
Walk | Streaming directory traversal |
walk_collect() |
Walk | Collect all entries at once |
WalkEntry |
Walk | Single directory entry |
WalkIter |
Walk | Streaming walk iterator |
hash_file() |
Hash | Hash a single file |
hash_files() |
Hash | Hash multiple files in parallel |
HashResult |
Hash | Hash result with metadata |
copy_files() |
Copy/Move | Copy files with progress |
move_files() |
Copy/Move | Move files with smart fallback |
CopyProgress |
Copy/Move | Progress snapshot |
FileWatcher |
Watch | Filesystem watcher |
FileChange |
Watch | Single change event |
async_watch() |
Watch | Async watch generator |
find_duplicates() |
Dedup | Find duplicate files |
DuplicateGroup |
Dedup | Group of duplicate files |
search() |
Search | Parallel content search |
search_iter() |
Search | Streaming content search |
SearchResult |
Search | Matches in a single file |
SearchMatch |
Search | Single line match |
SearchIter |
Search | Streaming search iterator |
diff_dirs() |
Diff | Compare two directories |
DirDiff |
Diff | Comparison result |
DiffEntry |
Diff | Single differing file |
MovedEntry |
Diff | Detected moved file |
sync() |
Sync | Incremental directory sync |
SyncResult |
Sync | Sync operation result |
SyncProgress |
Sync | Sync progress snapshot |
SyncFileError |
Sync | Per-file sync error |
snapshot() |
Snapshot | Create filesystem snapshot |
verify() |
Snapshot | Verify snapshot integrity |
Snapshot |
Snapshot | Snapshot object |
SnapshotEntry |
Snapshot | Single snapshot entry |
VerifyResult |
Snapshot | Verification result |
VerifyChange |
Snapshot | Single detected change |
disk_usage() |
Disk Usage | Parallel size calculation |
DiskUsage |
Disk Usage | Usage result |
DiskUsageEntry |
Disk Usage | Per-child breakdown |
bulk_rename() |
Rename | Regex-based batch rename |
RenameResult |
Rename | Rename operation result |
RenameEntry |
Rename | Single rename mapping |
RenameFileError |
Rename | Per-file rename error |
Exceptions¶
| Exception | Description |
|---|---|
FsWatcherError |
Base exception for all errors |
WalkError |
Directory walk failure |
HashError |
Hashing failure |
CopyError |
Copy/move failure |
WatchError |
File watching failure |
SearchError |
Content search failure |
DirDiffError |
Directory diff failure |
SyncError |
Sync failure |
SnapshotError |
Snapshot/verify failure |
DiskUsageError |
Disk usage failure |
RenameError |
Bulk rename failure |
Import¶
Functions and the FileWatcher class are available from the top-level package:
from pyfs_watcher import (
walk, walk_collect, hash_file, hash_files,
copy_files, move_files, FileWatcher, async_watch,
find_duplicates, search, search_iter, diff_dirs,
sync, snapshot, verify, disk_usage, bulk_rename,
)
Data classes and result types live in pyfs_watcher.types:
from pyfs_watcher.types import (
WalkEntry, HashResult, CopyProgress, FileChange,
DuplicateGroup, SearchResult, SearchMatch, SearchIter,
DirDiff, DiffEntry, MovedEntry,
SyncResult, SyncProgress, SyncFileError,
Snapshot, SnapshotEntry, VerifyResult, VerifyChange,
DiskUsage, DiskUsageEntry,
RenameResult, RenameEntry, RenameFileError,
)
Exceptions live in pyfs_watcher.errors: