flatbuffers icon indicating copy to clipboard operation
flatbuffers copied to clipboard

[Rust] [Flexbuffers] HashMap with `Option<&str>` keys returns `KeyMustBeString` error even if every key in the map is `Some`

Open Scripter17 opened this issue 1 year ago • 6 comments

fn main() {
    flexbuffers::to_vec::<std::collections::HashMap<Option<&str>, &str, std::collections::hash_map::RandomState>>(std::collections::HashMap::from_iter(vec![(Some("a"), "a")])).unwrap();
}

serde_json only returns an error when there's a None key.

Scripter17 avatar Sep 27 '24 07:09 Scripter17

Thanks for reporting! This was fixed in v3.0.0-beta.128, particularly in https://github.com/payloadcms/payload/pull/8364 The problem was that depth=0 was missing in the request that appears in packages/ui/src/elements/Status/index.tsx

GermanJablo avatar Nov 21 '24 16:11 GermanJablo

This issue has been automatically locked. Please open a new issue if this issue persists with any additional detail.

github-actions[bot] avatar Nov 23 '24 04:11 github-actions[bot]