-
-
Notifications
You must be signed in to change notification settings - Fork 419
PICARD-3118: Allow user to save/load current Picard session #2731
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PICARD-3118: Allow user to save/load current Picard session #2731
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just few comments, I didn't test yet (I will soon).
That's a very promising improvement :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure about the automatic saving (based on time).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
UI-wise it works well, thanks for all recent additions.
And it works well.
Though I have concerns about only saving 3 options, and IMHO this isn't enough (see my comment about that)
Resolved conflicts by: - Keeping enable_tag_saving handler from master in mainwindow/__init__.py - Merging session-related options with master's filter column defaults in options.py - Preserving session constants while adding master's DEFAULT_FILTER_COLUMNS in defaults.py
b9d8434
to
1bee982
Compare
Try now. All test comments should have been addressed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Summary
Problem
Users lose their work state when closing Picard, including file placements, manual metadata edits, and album configurations.
Solution
Core Components
Session Data Structures (
session_data.py
):SessionItemLocation
: Tracks file placement (unclustered, cluster, album, track, NAT)SessionData
: Complete session container with version, options, items, and metadata overridesSession Exporter (
session_exporter.py
):~
tags)Session Loader (
session_loader.py
):Supporting Modules:
location_detector.py
: Determines file placement within session structuremetadata_handler.py
: Serializes/deserializes metadata with error handlingtrack_mover.py
: Handles file-to-track movement with retry logicretry_helper.py
: Centralized retry mechanismKey Features
session_safe_restore
setting to prevent overwriting unsaved changesFile Format
.mbps.gz
(gzip-compressed YAML)Configuration Options
Five new options added:
session_safe_restore
: Honor local edits on load (default: True)session_load_last_on_startup
: Auto-load last session (default: False)session_autosave_interval_min
: Auto-save interval in minutes (default: 0 = disabled)session_backup_on_crash
: Keep backup on unexpected shutdown (default: True)session_include_mb_data
: Include MB data in sessions (default: False)Action
Additional actions required: