Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e2da5136af
ℹ️ 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".
| serde_json::from_slice(&plaintext).map_err(|_| { | ||
| let raw = String::from_utf8_lossy(&plaintext); | ||
| Error::BridgeError(format!( | ||
| "World App returned an unrecognized response. This may indicate a version mismatch. Raw response: {raw}" | ||
| )) |
There was a problem hiding this comment.
Classify unparseable bridge payloads as unexpected responses
This change maps JSON decode failures to Error::BridgeError, which downstream is treated as AppError::ConnectionFailed and a retryable NetworkingError (to_app_error/is_networking_error). For malformed or version-mismatched decrypted payloads, clients now mis-handle a protocol/format problem as a transport failure, which can trigger unnecessary retry loops and hide the real failure class. Keep the richer message if needed, but return an UnexpectedResponse/JSON-class error instead of BridgeError.
Useful? React with 👍 / 👎.
This PR: