Repository navigation
185 lines (180 loc) · 9.86 KB
/
Copy pathvalidate.yml
File metadata and controls
185 lines (180 loc) · 9.86 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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
name: Validate
on:
push:
pull_request:
permissions:
contents: read
jobs:
actionlint:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v6
- name: Actionlint
uses: docker://rhysd/actionlint:1.7.12
python:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Install Python packaging tools
run: |
set -euo pipefail
python3 -m pip install --upgrade pip
python3 -m pip install build -e ./python
- name: Verify Python dependencies
run: python3 -m pip check
- name: Check whitespace
run: |
set -euo pipefail
if [ "${{ github.event_name }}" = "pull_request" ]; then
git fetch --no-tags --depth=1 origin "${{ github.base_ref }}"
git diff --check "origin/${{ github.base_ref }}...HEAD"
else
git diff-tree --check --no-commit-id --root -r HEAD
fi
- name: Validate generated display names
run: python3 python/scripts/build_display_names.py --check
- name: Validate platform config
run: python3 python/scripts/build_config.py --check
- name: Validate runtime targets
run: python3 python/scripts/runtime_settings.py validate
- name: Run Python unit tests
run: python3 -m unittest discover -s python/tests -v
- name: Build Python package
run: python3 -m build ./python
- name: Checkout internal dependency consumer repos
env:
GH_TOKEN: ${{ github.token }}
run: bash python/shell/checkout_internal_dependency_consumers.sh --output-root ..
- name: Report internal dependency matrix
run: python3 python/scripts/check_internal_dependency_matrix.py --projects-root .. --json --require-consumer-files
- name: Enforce internal dependency matrix when its ledger changes
run: |
set -euo pipefail
if [ "${{ github.event_name }}" = "pull_request" ]; then
comparison_range="origin/${{ github.base_ref }}...HEAD"
elif git rev-parse --verify HEAD^ >/dev/null 2>&1; then
comparison_range="HEAD^...HEAD"
else
echo "No parent commit is available; reporting dependency drift without a strict ledger gate."
exit 0
fi
if git diff --quiet "$comparison_range" -- internal_dependency_matrix.json; then
echo "Internal dependency ledger did not change; retaining the report without making this unrelated PR non-hermetic."
exit 0
fi
python3 python/scripts/check_internal_dependency_matrix.py --projects-root .. --json --strict --require-consumer-files
js:
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: actions/setup-node@v6
with:
node-version: "22"
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Validate offline synthetic reconciliation console
run: node tests/offline_reconciliation_console_validation.mjs
- name: Install local Worker test runtime
working-directory: web/strategy-switch-console
run: npm ci
- name: Validate strategy switch web assets
env:
CLOUDFLARE_CF_FETCH_ENABLED: "false"
npm_config_update_notifier: "false"
run: |
set -euo pipefail
node tests/display_names_validation.mjs
node tests/console_v2_assets_validation.mjs
node tests/console_deploy_safety_validation.mjs
npm ci --prefix web/strategy-switch-console/frontend
npm run build --prefix web/strategy-switch-console/frontend
npm run sync:v2-assets --prefix web/strategy-switch-console/frontend
node tests/console_v2_assets_validation.mjs
npm run test:operations --prefix web/strategy-switch-console/frontend
node tests/console_candidate_readiness_validation.mjs
node tests/console_acceptance_budget_validation.mjs
node tests/kv_directory_validation.mjs
node tests/console_source_quota_validation.mjs
node tests/console_inbox_requests_validation.mjs
node tests/console_v2_i18n_validation.mjs
node tests/console_account_state_validation.mjs
node --experimental-strip-types tests/console_presentation_validation.mjs
node --experimental-strip-types tests/strategy_display_identity_validation.mjs
node tests/console_catalog_release_validation.mjs
git diff --exit-code -- web/strategy-switch-console/v2_asset_map.js
python3 python/scripts/build_config.py --check
python3 python/scripts/build_config.py
python3 python/scripts/build_platform_config.py --check
git diff --exit-code -- web/strategy-switch-console/config.js web/strategy-switch-console/strategy_profiles_asset.js web/strategy-switch-console/runtime-catalog-projection.json
jq empty web/strategy-switch-console/strategy-profiles.example.json
node --experimental-default-type=module tests/strategy_switch_worker_validation.mjs
node tests/credential_maintenance_worker_validation.mjs
node --experimental-strip-types tests/credential_maintenance_presentation_validation.mjs
node tests/runtime_daily_worker_validation.mjs
node tests/account_facts_validation.mjs
node tests/ibkr_period_return_validation.mjs
node tests/binance_account_facts_validation.mjs
node tests/binance_receiver_deploy_acceptance_validation.mjs
node tests/account_facts_binding_workflow_validation.mjs
node tests/firstrade_account_facts_preparation_validation.mjs
node tests/ibkr_runtime_lifecycle_inspection_validation.mjs
node --experimental-strip-types tests/account_history_presentation_validation.mjs
node --experimental-strip-types tests/console_chart_visibility_validation.mjs
node tests/console_synthetic_development_validation.mjs
node tests/console_read_recovery_ui_validation.mjs
node --experimental-strip-types tests/overview_benchmark_aggregate_validation.mjs
node --experimental-strip-types tests/overview_fx_proxy_validation.mjs
node --experimental-strip-types tests/market_benchmark_validation.mjs
node tests/market_benchmark_revision_policy_validation.mjs
node tests/market_benchmark_revision_apply_validation.mjs
node tests/account_facts_readonly_extract_validation.mjs
node tests/account_facts_sync_extract_validation.mjs
node tests/owner_decision_extract_validation.mjs
node tests/research_promotion_application_extract_validation.mjs
node --experimental-strip-types tests/research_summary_worker_validation.mjs
node tests/console_v2_worker_validation.mjs
node --experimental-strip-types tests/console_update_notice_validation.mjs
node --experimental-default-type=module tests/runtime_instances_worker_validation.mjs
node --experimental-default-type=module tests/account_diagnosis_worker_validation.mjs
node --experimental-strip-types tests/account_diagnosis_targets_validation.mjs
node --experimental-default-type=module tests/research_promotion_application_worker_validation.mjs
node tests/human_decisions_worker_validation.mjs
node --experimental-strip-types tests/decision_review_material_pure_validation.mjs
node tests/console_api_contract_validation.mjs
node tests/console_api_worker_validation.mjs
node tests/console_design_api_validation.mjs
node web/strategy-switch-console/frontend/node_modules/typescript/bin/tsc -p tests/tsconfig.console-gaps.json
node --experimental-strip-types tests/console_gap_contract_validation.mjs
node --experimental-strip-types tests/console_returns_adapter_validation.mjs
node --experimental-strip-types tests/console_display_gaps_validation.mjs
node --experimental-strip-types tests/console_cashflow_method_presentation_validation.mjs
node --experimental-strip-types tests/console_runtime_daily_selection_validation.mjs
node tests/console_performance_stats_validation.mjs
node --test tests/fe8a_performance_validation.mjs tests/fe8a_runtime_today_validation.mjs tests/fe8a_overview_runtime_ui_validation.mjs
node tests/account_settings_worker_validation.mjs
node --experimental-default-type=module tests/console_evidence_metadata_validation.mjs
node --experimental-strip-types tests/account_settings_state_validation.mjs
node --experimental-strip-types tests/overview_refresh_validation.mjs
node --experimental-strip-types tests/runtime_history_validation.mjs
node --experimental-strip-types tests/workflow_clarity_validation.mjs
node --experimental-strip-types tests/runtime_stop_worker_validation.mjs
node tests/runtime_stop_requests_worker_validation.mjs
node --experimental-default-type=module tests/binance_resume_worker_validation.mjs
node --experimental-default-type=module tests/ux1_research_worker_validation.mjs
node --experimental-default-type=module tests/ux1_async_worker_validation.mjs
node --experimental-default-type=module tests/ux1_async_ui_validation.mjs
node --experimental-strip-types --test tests/console_runtime_state_validation.mjs
node --experimental-strip-types --test tests/binance_private_scope_worker_validation.mjs
node --check --input-type=module < web/strategy-switch-console/strategy_profiles_asset.js
node --check --input-type=module < web/strategy-switch-console/worker.js