-
Notifications
You must be signed in to change notification settings - Fork 9
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
Made test for versioning system. #387
Merged
MicahGale
merged 11 commits into
develop
from
386-error-with-versioning-without-setuptools-scm-installed
Apr 15, 2024
Merged
Made test for versioning system. #387
MicahGale
merged 11 commits into
develop
from
386-error-with-versioning-without-setuptools-scm-installed
Apr 15, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MicahGale
added
bugs
A deviation from expected behavior that does not reach the level of being reportable as an "Error".
CI/CD
critical
An issue that seriously limits user adoption or hampers current use.
labels
Mar 9, 2024
Pull Request Test Coverage Report for Build 8211674948Details
💛 - Coveralls |
* fixed test reporting to still occur if tests failed * ensured build packages are installed for testing
MicahGale
force-pushed
the
386-error-with-versioning-without-setuptools-scm-installed
branch
from
March 9, 2024 03:21
563222c
to
7a54524
Compare
This reverts commit d92dd64. *This was done to avoid redundant documentation builds.
tjlaboss
requested changes
Apr 15, 2024
tjlaboss
approved these changes
Apr 15, 2024
MicahGale
deleted the
386-error-with-versioning-without-setuptools-scm-installed
branch
April 15, 2024 22:26
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This was meant to be a bug fix for #386. However, since this bug I have been unable to replicate the error in CI, or even on the machine had initially had the error.
Nonetheless I saw some opportunities for making this version system more robust.
Background on version system.
How versions were determined changed with #336.
At this point we moved to setuptools-scm, and the version is never hard coded into a git tracked file.
Rather the tool uses git tag and git commits to determine the current/next version.
This is expensive to do so it is only done when
python -m build
is ran.At this point the version number is calculated and saved to
montepy/_version.py
.It is also possible to figure out the version number by importing
setuptools_scm
.To determine the version montepy does the following:
_version.py
and use that.import setuptools_scm
Undefined
.Improvements
tests/test_version.py
. This test is rather jank because it has intentionally unloadsetuptools_scm
andmontepy
so it can force it re-import multiple times.LookupError
so if setuptools_scm fails for some reason the user will getUndefined
.Fixes #386
Checklist
I have made corresponding changes to the documentation (if applicable)