Repository navigation
Rewrite AutoTidy in Rust + Tauri (v2.0.0) - #67
Merged
Merged
Conversation
Replaces the Python/PyQt6 implementation with a Rust engine and a Tauri
shell. Existing config and history are read in place from %APPDATA%;
upgrading requires nothing of the user.
installer 73 MB -> 1.8 MB executable 33.5 MB -> 4.9 MB
add-folder 74 ms -> 21 ms 8,000 files 7.4 s -> 0.6 s
For a Downloads folder with a few dozen files an hour none of that speed
is observable. Size, launch behaviour, and two scanning modes the old
architecture could not support are the real changes.
Verification
------------
Rewriting software that deletes files cannot rest on a careful read, so
the 1.5.0 engine is retained under legacy/ as an executable specification
and two harnesses diff the two engines over a purpose-built corpus:
run_parity.py compares the decisions each makes, wet_parity.py runs both
for real over disposable copies and diffs the resulting trees. The second
exists because 1.5.0's collision handling sits inside `if not dry_run:`
and a dry run cannot reach it.
251 Rust tests, 76 legacy tests, dry parity 12/12, wet parity 11/11.
Bugs this found, all present in 1.5.0
-------------------------------------
* Glob matching is case-insensitive on Windows (fnmatch normcases both
operands). A case-sensitive port would have silently stopped matching
files that users' existing rules match.
* A {FILENAME}-style destination template lost its rename, filing files
under the original name. Only reachable on a real run.
* 77 history records carry no run_id; in Rust they deserialise to "" and
would have collapsed into one undoable run that a click would unwind.
* --add-folder raced the running app for config.json and lost changes.
* The Explorer context menu required administrator rights, and so was
effectively unavailable. Now per-user.
* Config writes were not atomic.
Also fixed here
---------------
* The CLI and the app both linked to target/release/autotidy.exe on a
case-insensitive filesystem, so whichever built last won. The wet
harness then "ran the engine", actually launched the GUI, moved
nothing, and reported every variant as a divergence. The CLI is now
autotidy-cli, and the harness verifies the binary before trusting it.
* The NSIS installer detects a 1.5.0 install and offers to remove it;
Windows treats them as unrelated products and would run both at once.
* Explorer context-menu invocations short-circuit before the Tauri
runtime is built, which had made them 4.5x slower than 1.5.0.
Repository
----------
Python moves to legacy/ and is marked linguist-vendored, so the root
reads as the Rust project it now is. README rewritten. Code signing
policy and privacy statement added for a pending SignPath Foundation
application; no release is signed yet.
Not yet verified: nobody has driven a real file move through the shipped
UI end to end. The engine is covered by tests and both harnesses, the
commands by unit tests, and the UI against a stubbed IPC bridge.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the Python/PyQt6 implementation with a Rust engine and a Tauri shell. Existing config and history are read in place from %APPDATA%; upgrading requires nothing of the user.
installer 73 MB -> 1.8 MB executable 33.5 MB -> 4.9 MB
add-folder 74 ms -> 21 ms 8,000 files 7.4 s -> 0.6 s
For a Downloads folder with a few dozen files an hour none of that speed is observable. Size, launch behaviour, and two scanning modes the old architecture could not support are the real changes.
Verification
Rewriting software that deletes files cannot rest on a careful read, so the 1.5.0 engine is retained under legacy/ as an executable specification and two harnesses diff the two engines over a purpose-built corpus: run_parity.py compares the decisions each makes, wet_parity.py runs both for real over disposable copies and diffs the resulting trees. The second exists because 1.5.0's collision handling sits inside
if not dry_run:and a dry run cannot reach it.251 Rust tests, 76 legacy tests, dry parity 12/12, wet parity 11/11.
Bugs this found, all present in 1.5.0
Also fixed here
Repository
Python moves to legacy/ and is marked linguist-vendored, so the root reads as the Rust project it now is. README rewritten. Code signing policy and privacy statement added for a pending SignPath Foundation application; no release is signed yet.
Not yet verified: nobody has driven a real file move through the shipped UI end to end. The engine is covered by tests and both harnesses, the commands by unit tests, and the UI against a stubbed IPC bridge.
Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes # (issue)
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Test Configuration:
Checklist: