-
Notifications
You must be signed in to change notification settings - Fork 15
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
Flattening a list of lists #398
Comments
Yes, it looks like we lack support for flattening of lists of lists. Here's a TODO in the code https://github.com/OpenDataServices/flatten-tool/blob/main/flattentool/json_input.py#L422 ! It should be fairly easy to implement this, to produce a cell with the contents |
Thanks, @Bjwebb. I was expecting something like We've yet to decide whether we're going to use Flatten Tool for Open Fibre (see Open-Telecoms-Data/open-fibre-data-standard#14) so no need to implement this yet. |
For info, my suggestion is based on what we already support for unflattening (which I think requires a schema). |
@Bjwebb we've decided to use Flatten Tool for the Open Fibre alpha, would you have time to implement this before you go on leave? |
I've made a PR for this #401 |
Closing as the PR is merged. |
I'm trying to flatten this file using the following command:
flatten-tool flatten -f xlsx example.json
. However, the resulting xlsx file is empty.Flattening the nodes list with
flatten-tool flatten -f xlsx --root-list-path nodes example.json
works OK. However, flattening the links list withflatten-tool flatten -f xlsx --root-list-path links example.json
returns an error: 'list' object has no attribute 'items'.I think this is because
links.location.geometry.coordinates
is a list of lists (the list in the actual file is longer):The text was updated successfully, but these errors were encountered: