Skip to content

Inaccurate version bounds in .cabal file #2

@hvr

Description

@hvr

plugins-1.5.5.0 fails to build with ghc-8.0 as well as with its bundled Cabal-1.23 (soon to become Cabal-1.24):

[ 5 of 12] Compiling System.Plugins.Env ( src/System/Plugins/Env.hs, /tmp/plugins-1.5.5.0/dist-newstyle/build/plugins-1.5.5.0/build/System/Plugins/Env.o )

src/System/Plugins/Env.hs:326:21: error:
    • Couldn't match expected type ‘IO (PackageIndex PackageConfig)’
                  with actual type ‘ProgramConfiguration -> IO InstalledPackageIndex’
    • Probable cause: ‘getInstalledPackages’ is applied to too few arguments
      In a stmt of a 'do' block:
        pkgIndex <- getInstalledPackages
                      silent [GlobalPackageDB, UserPackageDB] pc
      In the expression:
        do { pc <- configureAllKnownPrograms
                     silent defaultProgramConfiguration;
             pkgIndex <- getInstalledPackages
                           silent [GlobalPackageDB, UserPackageDB] pc;
             return $ [] `union` allPackages pkgIndex }
      In an equation for ‘grabDefaultPkgConf’:
          grabDefaultPkgConf
            = do { pc <- configureAllKnownPrograms
                           silent defaultProgramConfiguration;
                   pkgIndex <- getInstalledPackages silent [GlobalPackageDB, ....] pc;
                   return $ [] `union` allPackages pkgIndex }

src/System/Plugins/Env.hs:326:49: error:
    • Couldn't match expected type ‘Compiler’
                  with actual type ‘[PackageDB]’
    • In the second argument of ‘getInstalledPackages’, namely
        ‘[GlobalPackageDB, UserPackageDB]’
      In a stmt of a 'do' block:
        pkgIndex <- getInstalledPackages
                      silent [GlobalPackageDB, UserPackageDB] pc
      In the expression:
        do { pc <- configureAllKnownPrograms
                     silent defaultProgramConfiguration;
             pkgIndex <- getInstalledPackages
                           silent [GlobalPackageDB, UserPackageDB] pc;
             return $ [] `union` allPackages pkgIndex }

src/System/Plugins/Env.hs:326:82: error:
    • Couldn't match type ‘Distribution.Simple.Program.Db.ProgramDb’
                     with ‘[PackageDB]’
      Expected type: PackageDBStack
        Actual type: Distribution.Simple.Program.Db.ProgramDb
    • In the third argument of ‘getInstalledPackages’, namely ‘pc’
      In a stmt of a 'do' block:
        pkgIndex <- getInstalledPackages
                      silent [GlobalPackageDB, UserPackageDB] pc
      In the expression:
        do { pc <- configureAllKnownPrograms
                     silent defaultProgramConfiguration;
             pkgIndex <- getInstalledPackages
                           silent [GlobalPackageDB, UserPackageDB] pc;
             return $ [] `union` allPackages pkgIndex }

src/System/Plugins/Env.hs:335:17: error:
    • Couldn't match expected type ‘IO (PackageIndex PackageConfig)’
                  with actual type ‘ProgramConfiguration -> IO InstalledPackageIndex’
    • Probable cause: ‘getInstalledPackages’ is applied to too few arguments
      In a stmt of a 'do' block:
        pkgIndex <- getInstalledPackages
                      silent [GlobalPackageDB, UserPackageDB, SpecificPackageDB f] pc
      In the expression:
        do { pc <- configureAllKnownPrograms
                     silent defaultProgramConfiguration;
             pkgIndex <- getInstalledPackages
                           silent [GlobalPackageDB, UserPackageDB, ....] pc;
  tests/PackageTests/TemplateHaskell/dynamic/Lib.hs
             return $ allPackages pkgIndex }
      In an equation for ‘readPackageConf’:
          readPackageConf f
            = do { pc <- configureAllKnownPrograms
                           silent defaultProgramConfiguration;
                   pkgIndex <- getInstalledPackages silent [GlobalPackageDB, ....] pc;
                   return $ allPackages pkgIndex }

src/System/Plugins/Env.hs:335:45: error:
    • Couldn't match expected type ‘Compiler’
                  with actual type ‘[PackageDB]’
    • In the second argument of ‘getInstalledPackages’, namely
        ‘[GlobalPackageDB, UserPackageDB, SpecificPackageDB f]’
      In a stmt of a 'do' block:
        pkgIndex <- getInstalledPackages
                      silent [GlobalPackageDB, UserPackageDB, SpecificPackageDB f] pc
      In the expression:
        do { pc <- configureAllKnownPrograms
                     silent defaultProgramConfiguration;
             pkgIndex <- getInstalledPackages
                           silent [GlobalPackageDB, UserPackageDB, ....] pc;
             return $ allPackages pkgIndex }

  tests/PackageTests/TemplateHaskell/profiling/Lib.hs
src/System/Plugins/Env.hs:335:99: error:
    • Couldn't match type ‘Distribution.Simple.Program.Db.ProgramDb’
                     with ‘[PackageDB]’
      Expected type: PackageDBStack
        Actual type: Distribution.Simple.Program.Db.ProgramDb
    • In the third argument of ‘getInstalledPackages’, namely ‘pc’
      In a stmt of a 'do' block:
        pkgIndex <- getInstalledPackages
                      silent [GlobalPackageDB, UserPackageDB, SpecificPackageDB f] pc
      In the expression:
        do { pc <- configureAllKnownPrograms
                     silent defaultProgramConfiguration;
             pkgIndex <- getInstalledPackages
                           silent [GlobalPackageDB, UserPackageDB, ....] pc;
             return $ allPackages pkgIndex }
[ 8 of 12] Compiling System.Plugins.Load ( src/System/Plugins/Load.hs, /tmp/plugins-1.5.5.0/dist-newstyle/build/plugins-1.5.5.0/build/System/Plugins/Load.o )

src/System/Plugins/Load.hs:76:46: error:
    Module ‘Module’ does not export ‘packageKeyString’

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions