"Join with previous" loses data (with fix)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mixxx |
Fix Released
|
Medium
|
Steven Boswell |
Bug Description
I selected "Join with previous" while doing a library-rescan, and it deleted the set-log without moving its tracks into the previous set-log! There was a debug message written to stdout, explaining that the query failed because the database was locked, but it didn't recover gracefully from that, and lost data!
Also, "Join with previous" doesn't preserve the date/time that the track was added to the previous playlist -- instead, the current date/time was used.
Finally, the date/time last played is only displayed as the time in the set-log, instead of the date/time.
The enclosed patch fixes all three issues.
PlaylistDAO's appendTracksToP
copyPlaylistTra
This patch is against the master branch. It should integrate without trouble into the 1.11 release branch.
Changed in mixxx: | |
milestone: | none → 1.11.1 |
importance: | Undecided → Medium |
Changed in mixxx: | |
status: | Fix Committed → Fix Released |
Changed in mixxx: | |
milestone: | 1.11.1 → 2.0.0 |
Thanks Steven! Committed to lp:mixxx/1.11
Minor style issue for future ref:
- if (newPlaylistId != -1) { copyPlaylistTra cks(oldPlaylist Id, newPlaylistId))
emit( showTrackModel( m_pPlaylistTabl eModel) );
+ if (newPlaylistId != -1
+ && m_playlistDao.
- }
When an expression is dangling across lines, please keep the logic operator (e.g. the &&) at the end of the line so that as you scan, you naturally see the expression is continued because the binary operator is there without its right operand. Also, single line bodies of if statements should have braces.
The time-only in session playlists is intentional -- Daniel did that when he wrote the feature, I think to allow you to more easily tell how far into your set you played the track. If that was the intention then I think we should be showing the (date - first-track- start-date) as a duration instead. Daniel -- can you comment?