Skip to content

fix(ci): fail the protocol sync when it cannot sync - #387

Merged
Taure merged 1 commit into
mainfrom
fix/protocol-sync-fails-loudly
Aug 5, 2026
Merged

fix(ci): fail the protocol sync when it cannot sync#387
Taure merged 1 commit into
mainfrom
fix/protocol-sync-fails-loudly

Conversation

@Taure

@Taure Taure commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

What is wrong

SDK_SYNC_TOKEN has never been set. Every run of this workflow skips all seven SDKs and reports success:

sync (dart, widgrensit/asobi-dart)   SDK_SYNC_TOKEN is not set - cannot open a PR
sync (godot, widgrensit/asobi-godot) SDK_SYNC_TOKEN is not set - cannot open a PR
...                                  (all seven, run concluded: success)

So the drift it exists to prevent happened anyway. Checked against current main in each repo:

SDK state
js, godot, love2d, defold in sync
dart 6 files behind
unity 7 files behind
unreal 10 files behind

And it is not cosmetic. Defold's copy was stale enough to hide a real entity-sync bug — the SDK understood only the binary delta shape and dropped every JSON delta — which surfaced only when the fixtures were finally synced by hand today.

The change

The token check now fails the job instead of logging and passing.

The graceful skip was deliberate; the header comment gives the reasoning — "rather than failing a build nobody can fix". That reasoning does not survive contact with the outcome: the workflow only runs when the corpus actually changed, so a run that cannot sync means the SDKs are drifting right now, and red is the correct signal. The person who can add the secret is the person who owns this repo. The comment is updated to say all of this, so the next person does not re-soften it.

Follow-up PRs bring dart, unity and unreal back in line.

SDK_SYNC_TOKEN has never been set, so every run of this workflow has
skipped all seven SDKs and reported success. The drift it exists to
prevent happened anyway: dart, unity and unreal are all behind the corpus
on main right now, and defold's copy went stale enough to hide a real
entity-sync bug for weeks - it only surfaced when the fixtures were
finally synced by hand.

The graceful skip was deliberate, on the reasoning that a build nobody
can fix should not go red. The evidence says otherwise: a green run that
did nothing is worse than a red one, and the person who can add the
secret is the person who owns this repo.
Taure added a commit to widgrensit/asobi-dart that referenced this pull request Aug 5, 2026
Six fixtures were behind the corpus in widgrensit/asobi. The sync
workflow that should have caught this has been skipping silently since
it was written (SDK_SYNC_TOKEN was never set); widgrensit/asobi#387
makes it fail instead.

Suite green against the updated corpus - no dispatch changes needed.
Taure added a commit to widgrensit/asobi-unity that referenced this pull request Aug 5, 2026
Seven fixtures were behind the corpus, including match.list which this
SDK had no entry for at all. The sync workflow that should have caught
this has been skipping silently since it was written (SDK_SYNC_TOKEN was
never set); widgrensit/asobi#387 makes it fail instead.

match.list is mapped as correlated-by-cid rather than event-fired: every
WS request here goes out through SendAsync and gets its answer back on
the cid, so the reply would never be an event. Worth noting separately
that this SDK has no realtime match listing at all, unlike defold, godot
and love2d.
Taure added a commit to widgrensit/asobi-unreal that referenced this pull request Aug 5, 2026
* chore: sync the protocol fixtures, and dispatch module.*

Ten fixtures were behind the corpus in widgrensit/asobi, four of them
missing entirely. The sync workflow that should have caught this has been
skipping silently since it was written (SDK_SYNC_TOKEN was never set);
widgrensit/asobi#387 makes it fail instead.

module.error and module.message are the server's current names for
game.error and game.message. They gain EventIds and route to the same
delegates, so a game does not silently drop dev-console output from a
server on the newer naming - the same gap just fixed in the defold and
unity SDKs.

rpc.ok and rpc.error are in the corpus but are deliberately NOT events:
the reply goes to the one caller waiting on that cid, not to every
listener. The dispatch test now excludes them by name rather than
demanding an EventId for every fixture, and they stay covered in
RpcTest.cpp.

kEventCount 35 -> 37. AsobiCore suites green under -Werror: dispatch 20
cases / 347 assertions, auth 11 / 86. The UE-side dispatch case is not
compiled anywhere - CI has no engine licence - so it needs an editor
compile like the rest of AsobiWebSocket.cpp.

* ci: drop the hardcoded fixture list from the smoke workflow

It asserted a literal list of 35 event names, duplicating what
AsobiCore's dispatch test already proves from the EventId table itself:
every fixture has an id (bar the cid-correlated replies), every id has a
fixture, and the counts agree. The copy added nothing except a list to
hand-maintain, and it went stale the first time the corpus grew - it is
what failed this PR, not a real drift.
@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

🟡 Code Coverage — 75.2%

6679 of 8876 lines covered.

@Taure
Taure merged commit aa0b4cd into main Aug 5, 2026
15 checks passed
@Taure
Taure deleted the fix/protocol-sync-fails-loudly branch August 5, 2026 21:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant