Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 785820

Summary: dev-java/java-config: depend-java-query - if invalid jdk specification is used (virtual/jdk:*) then the error should say that version must be specified
Product: Gentoo Linux Reporter: Daniel Dawson <danielcdawson>
Component: Current packagesAssignee: Java team <java>
Status: CONFIRMED ---    
Severity: normal CC: candrews, flow, fordfrog, neil, sam
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=785436
Whiteboard:
Package list:
Runtime testing required: ---

Description Daniel Dawson 2021-04-26 12:20:25 UTC
A dependency string such as "virtual/jdk:*" (see e.g. bug 785436) causes an error message from depend-java-query:

$ depend-java-query --get-vm 'virtual/jdk:*'
!!! ERROR: could not convert string to float: '*'

I don't know whether it's okay to have a wildcard for this purpose, but if not, it should at least give a better error message than that.
Comment 1 Miroslav Ć ulc gentoo-dev 2021-04-28 17:58:44 UTC
the problem is not the wildcard itself but the fact that there is no version specified. this is not valid and not supported. it should be something like <=virtual/jdk-1.8:*". it sure might detect this kind of invalid version specification and report that appropriately.