Repository navigation
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Payload::deserializerejects Serde's default externally tagged representation for enum variants carrying data. For example, a payload field containing{"Newtype": 32}fails withinvalid type: map, expected enum ..., even though the correspondingserde_json::Valuedeserializes successfully.This change routes a single-entry object through
EnumAccessand carries its associatedValueintoVariantAccess. It supports newtype, tuple, struct, and object-form unit variants while preserving string-form unit variants. Empty and multi-entry variant objects remain errors.Only the handwritten
src/serde_deser.rschanges. There are no public signature, generated protobuf, dependency, or lint-policy changes.Tests
Identical tests were run against dev
03a01faa905313cb1efb567af0dd7dd24c5a9b2cwith unchanged production code and against the patch, using separate build directories:cargo test --offline --locked --jobs 2 --lib serde_deser --all-features: BASE 12 passed / 6 failed; PATCH 18 passed. The six failures reproduce the enum defect.serde_json::from_valuecomparisons for newtype, tuple, struct, unit, optional-newtype, and malformed representations.cargo clippy --offline --locked --jobs 2 --workspace --all-targets --all-features -- -D warnings: passed.cargo fmt --all -- --check: passed with stable Rust 1.97 and the scoped nightly-2026-10-22 formatter. The stable formatter emits the existing warnings about nightly-only formatting options; the nightly check also passes.Dependencies were fetched separately and pinned in a local generated
Cargo.lock, which remains uncommitted as required for this library.A broader
cargo test --offline --locked --jobs 2 --lib --all-features -- --skip tests::test_qdrant_queriesrun yielded BASE 33 passed / 8 failed and PATCH 39 passed / 2 failed. The two remaining failures are the same existing collection/query tests attempting TCP to localhost:6334 in the network-denied environment. This is not a fully green integration-suite claim. Live Qdrant integration tests were not run locally.Checklist
dev.AI disclosure
Claude Code prepared the production proposal and initial regression. Codex independently reproduced the failure, added reference-based edge tests, verified the patch, and handled submission.