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

GitHub-Actions: Add a simple test that checks if all packages specified in the .yml file were also installed in the conda environment #54

Open
JohannesWiesner opened this issue May 16, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@JohannesWiesner
Copy link
Owner

First run tcy.py to create an input .yml file, create an environment from that file and then try to import all modules that appear in the input .yml file

This could be possibly done with: python -c "import nilearn nipype ...."

See: https://github.com/mamba-org/setup-micromamba#usage

@JohannesWiesner JohannesWiesner added the enhancement New feature or request label Jun 21, 2023
@JohannesWiesner
Copy link
Owner Author

Another way to test if all packages that were specified in .tsv file were installed, is to run micromamba list. This list has to be reduced to only packages that can be found in .tsv file (possibily using grep?). Then export this to .csv and use pandas to check that all packages that appear in .tsv file also appear in micromamba environment.

@JohannesWiesner
Copy link
Owner Author

But see this issue, we have to use the workaround with

conda list -p "${MAMBA_ROOT_PREFIX}/envs/${{ matrix.os }}" --explicit > ./environments/${{ matrix.os }}_solved.txt

Only this gets us a list with conda + pip packages. This command is already used so we don't need to execute it another time. But we somehow have to bring it into a format that allows us to compare it to the input .yml file.

@JohannesWiesner JohannesWiesner changed the title GitHub-Actions: Add a simple test that opens python and imports all included modules GitHub-Actions: Add a simple test that checks if all packages specified in the .yml file were also installed in the conda environment Oct 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant