Skip to content

Commit 32482f3

Browse files
authored
feat(registryctl): deliver the Registry Stack 1.0 adopter journey (#598)
Closes #496 Closes #519 Closes #575 Signed-off-by: Jeremi Joslin <jeremi@joslin.fr>
1 parent 63ff711 commit 32482f3

357 files changed

Lines changed: 84853 additions & 57556 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/scripts/ci_changes.py‎

Lines changed: 12 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -77,55 +77,11 @@
7777
}
7878
)
7979
REPO_ROOT = Path(__file__).resolve().parents[2]
80-
STANDARD_JOURNEY_MANIFEST = (
81-
REPO_ROOT / "docs/site/src/data/standard-journeys.yaml"
82-
)
8380
AUTHORING_REFERENCE_MANIFEST = (
8481
REPO_ROOT / "docs/site/scripts/authoring-reference-sources.json"
8582
)
8683

8784

88-
def standard_journey_sources(
89-
manifest_path: Path = STANDARD_JOURNEY_MANIFEST,
90-
) -> frozenset[str]:
91-
"""Extract the exact canonical source paths from the journey manifest.
92-
93-
The manifest owns this routing inventory. Keeping the deliberately small
94-
parser here avoids adding a YAML dependency to the CI classifier.
95-
"""
96-
97-
sources: list[str] = []
98-
in_canonical_sources = False
99-
for line in manifest_path.read_text(encoding="utf-8").splitlines():
100-
if line == " canonical_sources:":
101-
in_canonical_sources = True
102-
continue
103-
if in_canonical_sources and line.startswith(" - "):
104-
source = line.removeprefix(" - ").strip()
105-
if (
106-
not source
107-
or source[0] in {"'", '"', "{", "["}
108-
or source.startswith(("/", "../"))
109-
):
110-
raise ValueError(
111-
"standard journey canonical_sources must contain "
112-
f"unquoted repository-relative paths: {source!r}"
113-
)
114-
sources.append(source)
115-
continue
116-
if in_canonical_sources and line and not line.startswith(" "):
117-
in_canonical_sources = False
118-
119-
if not sources:
120-
raise ValueError(
121-
f"no standard journey canonical_sources found in {manifest_path}"
122-
)
123-
return frozenset(sources)
124-
125-
126-
STANDARD_JOURNEY_SOURCES = standard_journey_sources()
127-
128-
12985
def authoring_reference_contract_sources(
13086
manifest_path: Path = AUTHORING_REFERENCE_MANIFEST,
13187
) -> tuple[str, ...]:
@@ -456,15 +412,13 @@ def classify(
456412
"crates/registryctl/src/project_authoring/diagnostics.rs",
457413
"crates/registryctl/src/project_authoring/fixture_diagnostics.rs",
458414
"crates/registryctl/src/project_authoring/fixture_coverage.rs",
459-
"crates/registryctl/src/project_authoring/migration.rs",
460415
"crates/registryctl/src/project_authoring/output.rs",
461416
"crates/registryctl/src/project_authoring/preflight.rs",
462-
"crates/registryctl/src/project_authoring/promotion.rs",
417+
"crates/registryctl/src/project_authoring/promotion_projection.rs",
463418
"crates/registryctl/src/project_authoring/report_contract.rs",
464-
"crates/registryctl/src/project_authoring/semantic_comparison.rs",
419+
"crates/registryctl/src/project_authoring/required_product_action.rs",
465420
"crates/registryctl/tests/fixtures/project-authoring-journeys.yaml",
466421
}
467-
or path in STANDARD_JOURNEY_SOURCES
468422
for path in paths
469423
)
470424
docs_archives = any(
@@ -502,11 +456,21 @@ def classify(
502456
"LICENSE",
503457
"docs/site/package-lock.json",
504458
"docs/site/package.json",
459+
"docs/site/public/examples/registryctl/jsonplaceholder-todo-live-overlay-v1.sh",
460+
"docs/site/public/examples/registryctl/jsonplaceholder-todo-live-overlay-v1.sh.sha256",
461+
"docs/site/public/examples/registryctl/opencrvs-events-api-overlay-v1.sh",
462+
"docs/site/public/examples/registryctl/opencrvs-events-api-overlay-v1.sh.sha256",
505463
"docs/site/scripts/check-registryctl-tutorials.sh",
506464
"docs/site/scripts/registryctl-tutorial.mjs",
507465
"docs/site/scripts/registryctl-tutorial.test.mjs",
466+
"docs/site/src/content/docs/configure/oauth-client-credentials.mdx",
467+
"docs/site/src/content/docs/operate/approve-initial-baseline.mdx",
468+
"docs/site/src/content/docs/tutorials/author-registry-project.mdx",
469+
"docs/site/src/content/docs/tutorials/configure-project-script-adapter.mdx",
508470
"docs/site/src/content/docs/tutorials/publish-spreadsheet-secured-registry-api.mdx",
471+
"docs/site/src/content/docs/tutorials/use-your-spreadsheet.mdx",
509472
"docs/site/src/content/docs/tutorials/verify-claim-registry-api.mdx",
473+
"docs/site/src/content/docs/tutorials/verify-opencrvs-claims.mdx",
510474
"release/docker/Dockerfile.registry-notary",
511475
"release/docker/Dockerfile.registry-relay",
512476
}

‎.github/scripts/test_ci_changes.py‎

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
AUTHORING_REFERENCE_INPUTS,
1717
RELEASE_SECURITY_WORKFLOWS,
1818
SHARDS,
19-
STANDARD_JOURNEY_SOURCES,
2019
Workspace,
2120
authoring_reference_inputs,
2221
classify,
@@ -423,22 +422,6 @@ def test_first_country_docs_and_journey_routing_matrix(self) -> None:
423422
"registryctl_tutorial": True,
424423
},
425424
),
426-
(
427-
"docs/site/src/data/standard-journeys.yaml",
428-
{
429-
"docs": True,
430-
"rust": False,
431-
"registryctl_tutorial": False,
432-
},
433-
),
434-
(
435-
"docs/site/scripts/generate-standard-journeys.mjs",
436-
{
437-
"docs": True,
438-
"rust": False,
439-
"registryctl_tutorial": False,
440-
},
441-
),
442425
(
443426
"docs/site/src/components/JourneyGateMatrix.astro",
444427
{
@@ -513,17 +496,38 @@ def test_tutorial_package_dependencies_route_the_source_journey(self) -> None:
513496
for output, value in expected.items():
514497
self.assertEqual(outputs[output], value, output)
515498

499+
def test_current_reader_journey_inputs_route_the_source_journey(self) -> None:
500+
inputs = (
501+
"docs/site/public/examples/registryctl/jsonplaceholder-todo-live-overlay-v1.sh",
502+
"docs/site/public/examples/registryctl/jsonplaceholder-todo-live-overlay-v1.sh.sha256",
503+
"docs/site/public/examples/registryctl/opencrvs-events-api-overlay-v1.sh",
504+
"docs/site/public/examples/registryctl/opencrvs-events-api-overlay-v1.sh.sha256",
505+
"docs/site/src/content/docs/configure/oauth-client-credentials.mdx",
506+
"docs/site/src/content/docs/operate/approve-initial-baseline.mdx",
507+
"docs/site/src/content/docs/tutorials/author-registry-project.mdx",
508+
"docs/site/src/content/docs/tutorials/configure-project-script-adapter.mdx",
509+
"docs/site/src/content/docs/tutorials/publish-spreadsheet-secured-registry-api.mdx",
510+
"docs/site/src/content/docs/tutorials/use-your-spreadsheet.mdx",
511+
"docs/site/src/content/docs/tutorials/verify-claim-registry-api.mdx",
512+
"docs/site/src/content/docs/tutorials/verify-opencrvs-claims.mdx",
513+
)
514+
515+
for path in inputs:
516+
with self.subTest(path=path):
517+
self.assertTrue(
518+
classify(self.workspace, (path,))["registryctl_tutorial"]
519+
)
520+
516521
def test_first_country_generation_inputs_run_docs(self) -> None:
517522
inputs = (
518523
"crates/registryctl/assets/project-starters/**",
519524
"crates/registryctl/src/main.rs",
520-
"crates/registryctl/src/project_authoring/compiler/relay.rs",
521525
"crates/registryctl/src/project_authoring/output.rs",
526+
"crates/registryctl/src/project_authoring/promotion_projection.rs",
522527
"crates/registryctl/src/project_authoring/report_contract.rs",
523528
"crates/registryctl/src/templates/**",
524529
"crates/registryctl/tests/fixtures/project-authoring-journeys.yaml",
525530
"crates/registryctl/tests/fixtures/project-authoring/**",
526-
"crates/registryctl/tests/project_authoring.rs",
527531
"crates/registry-relay/src/api/openapi.rs",
528532
"crates/registry-relay/src/main.rs",
529533
"crates/registry-relay/src/server.rs",
@@ -543,11 +547,6 @@ def test_docs_job_fetches_ignored_openapi_inputs_before_script_tests(self) -> No
543547
self.assertIn(fetch, docs_job)
544548
self.assertLess(docs_job.index(fetch), docs_job.index(test_scripts))
545549

546-
def test_every_standard_journey_source_routes_to_docs(self) -> None:
547-
for source in sorted(STANDARD_JOURNEY_SOURCES):
548-
with self.subTest(source=source):
549-
self.assertTrue(classify(self.workspace, (source,))["docs"])
550-
551550
def test_other_workflow_changes_do_not_select_the_full_matrix(self) -> None:
552551
for workflow in sorted(RELEASE_SECURITY_WORKFLOWS):
553552
with self.subTest(workflow=workflow):

‎.github/workflows/ci.yml‎

Lines changed: 14 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -631,40 +631,6 @@ jobs:
631631
cargo test --locked -p registryctl --test project_authoring
632632
every_cataloged_supported_project_authoring_command_is_automated -- --exact
633633
634-
- name: Setup Node
635-
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
636-
with:
637-
node-version: 22.12.0
638-
cache: npm
639-
cache-dependency-path: docs/site/package-lock.json
640-
641-
- name: Install docs shell dependency
642-
if: runner.os == 'Linux'
643-
run: |
644-
sudo apt-get update
645-
sudo apt-get install --yes zsh
646-
647-
- name: Assert docs shell dependencies
648-
shell: bash
649-
run: |
650-
set -euo pipefail
651-
command -v sh
652-
command -v bash
653-
command -v zsh
654-
655-
- name: Install docs dependencies
656-
working-directory: docs/site
657-
run: npm ci
658-
659-
- name: Execute required standard journey commands from clean directories
660-
working-directory: docs/site
661-
env:
662-
REGISTRYCTL_BIN: ${{ github.workspace }}/target/debug/registryctl
663-
run: >-
664-
node --test
665-
--test-name-pattern="executes every required noninteractive sequence"
666-
scripts/generate-standard-journeys.test.mjs
667-
668634
release-tool:
669635
name: Release tooling checks
670636
needs: changes
@@ -680,6 +646,11 @@ jobs:
680646
- name: Test adopter Compose conformance checker
681647
run: python3 -m unittest release/scripts/test_check_adopter_compose_contract.py
682648

649+
- name: Test PostgreSQL runtime recipe
650+
env:
651+
REGISTRY_POSTGRESQL_DOCKER_PROOF: "1"
652+
run: python3 -m unittest release/scripts/test_postgresql_runtime_recipe.py
653+
683654
- name: Check adopter Compose models
684655
run: bash release/scripts/check_adopter_compose_contract.sh
685656

@@ -689,6 +660,12 @@ jobs:
689660
- name: Test first-country release-form runner
690661
run: python3 -m unittest release/scripts/test_first_country_release_form.py
691662

663+
- name: Test RegistryReleaseLockV1 tooling
664+
run: python3 -m unittest release/scripts/test_registry_release_lock.py
665+
666+
- name: Check release-lock runtime and Compose parity
667+
run: bash release/scripts/check-runtime-contract-parity.sh
668+
692669
- name: Test release planning commands
693670
run: python3 -m unittest release/scripts/test_registry_release_plans.py
694671

@@ -710,6 +687,9 @@ jobs:
710687
- name: Test release workflow structure
711688
run: python3 -m unittest release/scripts/test_release_workflow_structure.py
712689

690+
- name: Test release workflow guard
691+
run: python3 -m unittest release/scripts/test_release_workflow_guard.py
692+
713693
- name: Test release image OCI label checker
714694
run: python3 -m unittest release/scripts/test_check_release_image_oci_labels.py
715695

‎.github/workflows/docs-pages.yml‎

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,6 @@ jobs:
128128
working-directory: docs/site
129129
run: npm ci
130130

131-
- name: Check standard journey generation
132-
working-directory: docs/site
133-
run: node scripts/generate-standard-journeys.mjs --check
134-
135131
- name: Build protected main at /dev/
136132
working-directory: docs/site
137133
run: |

0 commit comments

Comments
 (0)