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

Improve ci workflows #127

Merged
merged 10 commits into from
Jul 25, 2024
Merged

Improve ci workflows #127

merged 10 commits into from
Jul 25, 2024

Conversation

ilaflott
Copy link
Member

Describe your changes

updates environment.yml to reflect the same dependencies as whats in meta.yaml, plus pip.

adds workflow file create_test_conda_env.yml to use environment.yml to create environment, then uses that environment's python/pip to install fre-cli in that environment, and that environment's pytest is called to run tests.

publish_conda.yml's job name is changed to just publish from build_and_publish, to line up more with the workflow file's name.

Issue ticket number and link (if applicable)

#122, #75

Checklist before requesting a review

  • I ran my code
  • I tried to make my code readable
  • I tried to comment my code
  • N/A I wrote a new test, if applicable
  • N/A I wrote new instructions/documentation, if applicable
  • I ran pytest and inspected it's output
  • N/A I ran pylint and attempted to implement some of it's feedback

ilaflott added 9 commits July 23, 2024 15:01
rename job to "publish"

now reflects scheme of build_conda.yml
fix environment name in python/pytest calls
now reflects meta.yaml
remove specific python version requirement, any python 3.9 or higher is fine. 

use full path to python interpreter for `pip install` call- call pip as python module to make sure fre-cli is installed in the conda env's python... NOT the python-setup step's python..
remove "noarch: python" field from `meta.yaml`

see comment in file
testing adding the build conda environment's bin folder to $GITHUB_PATH. this is how conda is made callable in the pipeline... so maybe this will help the python interpreter link up python-cdo with the cdo installation in the conda env.
add pip as a dependency in environment.yml
ilaflott added a commit to NOAA-GFDL/CatalogBuilder that referenced this pull request Jul 24, 2024
implementing conda env tricks for github ci/cd i figured out here:
NOAA-GFDL/fre-cli#127
add back in noarch field w/ value `python`.

unsure it was ever relevant to `conda env create` anyways.
@ilaflott ilaflott added the enhancement New feature or request label Jul 25, 2024
@ilaflott ilaflott requested a review from kiihne-noaa July 25, 2024 16:37
@ilaflott ilaflott merged commit 7f716a5 into main Jul 25, 2024
3 checks passed
@ilaflott ilaflott deleted the improveCIworkflow branch July 25, 2024 16:39
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

Successfully merging this pull request may close these issues.

2 participants