mixxxdj / mixxx

Mixxx is Free DJ software that gives you everything you need to perform live mixes.
http://mixxx.org
Other
4.48k stars 1.28k forks source link

Playing a duplicate track with same location crashes Mixxx with debug assert #13140

Open fwcd opened 6 months ago

fwcd commented 6 months ago

Bug Description

It seems that playing one of two tracks with the same location can crash Mixxx (if debug asserts are enabled):

warning [Main] GlobalTrackCache - Found a different track for the same canonical location: requested =  TrackRef {"<path/to/my/track>","<path/to/my/track>",90208} cached =  TrackRef {"<path/to/my/track>","<path/to/my/track>",90586}
DEBUG ASSERT: "!trackId.isValid() || trackId == cacheResolver.getTrackRef().getId()" in function TrackPointer TrackDAO::getTrackById(TrackId) const at src/library/dao/trackdao.cpp:1440
zsh: abort      build-2.4/mixxx

Not sure why this duplicate track got there in the first place, but probably something worth addressing (if this constraint isn't handled at the db level).

Version

2.4 (f225751515)

OS

macOS 14.4.1

ronso0 commented 3 weeks ago

Not sure why this duplicate track got there in the first place, but probably something worth addressing (if this constraint isn't handled at the db level).

quoting myself from #13685 FWIW I couldn't duplicate a track with DB Browser for SQlite, it prevents that: Error changing data: UNIQUE constraint failed: track_locations.location