Skip to content

Commit

Permalink
polish
Browse files Browse the repository at this point in the history
Signed-off-by: Adrian Cole <[email protected]>
  • Loading branch information
codefromthecrypt committed Sep 19, 2024
1 parent a6e043c commit e175077
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
- name: Cache Ollama models
id: cache-ollama
uses: actions/cache@v4
with: # make the cache key based on where the OLLAMA_MODEL constant is defined.
with: # cache key is based on where OLLAMA_MODEL is defined.
path: ~/.ollama/models # default directory for Ollama models
key: ollama-${{ hashFiles('./src/exchange/providers/ollama.py') }}

Expand All @@ -70,10 +70,13 @@ jobs:
# Block using the ready endpoint mentioned in ollama/ollama#3341
time curl --retry 5 --retry-connrefused --retry-delay 0 -sf http://localhost:11434
- name: Pull Ollama model
# First time pull, and first time execution of a model is slow, so we do
# this prior to running tests. This also reduces the chance of flakiness.
- name: Pull and Test Ollama model
run: | # get the OLLAMA_MODEL from ./src/exchange/providers/ollama.py
OLLAMA_MODEL=$(uv run python -c "from src.exchange.providers.ollama import OLLAMA_MODEL; print(OLLAMA_MODEL)")
ollama pull $OLLAMA_MODEL || cat ollama.log
ollama run $OLLAMA_MODEL hello || cat ollama.log
- name: Run Ollama tests
run: uv run pytest tests -m integration -k ollama

0 comments on commit e175077

Please sign in to comment.