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

packet pack fails if paket.references contains an unknown reference #1514

Closed
michael-baker opened this issue Mar 14, 2016 · 2 comments
Closed

Comments

@michael-baker
Copy link

Very minor issue.

If you create a solution with two projects. Project A and B.
Project B depends on Project A.

If you attempt to run

paket.exe pack buildconfig "Debug" buildplatform "AnyCPU" output ..\..\Bin

against Project B where Project B has a paket.references defined as

nuget ProjectA

Then the packaging process will fail

Paket version 2.52.3.0
Paket failed with:
The given key was not present in the dictionary.

This is because the solution level paket.dependencies doesn't contain an entry for ProjectA.
It would be nice to have a friendly error message rather than the generic key not found exception in this case. However I do accept this is user error :)

zip which reproduces the issue is attached.

PaketDemo.zip

@forki
Copy link
Member

forki commented Mar 14, 2016

nuget ProjectA is actually not correct syntax in paket.references.
It would be correct to inly write ProjectA - but I see this as a common mistake and made the parser accept this.

So now you will see the correct error message.

@forki forki closed this as completed in 4452fac Mar 14, 2016
@michael-baker
Copy link
Author

True, I released my error with including the "nuget" prefix text shortly after posting.
Cool! Thanks for the tweak 👍

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