mx icon indicating copy to clipboard operation
mx copied to clipboard

Provide def release_version(self) for BinarySuite

Open olpaw opened this issue 8 years ago • 7 comments

The call to _updateGraalPropertiesFile() in mx.graal-core/mx_graal_8.py line 73 will fail with jvmci imported as binary suite because there is no definition of def release_version(self) for BinarySuite. A proper definition needs to be added.

olpaw avatar Mar 08 '16 16:03 olpaw

Have you seen a failure? If so, under what conditions?

This should not fail as this code is only called when building the JVMCI JDK and when JVMCI is a binary suite this step is not necessary.

dougxc avatar Mar 09 '16 21:03 dougxc

Have you seen a failure? If so, under what conditions?

Yes. We have a project that transitively depends on jvmci that builds (and uses) jvm-product-server-linux-amd64. If I binary deploy all transitive dependencies and then use them via MX_BINARY_SUITES='' mx build it will work fine except for binary artifact for jvm-product-server-linux-amd64. There mx tries to call _updateGraalPropertiesFile() and fails in line 73 because now jvm-product-server-linux-amd64 comes from a binary suite (which does not have def release_version(self) defined)

But when I define a dummy implementation for release_version(self) in BinarySuite everything works a expected.

olpaw avatar Mar 10 '16 12:03 olpaw

When you execute MX_BINARY_SUITES='' mx build isn't the jvmci source suite resolved (and downloaded if necessary) bypassing the jvmci binary suite altogether?

dougxc avatar Mar 10 '16 12:03 dougxc

I will send you a console log via email.

olpaw avatar Mar 10 '16 12:03 olpaw

Sorry, I got confused and interpreted MX_BINARY_SUITES=‘’ to mean don’t use binary suites. Also, I didn’t see any failure with graal-core as the primary suite. Obviously, it has to be an imported binary suite to see the problem!

What does your dummy implementation look like? Worth creating a PR from it?

dougxc avatar Mar 10 '16 17:03 dougxc

Worth creating a PR from it?

I don't think so:

def release_version(self):
    return self.version()

olpaw avatar Mar 10 '16 17:03 olpaw

That seems reasonable to me - I don't know where else could we get version info from a binary suite?

dougxc avatar Mar 10 '16 19:03 dougxc