Skip to content

Commit

Permalink
Pin micromamba 1.5.10-0
Browse files Browse the repository at this point in the history
  • Loading branch information
Yoshanuikabundi committed Oct 1, 2024
1 parent b3273e9 commit 028e4ff
Show file tree
Hide file tree
Showing 5 changed files with 109 additions and 90 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ jobs:
environment-file: devtools/conda-envs/${{ env.ENVFILE }}.yaml
create-args: >-
python=${{ matrix.python-version }}
# default - will pull down 2.0 which we don't want!
# micromamba-version: latest
# pin to latest 1.x release
micromamba-version: "1.5.10-0"

- name: Make oe_license.txt file from GH org secret "OE_LICENSE"
env:
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/beta_rc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ jobs:
- conda-forge
create-args: >-
python=${{ matrix.python-version }}
# default - will pull down 2.0 which we don't want!
# micromamba-version: latest
# pin to latest 1.x release
micromamba-version: "1.5.10-0"

- name: Make oe_license.txt file from GH org secret "OE_LICENSE"
env:
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ jobs:
environment-file: devtools/conda-envs/conda_oe.yaml
create-args: >-
python=${{ matrix.python-version }}
# default - will pull down 2.0 which we don't want!
# micromamba-version: latest
# pin to latest 1.x release
micromamba-version: "1.5.10-0"

- name: Additional info about the build
run: |
Expand Down Expand Up @@ -126,4 +130,4 @@ jobs:
- name: Run example notebooks
run: |
python -m pytest -r fE -v -x --tb=short --nbval-lax --ignore=examples/deprecated examples
python -m pytest -r fE -v -x --tb=short --nbval-lax --ignore=examples/deprecated examples
4 changes: 4 additions & 0 deletions .github/workflows/examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ jobs:
environment-file: devtools/conda-envs/${{env.ENVFILE}}-examples.yaml
create-args: >-
python=${{ matrix.python-version }}
# default - will pull down 2.0 which we don't want!
# micromamba-version: latest
# pin to latest 1.x release
micromamba-version: "1.5.10-0"

- name: Additional info about the build
run: |
Expand Down
181 changes: 92 additions & 89 deletions .github/workflows/installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,92 +20,95 @@ jobs:
PYVER: ${{ matrix.python-version }}

steps:
- uses: actions/checkout@v4

- name: Install conda environment
uses: mamba-org/setup-micromamba@v1
with:
environment-file: devtools/conda-envs/installer.yaml
create-args: >-
python=${{ matrix.python-version }}
- name: Additional info about the build
shell: bash
run: |
uname -a
df -h
ulimit -a
- name: Environment Information
shell: bash -l {0}
run: |
conda info
conda list
- name: Prepare and run the constructor
shell: bash -l {0}
run: |
#cd ..
# Find the tag of the last release (excluding RCs)
# TODO: Make this a variable that can be passed through from trigger and/or allow RC
export LATEST_TAG=$(git ls-remote --tags https://github.com/openforcefield/openff-toolkit.git | cut -f2 | grep -E "([0-9]+)\.([0-9]+)\.([0-9]+)$" | sort --version-sort | tail -1 | sed 's/refs\/tags\///')
echo $LATEST_TAG
git clone https://github.com/openforcefield/toolkit-installer-constructor
cd toolkit-installer-constructor
python ../devtools/scripts/build_cookiecutter_json.py $LATEST_TAG $PYVER $CI_OS
cp new_cookiecutter.json cookiecutter/cookiecutter.json
cat new_cookiecutter.json
python run.py
pwd
ls
ls build
- name: Upload installer as artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}_py${{ matrix.python-version }}.sh
path: toolkit-installer-constructor/build/openff-toolkit*/openff-toolkit*.sh

- name: Install from installer
shell: bash -l {0}
run: |
#cd ..
pwd
ls
ls toolkit-installer-constructor
ls toolkit-installer-constructor/build
ls toolkit-installer-constructor/build/openff-toolkit-*/
mkdir scratch
cd scratch
echo $HOME/constructor_install/ | bash ../toolkit-installer-constructor/build/openff-toolkit-*/openff-toolkit-*.sh
conda activate $HOME/constructor_install/
conda info
conda list
export FOUND_VER=$(python -c "import openff.toolkit; print(openff.toolkit.__version__)")
export LATEST_TAG=$(git ls-remote --tags https://github.com/openforcefield/openff-toolkit.git | cut -f2 | grep -v "rc" | tail -1 | sed 's/refs\/tags\///')
echo $LATEST_TAG
echo $FOUND_VER
if [[ $LATEST_TAG != $FOUND_VER ]];
then echo "Version mismatch"
exit 1
fi
PYTEST_ARGS=" -r fE --tb=short"
PYTEST_ARGS+=" --ignore=openff/toolkit/_tests/test_links.py"
# This should work if run directly at release time, but a safer approach would be
# to `git checkout` the corresponding tag of the release, see PR #577
pytest $PYTEST_ARGS ../
- uses: actions/checkout@v4

- name: Install conda environment
uses: mamba-org/setup-micromamba@v1
with:
environment-file: devtools/conda-envs/installer.yaml
create-args: >-
python=${{ matrix.python-version }}
# default - will pull down 2.0 which we don't want!
# micromamba-version: latest
# pin to latest 1.x release
micromamba-version: "1.5.10-0"

- name: Additional info about the build
shell: bash
run: |
uname -a
df -h
ulimit -a
- name: Environment Information
shell: bash -l {0}
run: |
conda info
conda list
- name: Prepare and run the constructor
shell: bash -l {0}
run: |
#cd ..
# Find the tag of the last release (excluding RCs)
# TODO: Make this a variable that can be passed through from trigger and/or allow RC
export LATEST_TAG=$(git ls-remote --tags https://github.com/openforcefield/openff-toolkit.git | cut -f2 | grep -E "([0-9]+)\.([0-9]+)\.([0-9]+)$" | sort --version-sort | tail -1 | sed 's/refs\/tags\///')
echo $LATEST_TAG
git clone https://github.com/openforcefield/toolkit-installer-constructor
cd toolkit-installer-constructor
python ../devtools/scripts/build_cookiecutter_json.py $LATEST_TAG $PYVER $CI_OS
cp new_cookiecutter.json cookiecutter/cookiecutter.json
cat new_cookiecutter.json
python run.py
pwd
ls
ls build
- name: Upload installer as artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}_py${{ matrix.python-version }}.sh
path: toolkit-installer-constructor/build/openff-toolkit*/openff-toolkit*.sh

- name: Install from installer
shell: bash -l {0}
run: |
#cd ..
pwd
ls
ls toolkit-installer-constructor
ls toolkit-installer-constructor/build
ls toolkit-installer-constructor/build/openff-toolkit-*/
mkdir scratch
cd scratch
echo $HOME/constructor_install/ | bash ../toolkit-installer-constructor/build/openff-toolkit-*/openff-toolkit-*.sh
conda activate $HOME/constructor_install/
conda info
conda list
export FOUND_VER=$(python -c "import openff.toolkit; print(openff.toolkit.__version__)")
export LATEST_TAG=$(git ls-remote --tags https://github.com/openforcefield/openff-toolkit.git | cut -f2 | grep -v "rc" | tail -1 | sed 's/refs\/tags\///')
echo $LATEST_TAG
echo $FOUND_VER
if [[ $LATEST_TAG != $FOUND_VER ]];
then echo "Version mismatch"
exit 1
fi
PYTEST_ARGS=" -r fE --tb=short"
PYTEST_ARGS+=" --ignore=openff/toolkit/_tests/test_links.py"
# This should work if run directly at release time, but a safer approach would be
# to `git checkout` the corresponding tag of the release, see PR #577
pytest $PYTEST_ARGS ../

0 comments on commit 028e4ff

Please sign in to comment.