feat(core,fuse,cli,gui): discard a queued change and undo it here

A change Drive will not take could be exported or retried, never let go
of. The Sync page's Discard button (with a confirmation) and
`pdfs sync discard <id>` drop it: a node made here goes, as if deleted
before it was sent; a node Drive has goes back to what Drive has, under
the same inode, with every change queued on it, while what is queued
below it stays. A change on the wire or an open file is refused.
This commit is contained in:
nvrl committed 2026-10-05 00:57:02 +02:00
1 parent da013c29d6
commit 9dfe4c5450
22 files changed
+1530 -710

No files matched your search

+3
View File
@@ -26,6 +26,9 @@ by its local id, in the queue, the stored tree and pins alike.
save a copy of a queued upload's content. The upload stays queued.
- **`pdfs sync issues`** lists the changes that need attention; `pdfs sync queue` shows the
issue next to each change.
- **Discard a queued change.** The Sync page's Discard button and `pdfs sync discard <id>` drop
a change Drive will not take and undo it here: a new file or folder goes, anything else goes
back to what Drive has. Export a file first to keep its content.
### Changed
- **Making, renaming and deleting through the mount no longer waits for Drive.** A new folder,
+3
View File
@@ -82,6 +82,9 @@ commands are for scripts and for cases where the mount is not available.
| `pdfs sync resume [--folder ID]` | Resume after a pause. |
| `pdfs sync limit [--up RATE] [--down RATE]` | Cap bandwidth, for example `500K` or `2M` per second. `0` removes a cap. Without options, prints the current caps. |
| `pdfs sync queue` | List changes that have not reached Proton Drive yet. |
| `pdfs sync issues` | List queued changes Proton Drive refused or that keep failing, and what to do. |
| `pdfs sync export ID DEST` | Save a copy of a queued upload's content. The upload stays queued. |
| `pdfs sync discard ID [--yes]` | Drop a queued change and undo it here: a new file or folder goes, anything else goes back to what Proton Drive has. Content not exported first is lost. |
| `pdfs sync retry [ID]` | Retry one queued operation, or every failed one. |
| `pdfs sync restore [--device UID] [--yes]` | Re-attach this computer's backed-up folders to local folders and download them. `--device` restores another computer's folders. See [RECOVERY.md](RECOVERY.md). |
+6 -3
View File
@@ -11,7 +11,8 @@ Tracks `docs/MILESTONE-3.0.0.md`. Update it with every commit that moves a phase
locally and sent from the queue; `"local_first": false` brings back the old path (5e0f30c).
- Fixes from the simulation and account runs since then: B125, B127, B130 and B141 to B181.
- **Sync issues, first cut** (§6.2): refusals sorted into issues, shown at once in the app,
tray and CLI; Export button and `pdfs sync export`; `pdfs sync issues`.
tray and CLI; Export button and `pdfs sync export`; `pdfs sync issues`; Discard button and
`pdfs sync discard`.
## Phase 3: left for 3.0.0
@@ -27,8 +28,10 @@ Tracks `docs/MILESTONE-3.0.0.md`. Update it with every commit that moves a phase
- [x] A name collision lands under a conflict name (create, rename, move, re-homed create)
and goes in the activity log, as does a queued edit kept as a conflict copy. The app
words each one in the user's language (the last one since B181).
- [ ] Discard an issue on purpose (after export, or for a change with no content), and
undo the local change it stood for. Not in the first cut.
- [x] Discard an issue on purpose (after export, or for a change with no content), and
undo the local change it stood for: a node made here goes, a node Drive has goes back
to what Drive has. Control request, `pdfs sync discard`, Discard button with a
confirmation; translated in every catalog.
- [ ] Show the issue on the node itself (file browser emblem or status). Not in the first
cut.
2. **Planner and executor (§5.4, §5.5)**: ops keyed by local id; remove `mint_local_uid`,
+7 -1
View File
@@ -128,7 +128,13 @@ pdfs sync retry 42 # one operation
```
The app shows the same list on **Sync → Overview**. An operation that keeps failing shows its
error there.
error there. A change Proton Drive will not take can be dropped instead, which undoes it here;
save a file's content first if you want to keep it:
```bash
pdfs sync export 42 ~/Desktop/
pdfs sync discard 42
```
**A file in a synced folder does not upload** — check that:
+2
View File
@@ -167,6 +167,8 @@ The version you do not keep goes to the Trash, so a wrong choice can be undone.
- **Limit bandwidth** under **Preferences → General → Network**, or with
`pdfs sync limit --up 2M --down 10M`. `0` removes a limit.
- **Retry** a failed upload from **Sync → Overview**, or with `pdfs sync retry`.
- **Discard** a change Proton Drive refused from the same list, or with `pdfs sync discard`: it is
undone here and never sent. Export a file first to keep your version.
## Photos