Skip to content
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

Remove Beats::findNthBeat fuzzy behavior #4099

Merged
merged 5 commits into from
Jul 24, 2021

Conversation

Holzhaus
Copy link
Member

@Holzhaus Holzhaus commented Jul 11, 2021

BeatmapTest.TestBpmAround fails for unknown reasons. Either the test is wrong, or our test coverage of the findNthBeat method is insufficient. I'll have to check later on.

EDIT: Works now.

I only removed two tests that explicitly tested this weird behavior. All other tests passed, so if this fuzzy behavior was indeed necessary for some feature, it should have been mentioned in a comment or required by a test case.

I suggest to merge this, unless we find major issues. Maybe we need it for beatjumps/looping, but in that case we should request snapping explicitly before called findNthBeat. I wrote a small convenience method that could be used for this.

@Holzhaus Holzhaus changed the title BeatMap: Reimplement findNthBeat without fuzzy behavior Remove Beats::findNthBeat fuzzy behavior Jul 12, 2021
@coveralls
Copy link

coveralls commented Jul 12, 2021

Pull Request Test Coverage Report for Build 1062636948

  • 29 of 29 (100.0%) changed or added relevant lines in 2 files are covered.
  • 795 unchanged lines in 15 files lost coverage.
  • Overall coverage decreased (-0.03%) to 28.614%

Files with Coverage Reduction New Missed Lines %
src/track/beatmap.h 1 60.0%
src/library/export/dlglibraryexport.cpp 2 1.29%
src/track/beatmap.cpp 4 76.97%
src/controllers/scripting/colormapperjsproxy.cpp 5 78.57%
src/engine/enginebuffer.cpp 15 86.22%
src/engine/sync/internalclock.cpp 20 80.51%
src/track/cue.cpp 20 65.56%
src/util/versionstore.cpp 23 1.3%
src/track/beatgrid.cpp 25 73.56%
src/engine/sync/enginesync.cpp 38 85.56%
Totals Coverage Status
Change from base Build 1022999157: -0.03%
Covered Lines: 20084
Relevant Lines: 70189

💛 - Coveralls

@Holzhaus Holzhaus marked this pull request as ready for review July 12, 2021 20:35
@Holzhaus Holzhaus added this to In progress in Beats Refactoring Jul 12, 2021
@Holzhaus
Copy link
Member Author

This resolves #3418 btw.

@ywwg
Copy link
Member

ywwg commented Jul 22, 2021

This would not be the first time that some weird logic in Mixxx turned out to be totally useless.

Copy link
Member

@ywwg ywwg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one small nit for clarity

src/track/beatmap.cpp Outdated Show resolved Hide resolved
@Holzhaus Holzhaus requested a review from ywwg July 22, 2021 15:02
src/track/beatmap.cpp Outdated Show resolved Hide resolved
Copy link
Member

@ywwg ywwg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks!

@Holzhaus Holzhaus requested a review from uklotzde July 24, 2021 14:19
Copy link
Contributor

@uklotzde uklotzde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! LGTM

@uklotzde uklotzde merged commit 6ac9b0a into mixxxdj:main Jul 24, 2021
Beats Refactoring automation moved this from In progress to Done Jul 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

4 participants