TypeError: Type is not JSON serializable: `numpy.ndarray`/`recarray`
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
Research direction
Start with the cratedb-orjson.py reproduction linked in the issue and inspect how crate-python handles decoded payloads containing numpy.ndarray or recarray values. Confirm the failure with array/list data read through pandas or Polars; done means those payloads serialize without the reported TypeError.
Written by the indexing model from the issue text.
Description
Problem
We probed JSON serialization with crate-python and discovered it does not work well in all situations yet, for example when the data payload includes an array/list, and is read from JSON using pandas or Polars.
{"foo":"bar","baz":["qux"]}
The reason is that the decoded payload includes numpy.ndarray or recarray types.
Reproduce
cratedb-orjson.py can be used to reproduce the problem.
References
- Dominant language
- Python
- Stars
- 85
- Forks
- 34
- Avg merge
- 3d 1h
- Merged PRs (30d)
- 4
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from crate/crate-python
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
crate/crate-python#794 · 2 comments ·
-
enhancement
crate/crate-python#833 · 1 assignee ·
-
bug
Difficulty 4/5 3-5 days Newbie friendliness 52/100
crate/crate-python#826 ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
crate/crate-python#820 · 1 comment ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
crate/crate-python#751 · 7 comments ·
All issues in crate/crate-python
Similar issues
-
Add: hunch Open
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
AbdelStark/awesome-typesafe#104 ·
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
DiamondLightSource/dodal#2211 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
openml/openml-python#1749 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
sipyourdrink-ltd/bernstein#6191 ·