guix import hackage fails on key:value

  • Open
  • quality assurance status badge
Details
2 participants
  • Robert Vollmert
  • Simon Tournier
Owner
unassigned
Submitted by
Robert Vollmert
Severity
normal
R
R
Robert Vollmert wrote on 16 Jul 2019 16:02
(address . bug-guix@gnu.org)
2DCCAF13-6983-40AF-AD15-27A6222902CB@vllmrt.net
Apparently, it’s valid for a cabal file to have key-value pairs
without a space, e.g.

benchmark benchmarks
type: exitcode-stdio-1.0
main-is:Speed.hs
hs-source-dirs:test
default-language: Haskell2010
build-depends:
base < 5,
criterion,
diagrams-core,
diagrams-lib


guix import hackage breaks on this:

$ guix import hackage diagrams-lib
Importing `diagrams-lib` from hackage
Syntax error: unexpected token : main-is:Speed.hs (at line 175, column 2)
Syntax error: unexpected end of input
guix import: error: failed to download cabal file for package 'diagrams-lib'
S
S
Simon Tournier wrote on 3 Apr 2023 18:51
(name . Robert Vollmert)(address . rob@vllmrt.net)(address . 36690@debbugs.gnu.org)
87y1n8ewob.fsf@gmail.com
Hi,

This old bug#36690 [1] is about an error of the Cabal parser.


On mar., 16 juil. 2019 at 16:02, Robert Vollmert <rob@vllmrt.net> wrote:

Toggle quote (24 lines)
> Apparently, it’s valid for a cabal file to have key-value pairs
> without a space, e.g.
>
> benchmark benchmarks
> type: exitcode-stdio-1.0
> main-is:Speed.hs
> hs-source-dirs:test
> default-language: Haskell2010
> build-depends:
> base < 5,
> criterion,
> diagrams-core,
> diagrams-lib
>
> from http://hackage.haskell.org/package/diagrams-lib-1.4.2.3/revision/2.cabal
>
> guix import hackage breaks on this:
>
> $ guix import hackage diagrams-lib
> Importing `diagrams-lib` from hackage
> Syntax error: unexpected token : main-is:Speed.hs (at line 175, column 2)
> Syntax error: unexpected end of input
> guix import: error: failed to download cabal file for package 'diagrams-lib'

Now, “guix import hackage diagrams-lib” passes. Well, I do not know if
the parser had been improved or if the Cabal file had been changed.

Without an example for testing the bug, I am in favor to close this
report. WDYT?

Cheers,
simon
?