Skip to content
This repository has been archived by the owner on Aug 16, 2023. It is now read-only.

Give a useful error when no JVMCI version info can be retrieved #10

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

smarr
Copy link
Collaborator

@smarr smarr commented Feb 17, 2021

Hi:

I just ran into an issue when trying to build this repo on MacOS (since there don't seem to be binaries at the moment).

Problem: I cloned with git clone --depth 1, and got a index out of bounds on the JVMCI versions.

The following patch gives a hint how to resolve it, though, it's probably not the best way.
And I don't know how mx usually communicates such errors.

Either suggestions welcome, or if you prefer, treat this simply as a "feature request".

Thanks!

/cc @dougxc

@@ -1463,6 +1463,8 @@ def _jvmci_versions_in_current_branch():
m = jvmci_tag_re.match(decoration)
if m:
versions.append(tuple([int(g) for g in m.groups()]))
if not versions:
raise Exception('No JVMCI versions found. If this is a shallow clone of the git repo, it may need to be unshallowed and load tags with `git fetch --unshallow --tags`')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good except that raise Exception should be mx.abort.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Changed, and force pushed.

@dougxc
Copy link
Member

dougxc commented Feb 17, 2021

since there don't seem to be binaries at the moment

The moment will be here for quite a while as stated in the release notes here.

@smarr smarr force-pushed the shallow-clone-issues branch from ff302e2 to 293ce50 Compare February 17, 2021 11:42
@smarr smarr force-pushed the shallow-clone-issues branch from 293ce50 to f397d31 Compare April 28, 2021 18:21
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants