check envs #590
This file contains hidden or 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
| name: SolveBio Python Package | |
| # on: [push, pull_request] | |
| on: [push] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 | |
| strategy: | |
| matrix: | |
| python-version: ['3.8', '3.9','3.10', '3.11', '3.12'] | |
| env: | |
| SOLVEBIO_API_HOST: ${{ secrets.QUARTZBIO_API_HOST }} | |
| SOLVEBIO_API_KEY: ${{ secrets.QUARTZBIO_API_KEY }} | |
| steps: | |
| - name: Debug environment variables | |
| run: | | |
| if [ -z "${{ secrets.QUARTZBIO_API_HOST }}" ]; then | |
| echo "QUARTZBIO_API_HOST is not set." | |
| else | |
| echo "QUARTZBIO_API_HOST starts with: ${${{ secrets.QUARTZBIO_API_HOST }}:0:10}..." | |
| fi | |
| if [ -z "${{ secrets.QUARTZBIO_API_KEY }}" ]; then | |
| echo "QUARTZBIO_API_KEY is not set." | |
| else | |
| echo "QUARTZBIO_API_KEY starts with: ${${{ secrets.QUARTZBIO_API_KEY }}:0:4}..." | |
| fi | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Display Python version | |
| run: python -c "import sys; print(sys.version)" | |
| - name: Export pythonpath | |
| run: | | |
| export PYTHONPATH=$PYTHONPATH:$(pwd) | |
| - name: Install Tox and any other packages | |
| run: | | |
| pip install -U wheel --user | |
| pip install setuptools | |
| pip install flake8 pytest | |
| - name: Install dependencies | |
| run: | | |
| pip install -r requirements-dev.txt | |
| pip install XlsxWriter===0.9.3 | |
| - name: Scripts | |
| run: | | |
| python -m pytest recipes/tests/test_recipes_sync.py | |
| python -m pytest solvebio/test/test_object.py | |
| python -m flake8 solvebio |