-
Notifications
You must be signed in to change notification settings - Fork 318
61 lines (54 loc) · 2.03 KB
/
Copy pathpersisted-settings-compat.yml
File metadata and controls
61 lines (54 loc) · 2.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
---
name: Persisted settings compatibility checks
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
persisted-settings-compat:
name: Persisted settings
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Install workspace deps (dev)
run: uv sync --frozen --group dev
- name: Run persisted settings compatibility check
shell: bash
run: |
uv run python .github/scripts/check_persisted_settings_compat.py \
2>&1 | tee persisted-settings-compat.log
exit_code=${PIPESTATUS[0]}
exit "${exit_code}"
- name: Write persisted settings summary
if: ${{ always() }}
env:
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
run: |
python3 <<'PY' >> "$GITHUB_STEP_SUMMARY"
import os
from pathlib import Path
log_path = Path("persisted-settings-compat.log")
if log_path.exists():
excerpt = log_path.read_text()[:1000].replace("```", "``\\`")
print("## Persisted settings compatibility checks")
print()
print("<details><summary>Log excerpt (first 1000 characters)</summary>")
print()
print("```text")
print(excerpt)
print("```")
print()
print("</details>")
print()
print(f"[Action log]({os.environ['RUN_URL']})")
PY