Edited remote validation notebook #3340
Workflow file for this run
This file contains 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: CI | |
on: | |
push: | |
branches: | |
- main | |
- dev | |
pull_request: | |
branches: | |
- main | |
- dev | |
- feat/* | |
- 0.*.* | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
Linting: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Poetry | |
uses: snok/install-poetry@v1 | |
- name: Install Dependencies | |
# TODO: fix errors so that we can run `make dev` instead | |
run: | | |
# Setup Virtual Environment | |
python3 -m venv ./.venv | |
source .venv/bin/activate | |
make full | |
- name: Lint with ruff | |
run: | | |
source .venv/bin/activate | |
make lint | |
Typing: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Poetry | |
uses: snok/install-poetry@v1 | |
- name: Install Dependencies | |
# TODO: fix errors so that we can run `make dev` instead | |
run: | | |
# Setup Virtual Environment | |
python3 -m venv ./.venv | |
source .venv/bin/activate | |
make full | |
- name: Static analysis with pyright | |
run: | | |
source .venv/bin/activate | |
make type | |
Pytests: | |
runs-on: LargeBois | |
strategy: | |
matrix: | |
python-version: ["3.9", "3.10", "3.11", "3.12"] | |
# TODO: fix errors so that we can run both `make dev` and `make full` | |
# dependencies: ['dev', 'full'] | |
# dependencies: ["full"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Create .guardrailsrc | |
run: | | |
echo 'id="SYSTEM TESTING"' > ~/.guardrailsrc | |
echo 'enable_metrics=false' >> ~/.guardrailsrc | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Poetry | |
uses: snok/install-poetry@v1 | |
- name: Install Dependencies | |
run: | | |
# Setup Virtual Environment | |
python3 -m venv ./.venv | |
source .venv/bin/activate | |
make full | |
if [ "${{ matrix.python-version }}" == "3.12" ]; then | |
echo "Installing latest langchain-core and langsmith from PyPI" | |
pip install "langchain-core>=0.2" "langsmith<0.2.0,>=0.1.75" | |
fi | |
- name: Run Pytests | |
run: | | |
source .venv/bin/activate | |
echo "langchain-core version:" | |
pip show langchain-core | |
echo "langsmith version:" | |
pip show langsmith | |
make test-cov | |
- name: Upload to codecov.io | |
uses: codecov/codecov-action@v3 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
file: ./coverage.xml | |
flags: unittests | |
name: codecov-umbrella | |
fail_ci_if_error: true |