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

cabal can't find modules from private package - error message is unhelpful #8575

Open
cheater opened this issue Nov 7, 2022 · 1 comment
Labels
attention: pr-welcome re: config-file Concerning the cabal configuration file and the `--config-file` option re: error-message Concerning error messages delivered to the user

Comments

@cheater
Copy link

cheater commented Nov 7, 2022

Describe the bug
I have a test suite which imports modules from a private library. Those modules are not found, even though the private library is added as build-depends.

The cabal file is here: foo.cabal.txt
(I had to add .txt so GitHub would take it)

Expected behavior

after a bunch of time spent experimenting, this seems to be alleviated by doing build-depends: foo:foo-test-lib. The error message should be more helpful. If I am in a package quux that contains baz as a private library, and I do build-depends: baz, then the error message should tell me to instead do build-depends: quux:baz. As in, "did you mean ...?" etc. Otherwise, the behavior is perceived as a bug - no one on IRC knew that the prefix (quux:) should be done, for example. Please include the actual name of the library or package in the error message.

System information

cabal-install version 3.8.1.0
compiled using version 3.8.1.0 of the Cabal library
The Glorious Glasgow Haskell Compilation System, version 9.0.2

Additional context
Add any other context about the problem here.

@Mikolaj
Copy link
Member

Mikolaj commented Nov 7, 2022

PR welcome. Related: #8573

@Mikolaj Mikolaj added attention: pr-welcome re: config-file Concerning the cabal configuration file and the `--config-file` option re: error-message Concerning error messages delivered to the user labels Nov 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
attention: pr-welcome re: config-file Concerning the cabal configuration file and the `--config-file` option re: error-message Concerning error messages delivered to the user
Projects
None yet
Development

No branches or pull requests

2 participants