Repository navigation
60 lines (57 loc) · 1.71 KB
/
Copy pathvalidate_data.yaml
File metadata and controls
60 lines (57 loc) · 1.71 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
name: Validate data
on:
pull_request:
paths:
- 'data/**'
- 'stores/**'
- 'schemas/**'
- 'ofd/**'
- 'requirements.txt'
push:
branches: [ main ]
paths:
- 'data/**'
- 'stores/**'
- 'schemas/**'
- 'ofd/**'
- 'requirements.txt'
workflow_dispatch:
permissions:
contents: read
jobs:
validate_data:
runs-on: ubuntu-24.04
strategy:
matrix:
name: [ json-files, folder-names, store-ids, logo-files, fiber-consistency, data-quality ]
name: Validate data - ${{ matrix.name }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install dependencies
run: pip install -r requirements.txt
- name: Validate data
run: python -m ofd validate --${{ matrix.name }}
# Canonical UUIDs are assigned post-merge (see style_data.yaml). This gate runs on
# PRs and on the raw merge commit — both legitimately precede assignment — so it
# passes `--allow-missing-uuids`: it flags malformed or duplicated UUIDs but does NOT
# require presence. Presence is enforced strictly in style_data.yaml, right after
# `ofd uuid assign` fills the empty ones.
validate_uuids:
runs-on: ubuntu-24.04
name: Validate data - uuids
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install dependencies
run: pip install -r requirements.txt
- name: Check UUID format and uniqueness
run: python -m ofd uuid check --allow-missing-uuids