New comment by pullmoll on void-packages repository https://github.com/void-linux/void-packages/pull/22377#issuecomment-635315105 Comment: The patch to disambiguate the `LTS`, `Nightly`, and `SnapName` gets the build farther than before. This is the current error message for `src/Stack/Config.hs`: ``` [ 68 of 109] Compiling Stack.Config ( src/Stack/Config.hs, /builddir/stack-2.3.1/dist-newstyle/build/x86_64-linux/ghc-8.8.3/stack-2.3.1/build/Stack/Config.o ) src/Stack/Config.hs:158:32: error: • Variable not in scope: nightlySnapshotLocation :: time-1.9.3:Data.Time.Calendar.Days.Day -> RawSnapshotLocation • Perhaps you meant ‘defaultSnapshotLocation’ (imported from Stack.Prelude) | 158 | ARLatestNightly -> nightlySnapshotLocation . snapshotsNightly <$> getSnapshots | ^^^^^^^^^^^^^^^^^^^^^^^ src/Stack/Config.hs:163:40: error: • Variable not in scope: ltsSnapshotLocation :: Int -> Int -> RawSnapshotLocation • Perhaps you meant one of these: ‘snapshotLocation’ (imported from Stack.Prelude), ‘smwSnapshotLocation’ (imported from Stack.Types.SourceMap) | 163 | Just y -> return $ ltsSnapshotLocation x y | ^^^^^^^^^^^^^^^^^^^ src/Stack/Config.hs:169:37: error: • Variable not in scope: ltsSnapshotLocation :: IntMap.Key -> Int -> RawSnapshotLocation • Perhaps you meant one of these: ‘snapshotLocation’ (imported from Stack.Prelude), ‘smwSnapshotLocation’ (imported from Stack.Types.SourceMap) | 169 | in return $ ltsSnapshotLocation x y | ^^^^^^^^^^^^^^^^^^^ src/Stack/Config.hs:177:24: error: • Variable not in scope: ltsSnapshotLocation :: IntMap.Key -> Int -> RawSnapshotLocation • Perhaps you meant one of these: ‘snapshotLocation’ (imported from Stack.Prelude), ‘smwSnapshotLocation’ (imported from Stack.Types.SourceMap) | 177 | let mlts = uncurry ltsSnapshotLocation <$> | ^^^^^^^^^^^^^^^^^^^ src/Stack/Config.hs:179:23: error: • Variable not in scope: nightlySnapshotLocation :: time-1.9.3:Data.Time.Calendar.Days.Day -> RawSnapshotLocation • Perhaps you meant ‘defaultSnapshotLocation’ (imported from Stack.Prelude) | 179 | pure $ fromMaybe (nightlySnapshotLocation (snapshotsNightly snapshots)) mlts | ^^^^^^^^^^^^^^^^^^^^^^^ src/Stack/Config.hs:374:6: error: • Couldn't match expected type ‘RIO env a’ with actual type ‘(PantryConfig -> RIO env0 a0) -> RIO env0 a0’ • Probable cause: ‘withPantryConfig’ is applied to too few arguments In a stmt of a 'do' block: withPantryConfig pantryRoot hsc (maybe HpackBundled HpackCommand $ getFirst configMonoidOverrideHpack) clConnectionCount (fromFirst defaultCasaRepoPrefix configMonoidCasaRepoPrefix) defaultCasaMaxPerRequest (\ configPantryConfig -> initUserStorage (configStackRoot relFileStorage) (\ configUserStorage -> inner Config {..})) In the expression: do mstackWorkEnv <- liftIO $ lookupEnv stackWorkEnvVar let mproject = ... configAllowLocals = ... configWorkDir0 <- maybe (return relDirStackWork) (liftIO . parseRelDir) mstackWorkEnv let configWorkDir = fromFirst configWorkDir0 configMonoidWorkDir configLatestSnapshot = fromFirst "https://s3.amazonaws.com/haddock.stackage.org/snapshots.json" configMonoidLatestSnapshot .... .... In an equation for ‘configFromConfigMonoid’: configFromConfigMonoid configStackRoot configUserConfigPath configResolver configProject ConfigMonoid {..} inner = do mstackWorkEnv <- liftIO $ lookupEnv stackWorkEnvVar let mproject = ... .... configWorkDir0 <- maybe (return relDirStackWork) (liftIO . parseRelDir) mstackWorkEnv .... • Relevant bindings include inner :: Config -> RIO env a (bound at src/Stack/Config.hs:193:36) configFromConfigMonoid :: Path Abs Dir -> Path Abs File -> Maybe AbstractResolver -> ProjectConfig (Project, Path Abs File) -> ConfigMonoid -> (Config -> RIO env a) -> RIO env a (bound at src/Stack/Config.hs:191:1) | 374 | withPantryConfig | ^^^^^^^^^^^^^^^^... src/Stack/Config.hs:381:32: error: • Couldn't match expected type ‘RawSnapshotLocation’ with actual type ‘RIO env a’ • In the expression: initUserStorage (configStackRoot relFileStorage) (\ configUserStorage -> inner Config {..}) In the 7th argument of ‘withPantryConfig’, namely ‘(\ configPantryConfig -> initUserStorage (configStackRoot relFileStorage) (\ configUserStorage -> inner Config {..}))’ In a stmt of a 'do' block: withPantryConfig pantryRoot hsc (maybe HpackBundled HpackCommand $ getFirst configMonoidOverrideHpack) clConnectionCount (fromFirst defaultCasaRepoPrefix configMonoidCasaRepoPrefix) defaultCasaMaxPerRequest (\ configPantryConfig -> initUserStorage (configStackRoot relFileStorage) (\ configUserStorage -> inner Config {..})) • Relevant bindings include inner :: Config -> RIO env a (bound at src/Stack/Config.hs:193:36) configFromConfigMonoid :: Path Abs Dir -> Path Abs File -> Maybe AbstractResolver -> ProjectConfig (Project, Path Abs File) -> ConfigMonoid -> (Config -> RIO env a) -> RIO env a (bound at src/Stack/Config.hs:191:1) | 381 | (\configPantryConfig -> initUserStorage | ^^^^^^^^^^^^^^^... src/Stack/Config.hs:383:39: error: • Couldn't match expected type ‘PantryConfig’ with actual type ‘Stack.Prelude.SnapName’ • In the ‘configPantryConfig’ field of a record In the first argument of ‘inner’, namely ‘Config {..}’ In the expression: inner Config {..} | 383 | (\configUserStorage -> inner Config {..})) | ^^^^^^^^^^^ => ERROR: stack-2.3.1_1: do_build: 'HOME=$PWD cabal new-build ${makejobs} --flag disable-git-info' exited with 1 => ERROR: in do_build() at srcpkgs/stack/template:24 ```