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 <<loop>>s upon encountering a invalid new-run target. #5467

Closed
AndreasPK opened this issue Jul 29, 2018 · 3 comments
Closed

Cabal <<loop>>s upon encountering a invalid new-run target. #5467

AndreasPK opened this issue Jul 29, 2018 · 3 comments

Comments

@AndreasPK
Copy link
Collaborator

Repro case:

git clone https://github.com/ndmitchell/safe.git

And run new-run with an invalid target.

Andi@Horzube MINGW64 /c/temp/safe
$ cabal new-run exe:algorithms
cabal.exe: Internal error in target matching. It should always be possible to
find a syntax that's sufficiently qualified to give an unambiguous match.
However when matching 'exe:algorithms' we found exe:algorithms
(unknown-component) which does not have an unambiguous syntax. The possible
syntax and the targets they match are as follows:
cabal.exe: <<loop>>

Original example

cabal --store-dir=/home/Andi/.store_all new-run --builddir=d-all -w 'C:\ghc\msys64\home\Andi\trees5\allCalls\inplace\bin\ghc-stage2.exe' '--ghc-options=-fnew-blocklayout -fcfg-weights=callWeight=310' --enable-benchmarks --disable-tests exe:algorithms -- --csv ../benchResults/allCalls.all.algorithms.csv
cabal.exe: Internal error in target matching. It should always be possible to
find a syntax that's sufficiently qualified to give an unambiguous match.
However when matching 'exe:algorithms' we found exe:algorithms
(unknown-component) which does not have an unambiguous syntax. The possible
syntax and the targets they match are as follows:
cabal.exe: <<loop>>

@typedrat
Copy link
Collaborator

typedrat commented Jul 29, 2018

Doesn't loop on macOS.

Doesn't work, either:

~/Development/safe master
❯ cabal new-run exe:algorithms
cabal: Internal error in target matching. It should always be possible to find
a syntax that's sufficiently qualified to give an unambiguous match. However
when matching 'exe:algorithms' we found exe:algorithms (unknown-component)
which does not have an unambiguous syntax. The possible syntax and the targets
they match are as follows:
'exe:algorithms' which matches exe:algorithms (unknown-component),
:pkg:exe:lib:exe:file:algorithms (unknown-file)

@grayjay
Copy link
Collaborator

grayjay commented Jul 30, 2018

I think this is a duplicate of #5081. #5263 fixed the infinite loop, but there is still an internal error.

@grayjay
Copy link
Collaborator

grayjay commented Aug 5, 2018

Duplicate of #5081

@grayjay grayjay marked this as a duplicate of #5081 Aug 5, 2018
@grayjay grayjay closed this as completed Aug 5, 2018
srid added a commit to srid/neuron that referenced this issue May 10, 2020
To play well with obelisk thunks.

cf. haskell/cabal#5467
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants