fix(torrent): harden lifecycle and properties state

- admit valid magnets immediately while keeping metadata refresh optional
- fence Torrent recovery, diagnostics, and allocation presentation by lifecycle
- avoid false peer-wait claims when telemetry is missing or malformed
- stabilize Properties metric label/value layout for narrow and RTL windows

Tests:
- npm test -- --run
- npm run build
- npm run check:i18n
- node --test scripts/*.node-test.js
- cargo test --all-targets
- npm run smoke:torrent
- npm run smoke:torrent:failure-paths
- git diff --check
This commit is contained in:
NimBold
2026-08-24 15:51:24 +03:30
parent a6b341f9e3
commit b5ee53140d
20 changed files with 452 additions and 84 deletions
+7
View File
@@ -108,6 +108,13 @@ fn headless_queue_lifecycle_eligibility_and_retry_contracts_hold() {
..SpawnPayload::default()
})
);
assert!(
!QueueManager::<tauri::Wry>::aria2_allocation_phase_eligible(&SpawnPayload {
is_torrent: true,
torrent_file_allocation: Some("prealloc".to_string()),
..SpawnPayload::default()
})
);
assert_eq!(backoff_for(0), Duration::from_secs(2));
assert_eq!(backoff_for(usize::MAX), Duration::from_secs(10));
assert_eq!(