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
Currently when we want vabal to suggest a ghc version to compile our cabal package, we can pass it two flags to alter its behavior: --try-hard and --try-super-hard.
The --try-hard flag makes vabal choose a ghc version that actually makes cabal v2-configure succeed, while currently the default behavior is to just read the version constraints on base and Cabal and choose a ghc version that fulfills them, therefore ignoring other dependencies ( see #19 ).
It runs cabal v2-build --dry for each ghc version compatible (actually not all, but one for each base version, i.e. it won't try both 8.6.4 and 8.6.3, but only 8.6.4) with the version constraints of base and Cabal.
Instead --try-super-hard runs cabal v2-buildfor eachghc compatible with base and Cabal version constraints, so it is only actually needed in very strange situations.
I think that --try-hard should be the default behavior because it is more beginner-friendly, since it suggests a ghc version taking into account all dependencies, thus guaranteeing that the package configuration be successful. On the other hand it has a more complex and is slower (potentially a lot slower, but it depends on how badly are the constraints defined, even if on pratical cases I have tested vabal on, it just had to try at most 2 ghc versions before giving a answer)
Currently when we want
vabal
to suggest aghc
version to compile our cabal package, we can pass it two flags to alter its behavior:--try-hard
and--try-super-hard
.The
--try-hard
flag makesvabal
choose aghc
version that actually makescabal v2-configure
succeed, while currently the default behavior is to just read the version constraints onbase
andCabal
and choose aghc
version that fulfills them, therefore ignoring other dependencies ( see #19 ).It runs
cabal v2-build --dry
for eachghc
version compatible (actually not all, but one for eachbase
version, i.e. it won't try both8.6.4
and8.6.3
, but only8.6.4
) with the version constraints ofbase
andCabal
.Instead
--try-super-hard
runscabal v2-build
for eachghc
compatible withbase
andCabal
version constraints, so it is only actually needed in very strange situations.I think that
--try-hard
should be the default behavior because it is more beginner-friendly, since it suggests a ghc version taking into account all dependencies, thus guaranteeing that the package configuration be successful. On the other hand it has a more complex and is slower (potentially a lot slower, but it depends on how badly are the constraints defined, even if on pratical cases I have testedvabal
on, it just had to try at most 2 ghc versions before giving a answer)I would like to hear some feedback, though
/CC @zenhack @fgaz @jabberabbe @lortabac
The text was updated successfully, but these errors were encountered: