Skip to content

feat: add storage adapter conformance - #90

Merged
imjlk merged 7 commits into
mainfrom
codex/storage-adapter-conformance
Jul 16, 2026
Merged

imjlk merged 7 commits into
mainfrom
codex/storage-adapter-conformance

Conversation

@imjlk

@imjlk imjlk commented Jul 16, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • add a reusable public conformance runner for missing reads, round trips, scope and mutation isolation, quota preservation, and fail-closed provider faults
  • make browser and Verse8 local storage reject unavailable or invalid persistence, and keep Devvit storage server-authoritative without a browser fallback
  • exercise eight local and remote target fixtures and keep the generated Devvit server template aligned

Validation

  • pnpm check
  • pnpm test:prepared
  • pnpm pack:packages:prepared
  • SAMPO_RELEASE_BRANCH=main sampo release --dry-run
  • pnpm build:web
  • pnpm build:microsoft-store
  • pnpm build:verse8
  • pnpm build:devvit
  • pnpm build:target ait sandbox

AIT production packaging was also exercised and stopped at the existing external-console prerequisite: ait.icon.externalUrl is intentionally absent from the repository. No personal or production console configuration is added.

Release

Includes a focused Sampo changeset for the affected publishable package contracts.

Summary by CodeRabbit

  • New Features
    • Added reusable storage adapter conformance runner and new storage-conformance package export.
    • Added native (Android/iOS) storage conformance coverage to CI, plus broader cross-platform failure-mode scenarios.
    • Added browser storage injection for deterministic gateway behavior.
  • Bug Fixes
    • Storage now “fails closed” on identity/provider/serialization/quota/transport issues with no browser fallback.
    • Missing values and stored null are distinguished reliably; load/save results use explicit “found” semantics.
    • When saves fail, the previously committed value is preserved.
  • Documentation
    • Expanded storage adapter and platform readiness guidance, including the new conformance command.
  • Tests
    • Added/updated Devvit, Verse8, Capacitor, AIT, and browser storage tests for stricter semantics and quotas.

@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@imjlk, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 48 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8a8aa113-b784-455d-ab7e-b5d6bd6f874a

📥 Commits

Reviewing files that changed from the base of the PR and between 59a094b and 7b50e02.

📒 Files selected for processing (1)
  • apps/target-ait/src/aitBridge.test.ts
📝 Walkthrough

Walkthrough

Storage persistence now follows shared fail-closed conformance rules across browser, AIT, Devvit, Verse8, Capacitor Android/iOS, and smoke-test targets. New quotas, structured errors, native backends, adapter tests, CI checks, documentation, and package exports cover the updated behavior.

Changes

Storage Conformance

Layer / File(s) Summary
Platform conformance contract
packages/platform/src/*, packages/platform/test/*, packages/platform/package.json
Adds reusable scenarios for missing values, overwrites, isolation, mutation safety, quotas, and load/save failures, with exported runner contracts and distribution checks.
Presence-aware bridge contract
packages/bridge/src/*, apps/target-ait/src/*, adapters/ait/src/*, adapters/capacitor/src/*
Introduces { found, value } bridge load responses that distinguish missing keys from stored top-level null values.
Adapter fail-closed behavior
adapters/browser/src/*, adapters/devvit/src/*, adapters/verse8/src/*, adapters/capacitor/src/*
Adds injectable or mandatory storage, explicit unavailable-storage errors, presence-aware decoding, JSON cloning, and removes Devvit browser fallback persistence.
Devvit bridge validation and errors
apps/target-devvit/src/server/index.ts, packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts
Adds identity validation, JSON serialization checks, 256 KiB UTF-8 quotas, and structured Redis failure responses.
Native Capacitor storage
native-plugins/capacitor-game-services/android/*, native-plugins/capacitor-game-services/ios/*
Adds SharedPreferences and application-support-file JSON storage backends with namespacing, quotas, structured errors, migration, rollback behavior, and native conformance tests.
Cross-target validation and release wiring
tools/smoke/*, .github/workflows/ci.yml, package.json, docs/*, native-plugins/*/README.md, .sampo/changesets/*
Adds cross-target smoke fixtures, npm commands, Android/iOS CI execution, documentation, and release metadata for storage conformance and fail-closed persistence.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related PRs

Poem

A rabbit checks each save with care,
No hidden fallback hopping there.
Native stores keep values tight,
Seven tests make paths run right.
Errors bloom, quotas guard—
Conformance makes storage starred!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.82% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately summarizes the main change: adding storage adapter conformance.
Description check ✅ Passed It includes Summary and Validation, and the extra Release note covers the template's Notes content well enough.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/storage-adapter-conformance

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 921e8407b4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review


P2 Badge Preserve JSON null instead of loading it as missing

When a game saves value: null, saveStorage serializes it as the literal null; this line then sends bridge data null back, and the Devvit gateway interprets bridge null as a missing key rather than { value: null }. That violates the advertised JSON-serializable round-trip contract and can silently turn a nullable save slot into an absent one; wrap persisted values or reject top-level null so stored null is distinguishable from no stored value.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🧹 Nitpick comments (1)
tools/smoke/storage-adapter-conformance.ts (1)

90-135: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Reduce duplication and unsafe casts in createBridgeFixture.

The four branches (android/ios/ait/reddit) repeat near-identical primary/isolated construction, each force-casting a minimal { request } stub via as NativeBridge/as GamePlatformBridge/as DevvitBridge. This works today but hides any contract drift if those bridge interfaces grow beyond request(), and the duplication makes adding a new target tedious.

♻️ Proposed refactor
-  if (target === 'android' || target === 'ios') {
-    primary = createCapacitorPlatformGateway({
-      target,
-      appVersion: '1.0.0',
-      buildId: 'storage-conformance',
-      bridge: provider.bridge('primary-account', true) as NativeBridge,
-    }).storage;
-    isolated = createCapacitorPlatformGateway({
-      target,
-      appVersion: '1.0.0',
-      buildId: 'storage-conformance',
-      bridge: provider.bridge('isolated-account', false) as NativeBridge,
-    }).storage;
-  } else if (target === 'ait') {
-    ...
-  } else {
-    ...
-  }
+  const gatewayFactories = {
+    android: (bridge: unknown) =>
+      createCapacitorPlatformGateway({ target, appVersion: '1.0.0', buildId: 'storage-conformance', bridge: bridge as NativeBridge }),
+    ios: (bridge: unknown) =>
+      createCapacitorPlatformGateway({ target, appVersion: '1.0.0', buildId: 'storage-conformance', bridge: bridge as NativeBridge }),
+    ait: (bridge: unknown) =>
+      createAitPlatformGateway({ appVersion: '1.0.0', buildId: 'storage-conformance', bridge: bridge as GamePlatformBridge }),
+    reddit: (bridge: unknown) =>
+      createDevvitPlatformGateway({ appVersion: '1.0.0', buildId: 'storage-conformance', bridge: bridge as DevvitBridge }),
+  } as const;
+  primary = gatewayFactories[target](provider.bridge('primary-account', true)).storage;
+  isolated = gatewayFactories[target](provider.bridge('isolated-account', false)).storage;
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tools/smoke/storage-adapter-conformance.ts` around lines 90 - 135, Refactor
createBridgeFixture to use a target-to-platform factory or shared construction
helper instead of repeating primary and isolated gateway creation for each
target. Define the bridge provider and gateway configuration with the complete
platform-specific bridge types so provider.bridge results are type-safe without
force-casting to NativeBridge, GamePlatformBridge, or DevvitBridge. Preserve the
existing target mappings, account identifiers, isolation flags, gateway
metadata, and returned createFixture values.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@adapters/verse8/src/index.test.ts`:
- Around line 96-106: Restore the original globalThis.localStorage value after
the “fails closed when local storage is unavailable” test completes. Capture the
existing property before Reflect.deleteProperty, then restore it in cleanup
regardless of assertion success, preserving the test’s simulated-unavailable
behavior without leaking global state.

In `@apps/target-devvit/src/server/index.ts`:
- Line 283: Remove the key value from both storage failure warnings, leaving
only the failure context and error details. Apply this in
apps/target-devvit/src/server/index.ts at lines 283-283 and 350-350, and mirror
the sanitized load and save warnings in
packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts at
lines 285-285 and 352-352.

In
`@native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/CapacitorGameServicesPlugin.java`:
- Around line 215-225: Update the save handler surrounding localStorage().save
in the CapacitorGameServicesPlugin to catch unexpected native exceptions in
addition to LocalJsonStorage.StorageException, and resolve the bridge call
through the existing errorResponse path rather than allowing initialization
failures to escape. Preserve the current success response and
StorageException-specific code and retryability fields.

In
`@native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/LocalJsonStorage.swift`:
- Around line 92-94: The set method currently uses UserDefaults, which cannot
report persistence failures despite its throwing contract and
LocalJsonStorageError.saveFailed path. Update set and the corresponding storage
backend to use a write mechanism that surfaces errors, or remove the
throwing/save-failed contract consistently if failures are not supported.

In `@packages/platform/src/storage-conformance.ts`:
- Around line 205-211: Update the mutation probes around mutableLoadedValue so
the coins assignment and inventory push execute independently, each with its own
try/catch. Preserve the existing isolation read and immutable-value handling,
ensuring the inventory probe still runs when the progress mutation throws.

---

Nitpick comments:
In `@tools/smoke/storage-adapter-conformance.ts`:
- Around line 90-135: Refactor createBridgeFixture to use a target-to-platform
factory or shared construction helper instead of repeating primary and isolated
gateway creation for each target. Define the bridge provider and gateway
configuration with the complete platform-specific bridge types so
provider.bridge results are type-safe without force-casting to NativeBridge,
GamePlatformBridge, or DevvitBridge. Preserve the existing target mappings,
account identifiers, isolation flags, gateway metadata, and returned
createFixture values.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: bd05cd35-da4f-49dd-868d-9153586ef4b2

📥 Commits

Reviewing files that changed from the base of the PR and between e3fb909 and 928ebbf.

📒 Files selected for processing (28)
  • .github/workflows/ci.yml
  • .sampo/changesets/storage-adapter-conformance.md
  • adapters/browser/src/index.test.ts
  • adapters/browser/src/index.ts
  • adapters/devvit/src/index.test.ts
  • adapters/devvit/src/index.ts
  • adapters/verse8/src/index.test.ts
  • adapters/verse8/src/index.ts
  • apps/target-devvit/src/server/index.ts
  • docs/GAME_DEVELOPMENT.md
  • native-plugins/capacitor-game-services/README.md
  • native-plugins/capacitor-game-services/android/build.gradle
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/CapacitorGameServicesPlugin.java
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/LocalJsonStorage.java
  • native-plugins/capacitor-game-services/android/src/test/java/dev/mpgd/capacitor/LocalJsonStorageTest.java
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/CapacitorGameServicesPlugin.swift
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/LocalJsonStorage.swift
  • native-plugins/capacitor-game-services/ios/Tests/LocalJsonStorageConformance/main.swift
  • package.json
  • packages/cli/templates/phaser-game/README.md
  • packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts
  • packages/platform/package.json
  • packages/platform/src/index.ts
  • packages/platform/src/storage-conformance.test.ts
  • packages/platform/src/storage-conformance.ts
  • packages/platform/test/storage-conformance-dist-import.mjs
  • tools/smoke/platform-capability-conformance.ts
  • tools/smoke/storage-adapter-conformance.ts

Comment thread adapters/verse8/src/index.test.ts Resolved
Comment thread apps/target-devvit/src/server/index.ts Resolved
@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

Addressed the Codex stored-null finding in 5e8943b. Bridge-backed storage now returns an explicit { found: false } | { found: true, value } envelope and decodes it fail-closed, so a persisted top-level null is distinct from a missing key across Capacitor, Apps in Toss, and Devvit. The shared conformance runner and adapter/bridge tests now exercise the null round-trip.

@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the latest changes in #90, including the stored-null conformance update.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5e8943bdaa

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/bridge/src/index.ts Resolved
Comment thread apps/target-ait/src/aitBridge.ts Resolved
Comment thread adapters/devvit/src/index.ts Resolved
@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/CapacitorGameServicesPlugin.swift`:
- Around line 11-13: Update the CapacitorGameServicesPlugin localStorage
initialization to migrate existing values from the previous UserDefaults backend
into FileLocalJsonStorageBackend on first access. Read each legacy value, write
it to file storage, and remove the corresponding UserDefaults entry only after
the file write succeeds; preserve normal file-backed access after migration.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 08088e9e-8e6d-4405-8b37-c416639a0358

📥 Commits

Reviewing files that changed from the base of the PR and between 928ebbf and 5e8943b.

📒 Files selected for processing (21)
  • .sampo/changesets/storage-adapter-conformance.md
  • adapters/ait/src/index.test.ts
  • adapters/ait/src/index.ts
  • adapters/capacitor/src/index.test.ts
  • adapters/capacitor/src/index.ts
  • adapters/devvit/src/index.test.ts
  • adapters/devvit/src/index.ts
  • adapters/verse8/src/index.test.ts
  • apps/target-ait/src/aitBridge.ts
  • apps/target-ait/src/bridgeTypes.ts
  • apps/target-devvit/src/server/index.ts
  • native-plugins/capacitor-game-services/README.md
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/CapacitorGameServicesPlugin.java
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/CapacitorGameServicesPlugin.swift
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/LocalJsonStorage.swift
  • native-plugins/capacitor-game-services/ios/Tests/LocalJsonStorageConformance/main.swift
  • packages/bridge/src/bridge-protocol.test.ts
  • packages/bridge/src/index.ts
  • packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts
  • packages/platform/src/storage-conformance.ts
  • tools/smoke/storage-adapter-conformance.ts
🚧 Files skipped from review as they are similar to previous changes (11)
  • native-plugins/capacitor-game-services/README.md
  • .sampo/changesets/storage-adapter-conformance.md
  • adapters/verse8/src/index.test.ts
  • native-plugins/capacitor-game-services/ios/Tests/LocalJsonStorageConformance/main.swift
  • packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts
  • tools/smoke/storage-adapter-conformance.ts
  • apps/target-devvit/src/server/index.ts
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/CapacitorGameServicesPlugin.java
  • adapters/devvit/src/index.ts
  • packages/platform/src/storage-conformance.ts
  • adapters/devvit/src/index.test.ts

@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the latest changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@imjlk
imjlk force-pushed the codex/storage-adapter-conformance branch from f3a6807 to eacbe20 Compare July 16, 2026 13:32
@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the latest changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: eacbe20053

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/bridge/src/index.ts Resolved
Comment thread adapters/ait/src/index.ts Resolved
@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the latest changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d26c2fc7e2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/bridge/src/index.ts Resolved
@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the latest changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@apps/target-ait/src/aitBridge.test.ts`:
- Around line 118-199: Wrap the installed bridge test sequence after
installAitBridge() in a try...finally block, and move
Reflect.deleteProperty(bridgeHost, '__GAME_PLATFORM_BRIDGE__') into the finally
block to guarantee global cleanup on assertion or await failures. Replace the
firstLoad.ok equality assertion and manual failure branch with
assert(firstLoad.ok), and use direct firstLoad.data access in subsequent
assertions instead of conditional ternaries.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: ac79d7c1-9f45-46d8-a10e-00fa64937340

📥 Commits

Reviewing files that changed from the base of the PR and between 5e8943b and 59a094b.

📒 Files selected for processing (39)
  • .github/workflows/ci.yml
  • .sampo/changesets/storage-adapter-conformance.md
  • adapters/ait/src/index.test.ts
  • adapters/ait/src/index.ts
  • adapters/browser/src/index.test.ts
  • adapters/browser/src/index.ts
  • adapters/capacitor/src/index.test.ts
  • adapters/capacitor/src/index.ts
  • adapters/devvit/src/index.test.ts
  • adapters/devvit/src/index.ts
  • adapters/verse8/src/index.test.ts
  • adapters/verse8/src/index.ts
  • apps/target-ait/src/aitBridge.test.ts
  • apps/target-ait/src/aitBridge.ts
  • apps/target-ait/src/bridgeTypes.ts
  • apps/target-devvit/src/server/index.ts
  • docs/GAME_DEVELOPMENT.md
  • native-plugins/capacitor-game-services/README.md
  • native-plugins/capacitor-game-services/android/build.gradle
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/CapacitorGameServicesPlugin.java
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/LocalJsonStorage.java
  • native-plugins/capacitor-game-services/android/src/test/java/dev/mpgd/capacitor/LocalJsonStorageTest.java
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/CapacitorGameServicesPlugin.swift
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/LocalJsonStorage.swift
  • native-plugins/capacitor-game-services/ios/Tests/LocalJsonStorageConformance/main.swift
  • package.json
  • packages/bridge/src/bridge-protocol.test.ts
  • packages/bridge/src/cloudflare-pages.test.ts
  • packages/bridge/src/cloudflare-pages.ts
  • packages/bridge/src/index.ts
  • packages/cli/templates/phaser-game/README.md
  • packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts
  • packages/platform/package.json
  • packages/platform/src/index.ts
  • packages/platform/src/storage-conformance.test.ts
  • packages/platform/src/storage-conformance.ts
  • packages/platform/test/storage-conformance-dist-import.mjs
  • tools/smoke/platform-capability-conformance.ts
  • tools/smoke/storage-adapter-conformance.ts
🚧 Files skipped from review as they are similar to previous changes (26)
  • adapters/verse8/src/index.test.ts
  • native-plugins/capacitor-game-services/README.md
  • packages/platform/package.json
  • apps/target-ait/src/aitBridge.ts
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/LocalJsonStorage.swift
  • tools/smoke/platform-capability-conformance.ts
  • packages/platform/test/storage-conformance-dist-import.mjs
  • .sampo/changesets/storage-adapter-conformance.md
  • native-plugins/capacitor-game-services/android/src/test/java/dev/mpgd/capacitor/LocalJsonStorageTest.java
  • docs/GAME_DEVELOPMENT.md
  • adapters/browser/src/index.test.ts
  • .github/workflows/ci.yml
  • adapters/capacitor/src/index.ts
  • adapters/ait/src/index.ts
  • adapters/verse8/src/index.ts
  • packages/platform/src/storage-conformance.ts
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/LocalJsonStorage.java
  • adapters/browser/src/index.ts
  • packages/platform/src/storage-conformance.test.ts
  • native-plugins/capacitor-game-services/ios/Sources/CapacitorGameServices/CapacitorGameServicesPlugin.swift
  • package.json
  • packages/cli/templates/phaser-game/apps/target-devvit/src/server/index.ts
  • tools/smoke/storage-adapter-conformance.ts
  • adapters/devvit/src/index.ts
  • native-plugins/capacitor-game-services/android/src/main/java/dev/mpgd/capacitor/CapacitorGameServicesPlugin.java
  • adapters/devvit/src/index.test.ts

Comment thread apps/target-ait/src/aitBridge.test.ts Resolved
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep them coming!

Reviewed commit: 59a094b08f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@imjlk

imjlk commented Jul 16, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 16, 2026 •

Copy link
Copy Markdown

@imjlk I’ll review the latest changes in #90.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: 7b50e0218e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@imjlk
imjlk merged commit 204fe80 into main Jul 16, 2026
6 checks passed
@imjlk
imjlk deleted the codex/storage-adapter-conformance branch July 16, 2026 14:56
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