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

Defining malformed scopes for dependencies produce confusing error messages #2685

Open
esuomi opened this issue May 27, 2020 · 1 comment
Open

Comments

@esuomi
Copy link

esuomi commented May 27, 2020

When defining scopes for dependencies in malformed way the produced error messages are not very helpful, at least for newbies. Examples:

[some/dep "1.2.3" :provided]
;=> "Provided artifact is missing a version: [some/dep nil "1.2.3" :provided]"
[some/dep "1.2.3" :scope :provided]
;=> "clojure.lang.Keyword cannot be cast to java.lang.String"

The correct form for defining the scope of course is

[some/dep "1.2.3" :scope "provided"]

The error message should probably either describe the full form of the dependency vector or potentially try to autodetect what the user is trying to do and suggest a fix based on that, whichever makes more sense.

@technomancy
Copy link
Owner

Sure; I'd take a patch to improve that error message.

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

2 participants