Skip to content
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

FIX: --version output in containers #493

Merged
merged 2 commits into from
Jan 14, 2023
Merged

Conversation

kaczmarj
Copy link
Collaborator

Prior to this PR, the --version output from containers would include dirty, indicating uncommitted changes. This was because /docs was not copied into the docker images.

Before this commit, the version output looks like this:

$ docker run --rm repronim/neurodocker:0.9.1 --version
neurodocker version 0.9.1+0.gad2f3a6.dirty

And after this commit, the version is:

$ docker run --rm neurodocker --version                                                                                           
neurodocker version 0.9.1+8.gf7f2aaf

Note the lack of .dirty in the output.

By excluding /docs from the Docker images, we were modifying the state of the git repository, and git status was reporting uncommitted changes. This caused the command neurodocker --version to show that there were uncommitted changes (by including the dirty suffix in the version). We do not want users to be under the impression that the version includes uncommitted changes. Indeed, kaczmarj excluded /docs from the docker builds as a premature optimization... it turns out that they only consume 136 kb, which is negligible.

By excluding `/docs` from the Docker images, we were modifying the state
of the git repository, and `git status` was reporting uncommitted
changes. This caused the command `neurodocker --version` to show that
there were uncommitted changes (by including the `dirty` suffix in the
version). We do not want users to be under the impression that the
version includes uncommitted changes. Indeed, kaczmarj excluded `/docs`
from the docker builds as a premature optimization... it turns out that
they only consume 136 kb, which is negligible.
@codecov
Copy link

codecov bot commented Jan 14, 2023

Codecov Report

Base: 83.74% // Head: 83.74% // No change to project coverage 👍

Coverage data is based on head (f79ef3e) compared to base (218697a).
Patch has no changes to coverable lines.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #493   +/-   ##
=======================================
  Coverage   83.74%   83.74%           
=======================================
  Files          11       11           
  Lines        1015     1015           
=======================================
  Hits          850      850           
  Misses        165      165           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@satra satra merged commit d62b72f into master Jan 14, 2023
@kaczmarj kaczmarj deleted the fix/fix-version-in-containers branch January 19, 2023 01:17
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.

None yet

2 participants