You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cabal-1.20.0.0 (2014-04-20) introduced the --allow-newer[=pkgs] option to ignore the upper bound on all dependencies or dependencies on specified packages in Cabal files.
Stack 0.1.8.0 (2015-11-20) added an allow-newer configuration option, to ignore the bounds in Cabal files. It took its name from the Cabal option, despite having a different function.
Cabal-2.0.0.2 (2017-07-24) introduced a scope syntax to --allow-newer.
Cabal-2.0.0.2 (2017-07-24) also introduced an --allow-older[=pkgs] option.
Stack 2.9.3 (2022-12-16) allowed the Cabal files in which bounds would be ignored to be specified (with allow-newer-deps, following the form of allow-newer).
Stack 3.1.1 (2024-07-28) allowed --[no-]allow-deps on the command line (following the form of allow-newer).
This has confused some users, who expect that:
Stack's allow-newer configuration option should function as Cabal's --allow-newer option; and
are not sure if allow-newer-deps is allow-newer-in-deps (like the scoping in Cabal's option) or allow-newer-over-deps (like Cabal's option) - it is the former.
Given the passage of over 10 years, the ship may have sailed, but perhaps more descriptive Stack configuration options would be:
ignore-bounds \ --ignore-bounds
ignore-bounds-in
In respect of the bounds in the Cabal files of package versions included in a snapshot, Stack always trusts the snapshot over the Cabal files.
Seconded! I keep tripping over this, and expecting allow-newer to only ever upgrade.
Thankfully this time I noticed the warning message noting the selected version and knew it was a downgrade to what I was expecting, but I've had long code archeology sessions due to the mismatch between the version I was expecting and what ghc was actually looking at. I'm looking at the viability of giving up on stack for a current project due to this being a perennial issue.
(This is for another issue, but is there any appetite for giving stack a flag with Cabal's semantics here?)
Activity
Re #6930 Improve allow-newer documentation
hseg commentedon Sep 22, 2026
Seconded! I keep tripping over this, and expecting
allow-newerto only ever upgrade.Thankfully this time I noticed the warning message noting the selected version and knew it was a downgrade to what I was expecting, but I've had long code archeology sessions due to the mismatch between the version I was expecting and what
ghcwas actually looking at. I'm looking at the viability of giving up onstackfor a current project due to this being a perennial issue.(This is for another issue, but is there any appetite for giving
stacka flag with Cabal's semantics here?)Convert to use cabal for building