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

Parse-uuid typed wrongly #2187

Closed
dbunin opened this issue Sep 19, 2023 · 1 comment
Closed

Parse-uuid typed wrongly #2187

dbunin opened this issue Sep 19, 2023 · 1 comment

Comments

@dbunin
Copy link
Contributor

dbunin commented Sep 19, 2023

problem

Given

(parse-uuid 1)

You see a warning saying that parse-uuid should be either nil or string.

expected behavior

Given that

; eval (root-form): (parse-uuid nil)
; (err) Execution error (NullPointerException) at java.util.UUID/fromString (UUID.java:237).
; (err) Cannot invoke "String.length()" because "name" is null

I would expect the parse-uuid not to be nilable but just a string. So maybe something like:

parse-uuid {1 {:args (:string)}}

Open to making a PR

@borkdude
Copy link
Member

Sure, PR welcome!

dbunin pushed a commit to dbunin/clj-kondo that referenced this issue Sep 19, 2023
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