Skip to content

Fix assert stanza disabled not available - #12080

Merged
mergify[bot] merged 2 commits into
haskell:masterfrom
cabalism:fix/assert-stanza-disabled-not-available
Jul 27, 2026
Merged

Fix assert stanza disabled not available#12080
mergify[bot] merged 2 commits into
haskell:masterfrom
cabalism:fix/assert-stanza-disabled-not-available

Conversation

@philderbeast

Copy link
Copy Markdown
Collaborator

Fix #11568. This is the work of @hasufell in #11567 but isolated and extracted to only fix the assertion.

Note

Tests were added previously in #12069. The assertion was removed then. We add it back with this fix.


Template Α: This PR modifies behaviour or interface

Include the following checklist in your PR:

@philderbeast
philderbeast force-pushed the fix/assert-stanza-disabled-not-available branch 3 times, most recently from ce31f0a to 6078c65 Compare July 3, 2026 11:23
@philderbeast
philderbeast force-pushed the fix/assert-stanza-disabled-not-available branch from 6078c65 to 09d9332 Compare July 5, 2026 11:28

@jappeace jappeace left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

looks good :)

@Mikolaj Mikolaj left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It looks plausible and definitely a good practice to split things up and thank you for re-adding the assertion.

philderbeast and others added 2 commits July 24, 2026 10:31
- Fix assertion failure wrt haskell#11568 'lookupLocalPackageConfig' would ignore --'projectConfigAllPackages'
(`package *`) and thus diverge from 'lookupPerPkgOption'. This would then cause further divergence between 'elabStanzasRequested'
and 'elabStanzasAvailable'.
Change arg order with perPkgOptionFlag, def first
Use function composition for perPkgOption*
Add type sigs for all perPkgOption* functions
Inline each perPkgOption* only used once
Use -XViewPatterns in perPkgOptionLibExeFlag
Partially apply then use lookupPerPkgOption
Move Map.fromList in list comprehension
Use -XViewPattern in Just pkgId branch
Defer (TestStanzas,) & (BenechStanzas,) tuples
Remove lookupLocalPackageConfig

Co-Authored-By: Julian Ospald <hasufell@posteo.de>
@philderbeast
philderbeast force-pushed the fix/assert-stanza-disabled-not-available branch from 09d9332 to 6ef5fc1 Compare July 24, 2026 14:32
@philderbeast philderbeast added the merge me Tell Mergify Bot to merge label Jul 24, 2026
@mergify mergify Bot added ready and waiting Mergify is waiting out the cooldown period merge delay passed Applied (usually by Mergify) when PR approved and received no updates for 2 days queued labels Jul 25, 2026
@mergify

mergify Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Merge Queue Status

This pull request spent 2 hours 2 minutes 54 seconds in the queue, including 1 hour 52 minutes running CI.

Required conditions to merge
  • #review-threads-unresolved = 0 [🛡 GitHub branch protection]
  • github-review-approved [🛡 GitHub branch protection] (documentation)
  • any of [🛡 GitHub branch protection]:
    • check-success = Doctest Cabal
    • check-neutral = Doctest Cabal
    • check-skipped = Doctest Cabal
  • any of [🛡 GitHub branch protection]:
    • check-success = Meta checks
    • check-neutral = Meta checks
    • check-skipped = Meta checks
  • any of [🛡 GitHub branch protection]:
    • check-success = docs/readthedocs.org:cabal
    • check-neutral = docs/readthedocs.org:cabal
    • check-skipped = docs/readthedocs.org:cabal
  • any of [🛡 GitHub branch protection]:
    • check-success = Validate post job
    • check-neutral = Validate post job
    • check-skipped = Validate post job
  • any of [🛡 GitHub branch protection]:
    • check-success = fourmolu
    • check-neutral = fourmolu
    • check-skipped = fourmolu
  • any of [🛡 GitHub branch protection]:
    • check-success = hlint
    • check-neutral = hlint
    • check-skipped = hlint
  • any of [🛡 GitHub branch protection]:
    • check-success = Bootstrap post job
    • check-neutral = Bootstrap post job
    • check-skipped = Bootstrap post job
  • any of [🛡 GitHub branch protection]:
    • check-success = whitespace
    • check-neutral = whitespace
    • check-skipped = whitespace
  • any of [🛡 GitHub branch protection]:
    • check-success = Check sdist post job
    • check-neutral = Check sdist post job
    • check-skipped = Check sdist post job
  • any of [🛡 GitHub branch protection]:
    • check-success = Changelogs
    • check-neutral = Changelogs
    • check-skipped = Changelogs

@mergify
mergify Bot merged commit a12f04d into haskell:master Jul 27, 2026
99 of 103 checks passed
@mergify mergify Bot removed the queued label Jul 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge delay passed Applied (usually by Mergify) when PR approved and received no updates for 2 days merge me Tell Mergify Bot to merge ready and waiting Mergify is waiting out the cooldown period

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Assertion failure for "stanzas explicitly disabled should not be available"

3 participants