Modify ↓
Ticket #192 (new defect)
ignore_aliases breaks with numy arrays
| Reported by: | barronh@… | Owned by: | xi |
|---|---|---|---|
| Priority: | normal | Component: | pyyaml |
| Severity: | normal | Keywords: | |
| Cc: |
Description
With all numpy arrays except type double, yaml crashes with error below:
TypeError?: data type not understood
steps to reproduce: python -c "import yaml; yaml.load(yaml.dump(arange(12, dtype = 'i')))"
steps to correct: patch yaml/representer.py using attached file
It appears that None and tuple or handled in a separate line from all other types. This can be avoided using the NoneType? from types.
Is there some other reason that these two are handled out of line?
By changing the implementation, numpy arrays of all types can be dumped.
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

