Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

some unicode attributes cannot be roundtripped #393

Open
dcherian opened this issue Nov 15, 2024 · 0 comments
Open

some unicode attributes cannot be roundtripped #393

dcherian opened this issue Nov 15, 2024 · 0 comments
Labels
bug 🐛 Something isn't working

Comments

@dcherian
Copy link
Contributor

key = '/0/zarr.json'
value = b'{\n  "shape": [\n    1\n  ],\n  "fill_value": false,\n  "chunk_grid": {\n    "name": "regular",\n    "configuration": {\n      "chunk_shape": [\n        1\n      ]\n    }\n  },\n  "attributes": {\n    "\\ud800": null\n  },\n  "zarr_format": 3,\n  "data_type": "bool",\n  "chunk_key_encoding": {\n    "name": "default",\n    "configuration": {\n      "separator": "/"\n    }\n  },\n  "codecs": [\n    {\n      "name": "bytes",\n      "configuration": {\n        "endian": "little"\n      }\n    }\n  ],\n  "node_type": "array"\n}'
await self._store.set(key, value)

ValueError: store error: bad metadata: `unexpected end of hex escape at line 15 column 12`

seem like an edge case with handling "attributes": {\n "\\ud800": null\n } but perhaps there's a real issue here around serializing this kind of thing.

Seen in #68

@dcherian dcherian added the bug 🐛 Something isn't working label Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant