[bug#38408,v9,5/8] guix: import: crate: deduplicate dependencies
diff mbox series

Message ID 24fe155b78d5df8046e5fa1953fb5e07b7532f75.1580817140.git.mjbecze@riseup.net
State New
Headers show
Series
  • recursive semver crate importer!
Related show

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job

Commit Message

Martin Becze Feb. 4, 2020, 12:18 p.m. UTC
* guix/import/crate.scm (crate-version-dependencies): deduplicate dependencies
---
 guix/import/crate.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch
diff mbox series

diff --git a/guix/import/crate.scm b/guix/import/crate.scm
index 9128314370..a82e5e877a 100644
--- a/guix/import/crate.scm
+++ b/guix/import/crate.scm
@@ -115,7 +115,7 @@  record or #f if it was not found."
          (url  (string-append (%crate-base-url) path)))
     (match (assoc-ref (or (json-fetch url) '()) "dependencies")
       ((? vector? vector)
-       (map json->crate-dependency (vector->list vector)))
+       (delete-duplicates (map json->crate-dependency (vector->list vector))))
       (_
        '()))))