Skip to content

Add protocol regression fixtures and a read-only macOS build check - #1

Merged
jmonster merged 5 commits into
mainfrom
test/macos-protocol-build
Sep 10, 2026
Merged

jmonster merged 5 commits into
mainfrom
test/macos-protocol-build

Conversation

@jmonster

@jmonster jmonster commented Sep 9, 2026

Copy link
Copy Markdown
Owner

Ready for review — validation baseline only

Head d32ed57a6bc2d6d991777638b65c08c1664caafb. Exact-head macOS validation passed.

Compile the actual transport-free Switch2Protocol.swift against synthetic fixtures for all 256 trigger values, supported models, sliced Data, truncated reports, command bytes and advertisement parsing. The small runner discovers independent output regression suites; SDL tests requiring their own source checkout use a separate entry point.

The read-only macOS 26 workflow records source/toolchain, runs the tests, builds the actual app through the existing build-app.sh, and verifies its ad-hoc signature/plist. No controller behavior, dependencies, privileges or release credentials change. Synthetic fixtures are not hardware captures; building a bundle does not test pairing or interactive launch.

The combined code from PRs #1#9 also passed the full app/output check and the rebuilt SDL check at test-only commit 8fe38c3. That integration branch is evidence, not a merge target.

Merge this baseline before dependent PRs #3/#4/#5. PR #2 is independent. No merge or release has been performed.

jmonster commented Sep 9, 2026

Copy link
Copy Markdown
Owner Author

Published batch closeout

All nine PRs are pushed, out of draft, and passing the hosted checks for these exact heads:

PR Head Passing run
#1 d32ed57 34381574119
#2 ae5996d 34384651950
#3 2ee0d1c 34383240211
#4 e4c6b3d 34386881848
#5 1babdaf 34417379142
#6 5df0f78 34417573754
#7 7a026de 34416996779
#8 dbe8b15 34390580252
#9 a14d883 34418135025

The combined production candidate was separately built/tested at 8fe38c3: actual macOS app and output suites, actual rebuilt SDL/USB/UDP checks. The subsequent #9 reconciliation changes its README/workflow guidance, not that tested production behavior. Downloaded integration-source bytes for the changed browser, RetroArch, session and UDP implementations match the locally tested versions; the combined portable suites passed again.

This closeout added regression-proven fixes for cancelled RetroArch destination changes and native/browser gamepad-index collisions, corrected source-dependent SDL test discovery, and reconciled the two optional output registrations. The fork README no longer implies that upstream binaries/updates contain this fork's changes.

Merge dependencies: #1#3#8; #1#4; #1#5#6#9; #2#7. Numerical order 1–9 satisfies them. Retarget each dependent PR to main after its prerequisite lands, then recheck CI; do not accidentally merge a follow-up into its temporary feature-branch base. Squash merges may require rebasing follow-ups onto the new main before retargeting.

The test/integration-closeout-20260909 branch is test evidence only, not an all-in-one merge target. main remains ea6719f. No PR merge, release, production signing, notarization or hardware qualification was performed. Compatibility tradeoffs and hardware requirements are recorded in each PR.

jmonster added a commit that referenced this pull request Sep 10, 2026
…ns (#6)

* feat(retroarch): import the optional network gamepad sink for regression validation

Adapted from vialoh/switch2mac retroarch-network-gamepad at
2c7a396 (upstream PR #1).
Retain the contributor's opt-in default and attribution; validate actual
Swift builds and repair edge/lifecycle behavior before marking ready.

* fix(retroarch): preserve edges, refresh releases and retire old destinations

Retain the attributed optional fork output and existing remote_message bytes.
Replace latest-only button state with a bounded edge queue; overflow explicitly
neutralizes this output until disable/re-enable. Include zeros in periodic
refreshes and clear the old port before switching destinations. Reject nonfinite
axes and remove the imported Array safe-subscript compile failure.

Eight synthetic/real-loopback cases pass locally; the tap, release refresh,
destination, overflow and finite-axis cases fail against the imported source.
UDP acceptance is not acknowledgement; no physical-gameplay claim is made.

* fix(retroarch): resume ordered input after cancelling a destination change

A partially completed reset left switchIndex active when the user changed
back to the original port. Subsequent button edges were never queued.
Reassert the desired state and retire that reset; the new real-loopback
regression fails against the previous head and the nine-case suite passes.

* fix(fork): isolate app identity and disable upstream automatic updates (#9)

Use io.github.jmonster.switch2mac and a distinct bundle name/defaults domain.
Keep upstream credits but reject default or saved update feeds and updater
entry points until a fork-specific signing/update trust path is established.

Require explicit signing identities, notary credentials and fork-matching
entitlements instead of silently consuming upstream signing configuration.
No certificate, profile, notarization request or release is created here.

Add metadata, actual feed-resolver and early signing-refusal regressions and
build the actual ad-hoc fork app in the existing read-only macOS check.
* feat(browser): stage attributed browser bridge for guarded integration

Adapted from Andrei-Kondrykau/switch2mac browser-bridge at
24b0cd3 (upstream PR #2).
Keep the output sink unregistered until access and lifecycle guards are added.
Retain the contributor's source and documentation, with our read-only checks.

* fix(browser): guard replay, rumble ownership, and opt-in WebSocket access

Preserve complete connection/state replay after rename and reject obsolete
socket callbacks. Keep long effects alive only for their requested lifetime,
settle cancelled effects, and reject retired actuators. Eight deterministic
Node regressions cover these behaviors (seven fail on the imported source).

Add an opt-in settings window, exact extension-Origin checks, bounded clients
and messages, and per-client rumble ownership. GameCube HD rumble is withheld
using the existing model capability. Origin checks are not native-process
authentication. Exercise the actual Network.framework listener in macOS CI.

Adapted browser feature retains attribution to Andrei-Kondrykau's upstream
browser-bridge at 24b0cd3.

* fix(browser): distinguish validated rumble values from clamped magnitudes

* docs(browser): document fork opt-in setup and actual compatibility limits

* fix(browser): preserve bridged controllers when native gamepads hotplug

Move only a conflicting virtual index and announce the old/new indices,
without mutating prior snapshots or hiding the native device. A regression
fails against the previous shim and all nine Node cases pass after repair.

* Adopt optional RetroArch network output with input-delivery regressions (#6)

* feat(retroarch): import the optional network gamepad sink for regression validation

Adapted from vialoh/switch2mac retroarch-network-gamepad at
2c7a396 (upstream PR #1).
Retain the contributor's opt-in default and attribution; validate actual
Swift builds and repair edge/lifecycle behavior before marking ready.

* fix(retroarch): preserve edges, refresh releases and retire old destinations

Retain the attributed optional fork output and existing remote_message bytes.
Replace latest-only button state with a bounded edge queue; overflow explicitly
neutralizes this output until disable/re-enable. Include zeros in periodic
refreshes and clear the old port before switching destinations. Reject nonfinite
axes and remove the imported Array safe-subscript compile failure.

Eight synthetic/real-loopback cases pass locally; the tap, release refresh,
destination, overflow and finite-axis cases fail against the imported source.
UDP acceptance is not acknowledgement; no physical-gameplay claim is made.

* fix(retroarch): resume ordered input after cancelling a destination change

A partially completed reset left switchIndex active when the user changed
back to the original port. Subsequent button edges were never queued.
Reassert the desired state and retire that reset; the new real-loopback
regression fails against the previous head and the nine-case suite passes.

* fix(fork): isolate app identity and disable upstream automatic updates (#9)

Use io.github.jmonster.switch2mac and a distinct bundle name/defaults domain.
Keep upstream credits but reject default or saved update feeds and updater
entry points until a fork-specific signing/update trust path is established.

Require explicit signing identities, notary credentials and fork-matching
entitlements instead of silently consuming upstream signing configuration.
No certificate, profile, notarization request or release is created here.

Add metadata, actual feed-resolver and early signing-refusal regressions and
build the actual ad-hoc fork app in the existing read-only macOS check.
…ng (#4)

* fix(udp): neutralize disconnected slots and bound subscriber handling

* test(udp): synchronize real datagram arrival before subscriber assertions
…ting (#3)

* fix(session): preserve command correlation and respect model capabilities

* fix(session): retire callbacks before teardown and require usable input for readiness (#8)

Guard late notifications, queued commands and timers after session retirement.
Clear notify completion before invocation to preserve reentrant replacement.
Require isNotifying on essential channels and one existing-decoder input report
before readiness, retaining the established keep-alive and handshake bytes.

Eleven synthetic production-session tests pass locally; five new targeted
cases fail against the prior session source. Full Apple-framework build and
regressions remain the hosted gate. No new connection deadline or protocol.
@jmonster
jmonster merged commit 99c305f into main Sep 10, 2026
1 check passed
@jmonster
jmonster deleted the test/macos-protocol-build branch September 10, 2026 00:03
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