@@ -108,6 +108,39 @@ jobs:
108108 chmod +x ./drift/instrumentation/${{ matrix.library }}/e2e-tests/run.sh
109109 cd ./drift/instrumentation/${{ matrix.library }}/e2e-tests && ./run.sh 8000
110110
111+ - name : Print replay logs for ${{ matrix.library }}
112+ if : always()
113+ run : |
114+ log_dir=./drift/instrumentation/${{ matrix.library }}/e2e-tests/.tusk/logs
115+ if ! sudo test -d "$log_dir"; then
116+ echo "No replay log directory found"
117+ exit 0
118+ fi
119+
120+ sudo chmod -R a+rX "$log_dir" || true
121+ sudo chown -R "$(id -u):$(id -g)" "$log_dir" || true
122+
123+ shopt -s nullglob
124+ logs=("$log_dir"/*)
125+ if [ ${#logs[@]} -eq 0 ]; then
126+ echo "No replay logs found"
127+ exit 0
128+ fi
129+
130+ for f in "${logs[@]}"; do
131+ echo "=== $f ==="
132+ cat "$f"
133+ done
134+
135+ - name : Upload replay logs for ${{ matrix.library }}
136+ if : always()
137+ uses : actions/upload-artifact@v4
138+ with :
139+ name : e2e-${{ matrix.library }}-replay-logs
140+ path : ./drift/instrumentation/${{ matrix.library }}/e2e-tests/.tusk/logs
141+ if-no-files-found : ignore
142+ include-hidden-files : true
143+
111144 - name : Cleanup Docker resources
112145 if : always()
113146 run : |
@@ -186,6 +219,39 @@ jobs:
186219 chmod +x ./drift/stack-tests/${{ matrix.test }}/run.sh
187220 cd ./drift/stack-tests/${{ matrix.test }} && ./run.sh 8000
188221
222+ - name : Print replay logs for ${{ matrix.test }}
223+ if : always()
224+ run : |
225+ log_dir=./drift/stack-tests/${{ matrix.test }}/.tusk/logs
226+ if ! sudo test -d "$log_dir"; then
227+ echo "No replay log directory found"
228+ exit 0
229+ fi
230+
231+ sudo chmod -R a+rX "$log_dir" || true
232+ sudo chown -R "$(id -u):$(id -g)" "$log_dir" || true
233+
234+ shopt -s nullglob
235+ logs=("$log_dir"/*)
236+ if [ ${#logs[@]} -eq 0 ]; then
237+ echo "No replay logs found"
238+ exit 0
239+ fi
240+
241+ for f in "${logs[@]}"; do
242+ echo "=== $f ==="
243+ cat "$f"
244+ done
245+
246+ - name : Upload replay logs for ${{ matrix.test }}
247+ if : always()
248+ uses : actions/upload-artifact@v4
249+ with :
250+ name : stack-${{ matrix.test }}-replay-logs
251+ path : ./drift/stack-tests/${{ matrix.test }}/.tusk/logs
252+ if-no-files-found : ignore
253+ include-hidden-files : true
254+
189255 - name : Cleanup Docker resources
190256 if : always()
191257 run : |
@@ -257,6 +323,39 @@ jobs:
257323 chmod +x ./drift/instrumentation/requests/e2e-tests/run.sh
258324 cd ./drift/instrumentation/requests/e2e-tests && ./run.sh 8000
259325
326+ - name : Print replay logs for requests smoke test
327+ if : always()
328+ run : |
329+ log_dir=./drift/instrumentation/requests/e2e-tests/.tusk/logs
330+ if ! sudo test -d "$log_dir"; then
331+ echo "No replay log directory found"
332+ exit 0
333+ fi
334+
335+ sudo chmod -R a+rX "$log_dir" || true
336+ sudo chown -R "$(id -u):$(id -g)" "$log_dir" || true
337+
338+ shopt -s nullglob
339+ logs=("$log_dir"/*)
340+ if [ ${#logs[@]} -eq 0 ]; then
341+ echo "No replay logs found"
342+ exit 0
343+ fi
344+
345+ for f in "${logs[@]}"; do
346+ echo "=== $f ==="
347+ cat "$f"
348+ done
349+
350+ - name : Upload replay logs for requests smoke test
351+ if : always()
352+ uses : actions/upload-artifact@v4
353+ with :
354+ name : requests-smoke-replay-logs
355+ path : ./drift/instrumentation/requests/e2e-tests/.tusk/logs
356+ if-no-files-found : ignore
357+ include-hidden-files : true
358+
260359 - name : Cleanup Docker resources
261360 if : always()
262361 run : |
0 commit comments