CI: fix schema publishing.

Previously, two concurrent jobs were used, which caused a race condition.
Serialize them.
This commit is contained in:
Catherine 2024-05-10 13:32:11 +00:00
parent 496432edaa
commit 631ef564aa
2 changed files with 25 additions and 25 deletions

View file

@ -135,7 +135,7 @@ def _extract_schemas(package, *, base_uri, path="schema/"):
entry_points = distribution(package).entry_points
for entry_point in entry_points.select(group="amaranth.lib.meta"):
schema = entry_point.load().schema
relative_path = entry_point.name # v0.5/component.json
relative_path = entry_point.name # "0.5/component.json"
schema_filename = pathlib.Path(path) / relative_path
assert schema["$id"] == f"{base_uri}/{relative_path}", \
f"Schema $id {schema['$id']} must be {base_uri}/{relative_path}"