File tree Expand file tree Collapse file tree 2 files changed +26
-4
lines changed Expand file tree Collapse file tree 2 files changed +26
-4
lines changed Original file line number Diff line number Diff line change @@ -112,9 +112,9 @@ jobs:
112
112
-DGGML_OPENMP=OFF ;
113
113
cmake --build build --config ${{ matrix.build_type }} -j $(nproc) --target llama-server
114
114
115
- - name : Build
116
- id : cmake_build
117
- if : ${{ matrix.sanitizer != 'THREAD' }}
115
+ - name : Build (sanitizers)
116
+ id : cmake_build_sanitizers
117
+ if : ${{ matrix.sanitizer != '' && matrix.sanitizer != ' THREAD' }}
118
118
run : |
119
119
cmake -B build \
120
120
-DGGML_NATIVE=OFF \
@@ -124,12 +124,31 @@ jobs:
124
124
-DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON ;
125
125
cmake --build build --config ${{ matrix.build_type }} -j $(nproc) --target llama-server
126
126
127
+ - name : Build (sanitizers)
128
+ id : cmake_build
129
+ if : ${{ matrix.sanitizer == '' }}
130
+ run : |
131
+ cmake -B build \
132
+ -DGGML_NATIVE=OFF \
133
+ -DLLAMA_BUILD_SERVER=ON \
134
+ -DLLAMA_CURL=ON \
135
+ -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} ;
136
+ cmake --build build --config ${{ matrix.build_type }} -j $(nproc) --target llama-server
137
+
127
138
- name : Tests
128
139
id : server_integration_tests
140
+ if : ${{ matrix.sanitizer == '' }}
129
141
run : |
130
142
cd examples/server/tests
131
143
./tests.sh
132
144
145
+ - name : Tests (sanitizers)
146
+ id : server_integration_tests_sanitizers
147
+ if : ${{ matrix.sanitizer != '' }}
148
+ run : |
149
+ cd examples/server/tests
150
+ LLAMA_SANITIZE=1 ./tests.sh
151
+
133
152
- name : Slow tests
134
153
id : server_integration_tests_slow
135
154
if : ${{ (github.event.schedule || github.event.inputs.slow_tests == 'true') && matrix.build_type == 'Release' }}
Original file line number Diff line number Diff line change 26
26
import wget
27
27
28
28
29
+ DEFAULT_HTTP_TIMEOUT = 10 if "LLAMA_SANITIZE" not in os .environ else 30
30
+
31
+
29
32
class ServerResponse :
30
33
headers : dict
31
34
status_code : int
@@ -88,7 +91,7 @@ def __init__(self):
88
91
if "PORT" in os .environ :
89
92
self .server_port = int (os .environ ["PORT" ])
90
93
91
- def start (self , timeout_seconds : int = 10 ) -> None :
94
+ def start (self , timeout_seconds : int | None = DEFAULT_HTTP_TIMEOUT ) -> None :
92
95
if "LLAMA_SERVER_BIN_PATH" in os .environ :
93
96
server_path = os .environ ["LLAMA_SERVER_BIN_PATH" ]
94
97
elif os .name == "nt" :
You can’t perform that action at this time.
0 commit comments