bug-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#52152: Haskell Hackage importer can create dependency cycles


From: zimoun
Subject: bug#52152: Haskell Hackage importer can create dependency cycles
Date: Tue, 08 Mar 2022 11:04:52 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)

Hi,

On dim., 28 nov. 2021 at 02:50, John Kehayias <john.kehayias@protonmail.com> 
wrote:

> While working on importing a bunch of Haskell packages, I came across
> a cycle created by the importer (twice actually, but forgot the other
> one). Perhaps this is from the metadata from Hackage, as it doesn't
> create the cycle when importing from Stackage. Here are the outputs:

The difference comes from upstream:

 - hackage fetches from
   https://hackage.haskell.org/package/OneTuple/OneTuple-0.3.1.tar.gz
 - stackage fetches from
   https://hackage.haskell.org/package/OneTuple/OneTuple-0.2.2.1.tar.gz

Therefore, it is not the same version.  Let compare:

--8<---------------cut here---------------start------------->8---
$ guix import hackage OneTuple

Starting download of /tmp/guix-file.7VmwVe
>From https://hackage.haskell.org/package/OneTuple/OneTuple-0.3.1.tar.gz...
 ….3.1.tar.gz  5KiB                   3.8MiB/s 00:00 [##################] 100.0%
(package
  (name "ghc-onetuple")
  (version "0.3.1")
[...]
        (base32 "1vry21z449ph9k61l5zm7mfmdwkwszxqdlawlhvwrd1gsn13d1cq"))))
[...]

  (inputs (list ghc-hashable ghc-base-orphans))
  (native-inputs (list ghc-onetuple ghc-onetuple))
  (arguments
    `(#:cabal-revision
      ("2" "0gk0656igxl0km9kgh8v7b5vq74kla59ka9hvpzq57njr6bc0j58")))
[...]

  (description
    "This package is a compatibility package for a singleton data type . > data 
Solo
a = Solo a .  Note: it's not a @newtype@ . @Solo@ is available in @base-4.16@
(GHC-9.2).")

$ guix import stackage OneTuple

Starting download of /tmp/guix-file.WpQBJV
>From https://hackage.haskell.org/package/OneTuple/OneTuple-0.2.2.1.tar.gz...
 …2.2.1.tar.gz                                10.9MiB/s 00:00 | 3KiB transferred
(package
  (name "ghc-onetuple")
  (version "0.2.2.1")
[...]
        (base32 "15ls6kkf953288q7rsc49bvw467ll4nq28hvsgbaazdn7hf75ixc"))))
[...]

  (arguments
    `(#:cabal-revision
      ("1" "03mygfz7lv6h0i30bq2grvmahbg9j7a36mc0wls2nr81dv9p19s7")))
[...]

  (description
    "This package provides a singleton tuple data type . > data OneTuple a = 
OneTuple
a .  Note: it's not a @newtype@")
--8<---------------cut here---------------end--------------->8---


And the "cycle" seems expected from OneTuple.cabal:

--8<---------------cut here---------------start------------->8---
$ cat OneTuple-0.3.1/OneTuple.cabal
cabal-version:      >=1.10

[...]

test-suite th
  type:             exitcode-stdio-1.0
  default-language: Haskell98
  hs-source-dirs:   test
  main-is:          th.hs
  build-depends:
      base
    , OneTuple
    , template-haskell
--8<---------------cut here---------------end--------------->8---


Well, for what they are worth, based on this remark, two points:

 1. I do not know what could be done on Guix side.  An idea?
 2. Usually, it is recommended to follow LTS and so Stackage.


Cheers,
simon





reply via email to

[Prev in Thread] Current Thread [Next in Thread]