[GHC] #11558: Using Cabal 1.22 against GHC 8.0 results in terrible errors
#11558: Using Cabal 1.22 against GHC 8.0 results in terrible errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package | Version: 8.0.1-rc1 system | Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: Incorrect Unknown/Multiple | warning at compile-time Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- GHC 8.0 will require Cabal >1.22 due to a variety of interface changes (see #10714, Phab:D1780, https://mail.haskell.org/pipermail/ghc- devs/2016-January/010978.html). Unfortunately things currently blow up late in compilation with a seemingly unrelated error when this requirement isn't met. Namely, we complain about missing interface files for dependencies. For instance, {{{ Text/Parsec/Prim.hs:85:1: error: Bad interface file: /root/.cabal/lib/x86_64-linux- ghc-8.0.0.20160204/mtl-2.2.1-9wMhzcfsAXi7cNtl9n7svO/Control/Monad/Cont/Class.hi Something is amiss; requested module mtl-2.2.1@mtl-2.2.1-1af5dabd2d7abb688f2145aec87badc4:Control.Monad.Cont.Class differs from name found in the interface file mtl_9wMhzcfsAXi7cNtl9n7svO:Control.Monad.Cont.Class }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in terrible errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Description changed by bgamari: @@ -17,0 +17,6 @@ + + = For users afflicted by this = + + The solution here is to install `Cabal` 1.23 or later and a `cabal- + install` linking against it. Currently this requires installing `Cabal` + and `cabal-install` from git. This is most easily done using GHC 7.10. New description: GHC 8.0 will require Cabal >1.22 due to a variety of interface changes (see #10714, Phab:D1780, https://mail.haskell.org/pipermail/ghc- devs/2016-January/010978.html). Unfortunately things currently blow up late in compilation with a seemingly unrelated error when this requirement isn't met. Namely, we complain about missing interface files for dependencies. For instance, {{{ Text/Parsec/Prim.hs:85:1: error: Bad interface file: /root/.cabal/lib/x86_64-linux- ghc-8.0.0.20160204/mtl-2.2.1-9wMhzcfsAXi7cNtl9n7svO/Control/Monad/Cont/Class.hi Something is amiss; requested module mtl-2.2.1@mtl-2.2.1-1af5dabd2d7abb688f2145aec87badc4:Control.Monad.Cont.Class differs from name found in the interface file mtl_9wMhzcfsAXi7cNtl9n7svO:Control.Monad.Cont.Class }}} = For users afflicted by this = The solution here is to install `Cabal` 1.23 or later and a `cabal- install` linking against it. Currently this requires installing `Cabal` and `cabal-install` from git. This is most easily done using GHC 7.10. -- -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:1> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in terrible errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Description changed by bgamari: @@ -18,1 +18,1 @@ - = For users afflicted by this = + = For users seeing this error = New description: GHC 8.0 will require Cabal >1.22 due to a variety of interface changes (see #10714, Phab:D1780, https://mail.haskell.org/pipermail/ghc- devs/2016-January/010978.html). Unfortunately things currently blow up late in compilation with a seemingly unrelated error when this requirement isn't met. Namely, we complain about missing interface files for dependencies. For instance, {{{ Text/Parsec/Prim.hs:85:1: error: Bad interface file: /root/.cabal/lib/x86_64-linux- ghc-8.0.0.20160204/mtl-2.2.1-9wMhzcfsAXi7cNtl9n7svO/Control/Monad/Cont/Class.hi Something is amiss; requested module mtl-2.2.1@mtl-2.2.1-1af5dabd2d7abb688f2145aec87badc4:Control.Monad.Cont.Class differs from name found in the interface file mtl_9wMhzcfsAXi7cNtl9n7svO:Control.Monad.Cont.Class }}} = For users seeing this error = The solution here is to install `Cabal` 1.23 or later and a `cabal- install` linking against it. Currently this requires installing `Cabal` and `cabal-install` from git. This is most easily done using GHC 7.10. -- -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:2> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Description changed by bgamari: @@ -23,0 +23,10 @@ + Finally, you need to clear your package database. + + This can be done with, + {{{ + $ git clone git://github.com/haskell/cabal + $ cd cabal + $ cabal update + $ cabal install Cabal/ cabal-install/ + $ rm -R $HOME/.ghc/*-8.0.0* + }}} New description: GHC 8.0 will require Cabal >1.22 due to a variety of interface changes (see #10714, Phab:D1780, https://mail.haskell.org/pipermail/ghc- devs/2016-January/010978.html). Unfortunately things currently blow up late in compilation with a seemingly unrelated error when this requirement isn't met. Namely, we complain about missing interface files for dependencies. For instance, {{{ Text/Parsec/Prim.hs:85:1: error: Bad interface file: /root/.cabal/lib/x86_64-linux- ghc-8.0.0.20160204/mtl-2.2.1-9wMhzcfsAXi7cNtl9n7svO/Control/Monad/Cont/Class.hi Something is amiss; requested module mtl-2.2.1@mtl-2.2.1-1af5dabd2d7abb688f2145aec87badc4:Control.Monad.Cont.Class differs from name found in the interface file mtl_9wMhzcfsAXi7cNtl9n7svO:Control.Monad.Cont.Class }}} = For users seeing this error = The solution here is to install `Cabal` 1.23 or later and a `cabal- install` linking against it. Currently this requires installing `Cabal` and `cabal-install` from git. This is most easily done using GHC 7.10. Finally, you need to clear your package database. This can be done with, {{{ $ git clone git://github.com/haskell/cabal $ cd cabal $ cabal update $ cabal install Cabal/ cabal-install/ $ rm -R $HOME/.ghc/*-8.0.0* }}} -- -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:4> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Changes (by bgamari): * differential: => Phab:D1892 -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:5> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Description changed by bgamari: @@ -5,2 +5,2 @@ - isn't met. Namely, we complain about missing interface files for - dependencies. For instance, + isn't met. Namely, we complain about bad interface files for dependencies. + For instance, New description: GHC 8.0 will require Cabal >1.22 due to a variety of interface changes (see #10714, Phab:D1780, https://mail.haskell.org/pipermail/ghc- devs/2016-January/010978.html). Unfortunately things currently blow up late in compilation with a seemingly unrelated error when this requirement isn't met. Namely, we complain about bad interface files for dependencies. For instance, {{{ Text/Parsec/Prim.hs:85:1: error: Bad interface file: /root/.cabal/lib/x86_64-linux- ghc-8.0.0.20160204/mtl-2.2.1-9wMhzcfsAXi7cNtl9n7svO/Control/Monad/Cont/Class.hi Something is amiss; requested module mtl-2.2.1@mtl-2.2.1-1af5dabd2d7abb688f2145aec87badc4:Control.Monad.Cont.Class differs from name found in the interface file mtl_9wMhzcfsAXi7cNtl9n7svO:Control.Monad.Cont.Class }}} = For users seeing this error = The solution here is to install `Cabal` 1.23 or later and a `cabal- install` linking against it. Currently this requires installing `Cabal` and `cabal-install` from git. This is most easily done using GHC 7.10. Finally, you need to clear your package database. This can be done with, {{{ $ git clone git://github.com/haskell/cabal $ cd cabal $ cabal update $ cabal install Cabal/ cabal-install/ $ rm -R $HOME/.ghc/*-8.0.0* }}} -- -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:6> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Changes (by asr): * cc: asr (added) -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:7> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Comment (by Ben Gamari <ben@…>): In [changeset:"d80caca10d7c2fa1c9ee8ef6bcafac365d02ff3d/ghc" d80caca/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="d80caca10d7c2fa1c9ee8ef6bcafac365d02ff3d" Error early when you register with too old a version of Cabal. On the GHC 8.0 RCs, multiple users reported a very strange error whereby GHC would complain that the symbols names recorded in interface files did not match the expected name. The reason for this is that they were using an old version of Cabal which chose symbol names differently from the installed package ID ('id' field) which the package was to be installed with; GHC 8.0 now mandates that these coincides. This change adds a test to ghc-pkg to make sure that 'id' and 'key' (which is how Cabal previously reported what the symbol name was supposed to be) match; if they don't match or key is missing, we assume that the Cabal was too old. Bikeshed points: - Should we offer more information about how to upgrade Cabal correctly (i.e. specify a version?) - Should we allow for a missing 'key'? If we allow for 'key' to be missing, we lose the ability to detect Cabal from GHC 7.8 or earlier being used. If we require it to be specified, then it will not be possible for Cabal to deprecate the (unused) field and remove it without having BC for 8.0. Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: austin, bgamari, hvr Reviewed By: hvr Subscribers: bergmark, thomie Differential Revision: https://phabricator.haskell.org/D1892 GHC Trac Issues: #11558 }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:8> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Comment (by bgamari): GHC should now produce an error resembling, {{{ PROG: installed package info from too old version of Cabal (key field does not match id field) }}} when invoked by an older Cabal. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:9> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: merge Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * status: new => merge -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:10> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: closed Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Changes (by bgamari): * status: merge => closed * resolution: => fixed Comment: Thanks thomie! This was merged to `ghc-8.0` as 7fc4300200a9e287d693e2df936e0fc9549de0a3. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:11> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#11558: Using Cabal 1.22 against GHC 8.0 results in unhelpful errors -------------------------------------+------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: closed Priority: highest | Milestone: 8.0.1 Component: Package system | Version: 8.0.1-rc1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Incorrect | Unknown/Multiple warning at compile-time | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D1892 Wiki Page: | -------------------------------------+------------------------------------- Comment (by Ben Gamari <ben@…>): In [changeset:"1f3d953e97f3c107f76d992bd087ed91f72d24e1/ghc" 1f3d953/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="1f3d953e97f3c107f76d992bd087ed91f72d24e1" users-guide: Mention #11558 in release notes }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11558#comment:12> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
participants (1)
-
GHC