# Plethora: Common Mistakes

Context version: plethora-agent-context-2026-10-22.1
SDK version: 1.8.0
Workflow version: 2026-10-30.1

**Fetch the current context first, every time.** At the start of every new Bit, and again right before every upload, fetch https://agent.plethora.studio/v1/agent/context.md and note its Version (also `contextVersion` in https://agent.plethora.studio/v1/agent/context.json). Do not build from an SDK, context, schema, template, skill or memory kept from an earlier chat or an earlier Bit: the contract changes, and Plethora only publishes full-screen Bits (`"display": "fullscreen"`). Send the version you built against as `agentFeedback.contextVersion`; an upload built against an older context is refused with 409 `context_outdated` and nothing is saved.

Public guidance. No pairing or token needed to read or build.

Check universal failures, then the subsystems you actually use. These are evidence-backed checks, not a fixed renderer or visual style. Historical platform bugs are not creator prohibitions: variables, tables, helpers, destructuring and supported wrapper patterns must not be banned because an old analyzer failed. Keep a minimal repro and report a current platform failure; do not force unnecessary source rewrites. See [existing-code.md](https://agent.plethora.studio/v1/agent/existing-code.md) for the complete conversion-specific rules.

## active-play-time
- **Symptom:** A puzzle timer includes hours away, or slower devices receive shorter completion times.
- **Cause:** Using Date.now()-savedStart or summing clamped simulation dt as competitive play time.
- **Correction:** Use ctx.game.stopwatch for active elapsed time, start/pause on actual gameplay boundaries, and persist elapsed snapshots. Keep calendar dates/countdowns separate. Old timestamps cannot reconstruct active durations: preserve old progress without awarding invented timed records.
- **Proof:** Pause for hours, reopen an acknowledged save, switch colour/menu, use slow frames and finish. Time away adds zero; foreground thinking counts.
- **Owner:** [sdk/game.md](https://agent.plethora.studio/v1/agent/sdk/game.md)

## mixed-challenge-boards
- **Symptom:** Different colours, difficulties or timing rules compete on one board.
- **Cause:** A shared record channel lacks distinguishing dimensions, or reads omit the submitted dimension.
- **Correction:** Declare dimensions or separate channels and use the same identity for submit/rank/leaderboard. For changed measurement semantics add a new channel and preserve old keys/epochs/scores. Metadata alone does not select a board or enforce a calendar edition.
- **Proof:** Complete each colour independently, inspect its matching board, preserve legacy rows and reject local stale-edition submits.
- **Owner:** [sdk/memory.md](https://agent.plethora.studio/v1/agent/sdk/memory.md)

## blank-ready
- **Symptom:** Blank first frame or a ready event with no useful content.
- **Cause:** Signaling readiness after setup rather than actual drawing.
- **Correction:** Paint meaningful content first; preserve errors and wire the first real input.
- **Proof:** Inspect rendered pixels and trigger actual input before claiming playability.
- **Owner:** [sdk/runtime.md](https://agent.plethora.studio/v1/agent/sdk/runtime.md)

## canvas-return
- **Symptom:** Drawing methods are missing or nothing is drawn.
- **Cause:** Treating ctx or the SDK canvas as the 2D painter.
- **Correction:** Use canvas = ctx.createCanvas2D(), then canvas.getContext("2d").
- **Proof:** Run init and verify visible drawing, not a mock return shape.
- **Owner:** [sdk/surfaces.md](https://agent.plethora.studio/v1/agent/sdk/surfaces.md)

## invented-api
- **Symptom:** Undefined method, invalid manifest or a nonexistent endpoint.
- **Cause:** Guessing familiar names instead of reading current interfaces.
- **Correction:** Read the complete SDK and schema; distinguish supported, legacy and unavailable features.
- **Proof:** Trace every authored call/field to its documented owner; exercise each path.
- **Owner:** [sdk.md](https://agent.plethora.studio/v1/agent/sdk.md)

## dependency-load
- **Symptom:** A library constructor/global is undefined.
- **Cause:** Use before await, wrong registry kind/export, guessed version or leaked global.
- **Correction:** Inspect exact registry pins/resources; await the right loader inside init and pass dependencies explicitly.
- **Proof:** Cold load and retry a real failure; verify the first frame and actual handler bindings.
- **Owner:** [sdk/libraries.md](https://agent.plethora.studio/v1/agent/sdk/libraries.md)

## dom-network
- **Symptom:** SecurityError or host content altered.
- **Cause:** Global DOM mounting, arbitrary networking, CDN fallback or script insertion.
- **Correction:** Use scoped DOM/surfaces and approved managed registry loads. Do not weaken the sandbox.
- **Proof:** Run the original authored source in the target runtime and preserve the actual diagnostic.
- **Owner:** [fundamentals.md](https://agent.plethora.studio/v1/agent/fundamentals.md)

## touch-trap
- **Symptom:** Scene looks alive but taps never reach it.
- **Cause:** Full-screen root/HUD/overlay intercepts input or all child controls are disabled.
- **Correction:** Set intentional surface input policy, preserve interactive children and close/skip controls.
- **Proof:** Use real hit-tested pointer events at visible coordinates, including the first tap and overlay dismissal.
- **Owner:** [sdk/surfaces.md](https://agent.plethora.studio/v1/agent/sdk/surfaces.md)

## dpr
- **Symptom:** Quarter-screen rendering/flash, zoomed corner, or displaced hit targets.
- **Cause:** CSS size and backing-store DPR/transform disagree.
- **Correction:** Choose one coordinate model consistently across draw, clear, FX and input; respect CSS-mode transforms.
- **Proof:** Check DPR 1/2/3, resize and full transition coverage using backing pixels and screenshots.
- **Owner:** [sdk/surfaces.md](https://agent.plethora.studio/v1/agent/sdk/surfaces.md)

## canvas-flags
- **Symptom:** A transparent layer disappears or composition differs on Android.
- **Cause:** Blanket alpha:false/desynchronized flags or inappropriate readback optimization.
- **Correction:** Use defaults first; alpha:false requires full painting, desynchronized is opt-in, willReadFrequently only for repeated local reads.
- **Proof:** Check layered canvas/WebGL on a real Android host as well as desktop.
- **Owner:** [sdk/surfaces.md](https://agent.plethora.studio/v1/agent/sdk/surfaces.md)

## control-boundary
- **Symptom:** Text sits under the camera cutout or island, buttons hide behind the logo or keyboard, or half the scene is unnecessarily empty.
- **Cause:** Fixed offsets instead of ctx.contentSafeArea ?? ctx.safeArea, a 0px bottom CSS fallback, or treating every lower pixel as prohibited.
- **Correction:** Lay out text and controls from ctx.contentSafeArea ?? ctx.safeArea (CSS: var(--plethora-content-safe-bottom, 120px)); move only obscured actionables/important cues; retain passive scenery edge to edge and compose layers deliberately.
- **Proof:** Check full screen on a notch, Dynamic Island and Android 3-button phone and in the safe frame (no contentSafeArea, safeArea.bottom 120), with the logo and keyboard visible; check button/content overlap.
- **Owner:** [fundamentals.md](https://agent.plethora.studio/v1/agent/fundamentals.md)

## time-loops
- **Symptom:** Speed changes by device/refresh rate or tapping; resume jumps.
- **Cause:** Per-frame movement, inconsistent ms/seconds, duplicate scheduling or unbounded resume dt.
- **Correction:** Use coherent time-based simulation and one deliberate scheduling owner per subsystem.
- **Proof:** Compare low/high cadence, input bursts, pause/resume and a second run.
- **Owner:** [sdk/game.md](https://agent.plethora.studio/v1/agent/sdk/game.md)

## async-lifetime
- **Symptom:** Old results alter a new run or disposed resources reappear.
- **Cause:** Late callbacks have no attempt/lifetime owner.
- **Correction:** Fence results by attempt and disposal; dispose late resources and avoid duplicate replay listeners.
- **Proof:** Delay success/failure across replay, close and reopen.
- **Owner:** [sdk/runtime.md](https://agent.plethora.studio/v1/agent/sdk/runtime.md)

## audio
- **Symptom:** Silent audio, swallowed playback failure or leaked sound.
- **Cause:** Missing gesture unlock/permission or unowned custom resources.
- **Correction:** Use actual readiness/error signals, deliberate gesture startup and cleanup. Host owns background suspension; report its failures rather than replacing it.
- **Proof:** Real Android/iOS tap, replay, mute, lock, background, foreground and disposal checks.
- **Owner:** [sdk/audio.md](https://agent.plethora.studio/v1/agent/sdk/audio.md)

## sensors
- **Symptom:** Motion/mic/camera fails or permission denial strands the player.
- **Cause:** Missing permission, unavailable native capability, bad units/calibration or no fallback.
- **Correction:** Declare/check permissions, use a real gesture, distinguish raw measurements from normalized controls and offer recovery.
- **Proof:** Phone test accepted/denied/unavailable paths; real physical movement/audio, not rising counters alone.
- **Owner:** [sdk/sensors.md](https://agent.plethora.studio/v1/agent/sdk/sensors.md)

## score-writes
- **Symptom:** Lag, request spam or replay waits for the server.
- **Cause:** Writing every frame/tap instead of meaningful results/checkpoints.
- **Correction:** Keep numeric score local; bounded checkpoints and detached, attempt-fenced result presentation.
- **Proof:** Count writes in a full run and rapidly replay while a request is delayed.
- **Owner:** [sdk/game.md](https://agent.plethora.studio/v1/agent/sdk/game.md)

## score-standing
- **Symptom:** queued is shown as accepted, stale rank, or guessed position.
- **Cause:** Confusing local state, host synchronization and committed leaderboard snapshots.
- **Correction:** Use explicit submit for acceptance and authoritative rank/board results. Handle null, pending, failure and cached Updating honestly.
- **Proof:** Test improvement/non-improvement, pending/failed writes, empty board and replay during completion.
- **Owner:** [sdk/memory.md](https://agent.plethora.studio/v1/agent/sdk/memory.md)

## device-only-persistence
- **Symptom:** BEST, unlocks or progress disappear after reinstall, or leak across account switch.
- **Cause:** Using ctx.storage as durable account state or assuming a record declaration restores an authored BEST display.
- **Correction:** In authenticated published app playback, read the existing all_time record standing for the exact channel/dimensions/order; use ctx.memory.local for cloud private state or ctx.game.progress for Continue Playing. This excludes draft preview and shared-web play: shared-web memory uses page-local simulation even for published Bits, not account-cloud persistence. A failed read must not cause a default/reset write. Never import unattributed legacy device values into competitive records.
- **Proof:** Clear device storage after acknowledged cloud saves, reopen on the same account, switch accounts and delay/fail hydration. Distinguish a missing accepted score from never-delivered local bytes; simulated success cannot prove an account save.
- **Owner:** [sdk/memory.md](https://agent.plethora.studio/v1/agent/sdk/memory.md)

## lost-score-delivery
- **Symptom:** A higher score never reaches the board, especially during continued play after a win.
- **Cause:** Only submitting the first win, swallowing rejection, or treating ctx.platform.setScore/queued:true as acceptance.
- **Correction:** Checkpoint already-valid best_per_user improvements at bounded milestones and submit the final valid result even after an earlier win. Keep pending/failed separate from accepted, fence async UI callbacks, and never use silent .catch(() => {}) as a save strategy.
- **Proof:** Test post-win improvement then game-over, offline/partial delivery, checkpoint failure, replay during pending work and reinstall before versus after acknowledgement. Count requests to rule out per-frame writes.
- **Owner:** [sdk/game.md](https://agent.plethora.studio/v1/agent/sdk/game.md)

## progress-identity
- **Symptom:** Lost resume/records or pass-and-play users share the wrong state.
- **Cause:** Confusing viewer progress/preferences with party identity, or changing published keys.
- **Correction:** Preserve record dimensions/keys and progress identity; version restore data and complete/abandon appropriately. Model local players explicitly.
- **Proof:** Reopen old saved state, test completion/abandon and keep existing records through the update.
- **Owner:** [sdk/game.md](https://agent.plethora.studio/v1/agent/sdk/game.md)

## shared-world
- **Symptom:** One creator overwrites others or writes are throttled.
- **Cause:** Whole-world replacement or unbounded per-frame mutations.
- **Correction:** Use documented semantic operations, channels, budgets and errors.
- **Proof:** Exercise concurrent updates, limits and failed writes without losing local feedback.
- **Owner:** [sdk/memory.md](https://agent.plethora.studio/v1/agent/sdk/memory.md)

## onboarding
- **Symptom:** Every Bit opens the same paragraphs or users still cannot play.
- **Cause:** Text cards substituted for teaching; no deliberate first-use decision.
- **Correction:** Use immersion, one cue or an interactive skippable example as appropriate. Bit-owned teaching uses immersive to avoid a second overlay.
- **Proof:** Watch an uncoached first use and Skip/replay; preserve intentional discovery.
- **Owner:** [sdk/onboarding.md](https://agent.plethora.studio/v1/agent/sdk/onboarding.md)

## puzzle-correctness
- **Symptom:** Only the stored solution is accepted, invalid boards win, or generators output trivial puzzles.
- **Cause:** Comparing arrays instead of validating rules, or not testing the generator distribution.
- **Correction:** Validate actual rules and alternate legal solutions; test solvability and meaningful complexity across seeds.
- **Proof:** Use valid alternate answers, invalid near-misses and representative generated boards; use an appropriate solver when justified.
- **Owner:** [creation.md](https://agent.plethora.studio/v1/agent/creation.md)

## generic-webgl-error
- **Symptom:** A generic failure says the device cannot do 3D.
- **Cause:** One catch relabels dependency, renderer and first-frame errors.
- **Correction:** Keep original error/stage via ctx.platform.error; recover explicitly and with bounds.
- **Proof:** Inject each failure separately; verify diagnostics and no automatic restart loop.
- **Owner:** [existing-code.md](https://agent.plethora.studio/v1/agent/existing-code.md)

## conversion-fidelity
- **Symptom:** Imported game loses controls, fog/materials, HUD alignment or visual identity.
- **Cause:** Rebuilding instead of adapting ownership; CSS/backing coordinates or imported globals changed.
- **Correction:** Preserve the original design and renderer, explicit dependencies/this binding, and compare key scenarios.
- **Proof:** Match original reference screenshots and first real input, resize, replay and cleanup.
- **Owner:** [existing-code.md](https://agent.plethora.studio/v1/agent/existing-code.md)

## json-upload
- **Symptom:** Broken JSON, wrong response key, duplicate drafts or unknown outcomes.
- **Cause:** Shell-escaped source, assumed envelopes or changing retry identity prematurely.
- **Correction:** Serialize files structurally; inspect exact envelopes; preserve request identity and reconcile before retrying.
- **Proof:** Parse payload locally, test a lost response, a 202 and corrected-payload retry following upload.md.
- **Owner:** [upload.md](https://agent.plethora.studio/v1/agent/upload.md)

## claiming-success
- **Symptom:** A 200/compile pass is called working or published.
- **Cause:** Transport acceptance is mistaken for behavior or creator consent.
- **Correction:** Distinguish saved, tested and published. Report real tests and gaps; creator opens Create -> Drafts.
- **Proof:** Verify correct saved draft identity and host interaction where access permits; label unavailable evidence.
- **Owner:** [upload.md](https://agent.plethora.studio/v1/agent/upload.md)

These checks complement, not replace, Step 7's source audit for new faulty/incomplete logic and actual execution. Fix within the creator's scope and repeat the affected checks.

Reading path: [Creation](https://agent.plethora.studio/v1/agent/creation.md) | [Fundamentals](https://agent.plethora.studio/v1/agent/fundamentals.md) | [Complete SDK](https://agent.plethora.studio/v1/agent/sdk.md) | [Verify and upload](https://agent.plethora.studio/v1/agent/upload.md).
