Repository navigation
Detect a twelve-bar blues by bars, not chord count [patch] - #428
Merged
Merged
Conversation
IsTwelveBarBlues required exactly twelve chord events and ignored their durations, so three bars of quarter-note chords were called a blues and a real twelve-bar blues with held chords was not. The section must now last exactly twelve bars, and each bar is represented by the chord sounding on its downbeat. The existing blues test used twelve one-beat cells, the three-bar false positive itself, so it now writes each chord as a full bar. Fixes #317 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SWJoWcEC3BuVS7pSPco7mA
Keeps them clear of the #314 tests so the two PRs merge independently. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SWJoWcEC3BuVS7pSPco7mA
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Fixes #317
What changed
Form.IsTwelveBarBluesrequired exactly 12 chord events and never looked at their durations. Three bars of quarter-note chords were therefore called a blues, while a real 12-bar blues with held chords was not.The detector now works bar by bar:
Durationfractions, notTotalBarsdoubles.Tests
Of_RecognizesTwelveBarBluesused"C7 | C7 | …". A chart cell is one beat, so that chart is three bars long and was the false positive from the issue. It now writes each chord as a full bar (C7 / / /).The three new tests fail on
main. All 354 Music tests pass on this branch, and the local Sonar build reports nothing inForm.cs.This touches the same file as #427 (#314), but a different method, so the two should merge independently.
🤖 Generated with Claude Code
https://claude.ai/code/session_01SWJoWcEC3BuVS7pSPco7mA
Generated by Claude Code