Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Garbled output of Top-sorted list of all dependencies (macOS) #78

Closed
andreasabel opened this issue Nov 13, 2021 · 2 comments
Closed

Garbled output of Top-sorted list of all dependencies (macOS) #78

andreasabel opened this issue Nov 13, 2021 · 2 comments

Comments

@andreasabel
Copy link
Member

I would like to use cabal-plan to generate a extra-deps in a stack.yaml file automatically, using the list of all dependencies under Top-sorted:

$ cabal-plan
...
Tree
~~~~

fix-whitespace-0.0.8
 [fix-whitespace-0.0.8:exe:"fix-whitespace"]
 ├─ base-4.16.0.0
...
Top-sorted
~~~~~~~~~~

UnitId "rts-1.0.2"
UnitId "ghc-prim-0.8.0"
UnitId "ghc-bignum-1.2"
UnitId "base-4.16.0.0"
UnitId "ghc-boot-th-9.2.1"
UnitId "array-0.5.4.0"
UnitId "deepseq-1.4.6.0"
UnitId "pretty-1.1.3.6"
UnitId "template-haskell-2.18.0.0"
UnitId "OnTpl-0.3.1-67092f35"
UnitId "stm-2.5.0.0"
UnitId "transformers-0.5.6.2"
UnitId "SttVr-1.2.2-18f5a458"
UnitId "bs-rphns-0.8.6-c90f3464"
UnitId "containers-0.6.5.1"
UnitId "tggd-0.8.6.1-23ebf165"
UnitId "dstrbtv-0.6.2.1-30d16c25"
UnitId "ndxd-trvrsbl-0.1.2-ea4c6a7b"
UnitId "trnsfrmrs-cmpt-0.7.1-11824f21"
UnitId "cmnd-5.0.8-f7847f23"
UnitId "th-bstrctn-0.4.3.0-331f74f3"
UnitId "bfnctrs-5.5.11-dfa607d8"
UnitId "bytestring-0.11.1.0"
UnitId "binary-0.8.9.0"
UnitId "time-1.11.1.1"
UnitId "unix-2.7.2.2"
UnitId "bs-cmpt-0.12.1-5d888bd5"
UnitId "bs-cmpt-bttrs-0.12.1-e85719a6"
UnitId "clck-0.8.2-49217a3c"
UnitId "filepath-1.4.2.1"
UnitId "directory-1.3.6.2"
UnitId "mtl-2.2.2"
UnitId "exceptions-0.10.4"
UnitId "text-1.2.5.0"
UnitId "hshbl-1.4.0.0-31d6e39d"
UnitId "nrdrd-cntnrs-0.2.15.0-08f1410e"
UnitId "splt-0.2.3.4-8fd6a6a9"
UnitId "prmtv-0.7.3.0-2eb0ce6a"
UnitId "vctr-0.12.3.1-ac51a413"
UnitId "vctr-lgrthms-0.8.0.4-119c737a"
UnitId "mn-trvrsbl-1.0.15.3-e9676e28"
UnitId "nlft-cr-0.2.0.1-9bdb8a14"
UnitId "rsrct-1.2.4.3-7795e470"
UnitId "cndt-1.3.4.2-cec99d9e"
UnitId "cntrvrnt-1.5.5-73ae429b"
UnitId "spltmx-0.1.0.4-d627621d"
UnitId "rndm-1.2.1-8175b129"
UnitId "d-typs-1.0.5-dd6298b2"
UnitId "dlst-1.0-db9e945a"
UnitId "dt-fx-0.3.2-cbb975f2"
UnitId "process-1.6.13.2"
UnitId "xtr-1.7.10-74cdb974"
UnitId "flpttrn-0.1.2-3d850001"
UnitId "lbyml-0.1.2-5d834e71"
UnitId "ntgr-lgrthms-1.0.3.1-38e2483a"
UnitId "scntfc-0.3.7.0-059148ff"
UnitId "ndxd-trvrsbl-nstncs-0.1.1-4659c8bc"
UnitId "smgrpds-5.3.6-bba6bb6b"
UnitId "ssc-1.0.2-267c64ef"
UnitId "ths-1.1.1.1-cb98139d"
UnitId "smlgn-1.2.0.1-0b87c17e"
UnitId "strct-0.4.0.1-cbf6f9b8"
UnitId "tm-cmpt-1.9.6.1-1c51abdb"
UnitId "ttprsc-0.14.2-0139c7c8"
UnitId "txt-shrt-0.1.4-885370e8"
UnitId "wthrbl-0.4.2-afa8ff09"
UnitId "sn-2.0.2.0-1cf37732"
UnitId "yml-0.11.7.0-55eff270"
UnitId "fix-whitespace-0.0.8-inplace-fix-whitespace"

Direct deps
~~~~~~~~~~~

PkgId (PkgName "fix-whitespace") (Ver [0,0,8])
CompNameExe "fix-whitespace"
  base-4.16.0.0
  directory-1.3.6.2
  filepath-1.4.2.1
  filepattern-0.1.2
...

Unfortunately, the list of all packages gives garbled names (on macOS) for all non-core packages, due to

A better access to the package names and version is provided by

$ cabal-plan fingerprint 
98853682d52fb4cc37a45cd186fbd77cf2565d3df5171acc4cf026427e103eef G OneTuple-0.3.1
5e4b39da395656a59827b0280508aafdc70335798b50e5d6fd52596026251825 G StateVar-1.2.2
d5ca55dd7fab55d3a0e166f04d14d1361696077b664b58b42e2523a160208037 G aeson-2.0.2.0
________________________________________________________________ B array-0.5.4.0
...

Thus, this issue is maybe more a wart than a real problem and can wait for an upstream fix.

@phadej
Copy link
Collaborator

phadej commented Nov 13, 2021

Use cabal-plan topo


Thus, this issue is maybe more a wart than a real problem and can wait for an upstream fix.

Is this issue actionable then? UnitIds are unit-ids, they are arbitrary strings.

@andreasabel
Copy link
Member Author

Use cabal-plan topo

Thanks!

Is this issue actionable then? UnitIds are unit-ids, they are arbitrary strings.

I guess not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants