Skip to content

Conversation

@marcinz
Copy link
Collaborator

@marcinz marcinz commented Apr 7, 2022

Files copied from the utils repository.

@marcinz marcinz requested a review from m3vaz April 7, 2022 21:58
# vNN.NN.NN
# vNN.NN.NN.dev
{% elif 'dev' in environ.get('GIT_DESCRIBE_TAG', '') %}
{% set version = environ.get('GIT_DESCRIBE_TAG', '') ~ environ.get('GIT_DESCRIBE_NUMBER', '') %}
Copy link
Contributor

Choose a reason for hiding this comment

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

Remember to strip the preceding "v" from the tag so that the version number is valid

{% elif 'dev' in environ.get('GIT_DESCRIBE_TAG', '') %}
{% set version = (environ.get('GIT_DESCRIBE_TAG', '') ~ environ.get('GIT_DESCRIBE_NUMBER', '')).lstrip('v') %}
{% else %}
{% set version = environ.get('GIT_DESCRIBE_TAG', '').lstrip('v') %}
Copy link
Contributor

Choose a reason for hiding this comment

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

Either this conditional should have a default statement to handle if it's not running under a git repo, or the environ.get() in the fallback should have a default value.

Copy link
Contributor

Choose a reason for hiding this comment

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

This also applies for PR's which are git repos, but do not have tags.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Hmm, I think that if we are running in one of these situations, we should provide package version through package_version. I don't think that there is really a good default. Let me know what do you think.

Copy link
Contributor

Choose a reason for hiding this comment

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

hrm, agreed. We could just set it to 0.0.0?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We could do that, but I would personally prefer an error message that would remind me to set package_version. WDYT? Unfortunately, for cunumeric we don't have a choice since we need a default to avoid errors in the initial pass where the environment vars are not defined yet. That's why we need a "fake" default there, but it also can prevent error messages.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I tried to remove the defaults, but that does not work:

TypeError: argument of type 'NoneType' is not iterable

So it seems that without the default, the output of environ.get ends up being None in the first pass. So we do have to keep the default, even if it is simply ''. I will elevate the default into a separate variable.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good. Other than that LGTM.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Should be fixed. Take a look and confirm if ready for merging.

@marcinz marcinz changed the title [WIP] Adding conda build recipe files Adding conda build recipe files Apr 28, 2022
@marcinz marcinz merged commit cd4ca09 into nv-legate:branch-22.05 Apr 28, 2022
elliottslaughter pushed a commit to elliottslaughter/legate that referenced this pull request Mar 26, 2025
* Update the default test binary name

* Make exception handling eager and put back Python exception support

* Custom exception handler to filter legate::TaskException

* Address review comment

* Address review comments

* Support multiple exception classes

* Expose the interna list of exceptions as a tuple

* Re-raise index errors as runtime errors

* Should have retrieved the index class outside the try block
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

Successfully merging this pull request may close these issues.

2 participants