Skip to content

Commit 75bd897

Browse files
committed
ci: isolate recurrent test predecessor
1 parent 38033b9 commit 75bd897

2 files changed

Lines changed: 45 additions & 18 deletions

File tree

‎.github/workflows/diagnose-recurrent-linux.yaml‎

Lines changed: 44 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,6 @@ on:
99
jobs:
1010
diagnose:
1111
runs-on: ubuntu-latest
12-
strategy:
13-
fail-fast: false
14-
matrix:
15-
include:
16-
- name: native-repack
17-
cmake-args: -DGGML_NATIVE=ON -DGGML_CPU_REPACK=ON
18-
- name: generic-repack
19-
cmake-args: -DGGML_NATIVE=OFF -DGGML_CPU_REPACK=ON
20-
- name: native-no-repack
21-
cmake-args: -DGGML_NATIVE=ON -DGGML_CPU_REPACK=OFF
22-
name: ${{ matrix.name }}
2312
steps:
2413
- uses: actions/checkout@v6
2514
with:
@@ -39,22 +28,60 @@ jobs:
3928
sudo apt-get install --yes gdb
4029
4130
- name: Build package
42-
env:
43-
CMAKE_ARGS: ${{ matrix.cmake-args }}
4431
run: |
4532
python -m pip install --upgrade pip
4633
python -m pip install uv
4734
python -m uv pip install -e '.[all]' --verbose
4835
49-
- name: Reproduce with native diagnostics
36+
- name: Recurrent test alone
5037
continue-on-error: true
51-
run: python tests/diagnose_recurrent_context.py
38+
run: |
39+
python -m pytest -vv -s \
40+
tests/test_llama.py::test_recurrent_model_prompt_cache_reset
41+
42+
- name: Recurrent test after low-level model
43+
continue-on-error: true
44+
run: |
45+
python -m pytest -vv -s \
46+
tests/test_llama.py::test_real_model \
47+
tests/test_llama.py::test_recurrent_model_prompt_cache_reset
48+
49+
- name: Recurrent test after high-level model
50+
continue-on-error: true
51+
run: |
52+
python -m pytest -vv -s \
53+
tests/test_llama.py::test_real_llama \
54+
tests/test_llama.py::test_recurrent_model_prompt_cache_reset
55+
56+
- name: Recurrent test after repeated-prompt model
57+
continue-on-error: true
58+
run: |
59+
python -m pytest -vv -s \
60+
tests/test_llama.py::test_real_llama_repeated_prompt_cache \
61+
tests/test_llama.py::test_recurrent_model_prompt_cache_reset
62+
63+
- name: Reproduce original test sequence
64+
continue-on-error: true
65+
run: |
66+
python -m pytest -vv -s \
67+
tests/test_llama.py::test_llama_cpp_version \
68+
tests/test_llama.py::test_llama_cpp_tokenization \
69+
tests/test_llama.py::test_real_model \
70+
tests/test_llama.py::test_real_llama \
71+
tests/test_llama.py::test_real_llama_repeated_prompt_cache \
72+
tests/test_llama.py::test_recurrent_model_prompt_cache_reset
5273
53-
- name: Capture native backtrace
74+
- name: Capture original-sequence backtrace
5475
continue-on-error: true
5576
run: |
5677
gdb --batch \
5778
-ex "set pagination off" \
5879
-ex run \
5980
-ex "thread apply all bt" \
60-
--args python tests/diagnose_recurrent_context.py
81+
--args python -m pytest -vv -s \
82+
tests/test_llama.py::test_llama_cpp_version \
83+
tests/test_llama.py::test_llama_cpp_tokenization \
84+
tests/test_llama.py::test_real_model \
85+
tests/test_llama.py::test_real_llama \
86+
tests/test_llama.py::test_real_llama_repeated_prompt_cache \
87+
tests/test_llama.py::test_recurrent_model_prompt_cache_reset

‎tests/test_llama.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ def _assert_prompt_cache_reset_handles_history_edit(
309309
n_threads=multiprocessing.cpu_count(),
310310
n_threads_batch=multiprocessing.cpu_count(),
311311
logits_all=False,
312-
verbose=False,
312+
verbose=True,
313313
)
314314

315315
assert model._is_recurrent is is_recurrent

0 commit comments

Comments
 (0)