-
Notifications
You must be signed in to change notification settings - Fork 41
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
Issues with most recent format from kart diff #487
Comments
Thanks for the issue. To clarify are you referring to the GeoJSON diff output? |
triageI can confirm the bug 0.10.0: works fine, output to directory The bad codepath seems to be this line: kart/kart/json_diff_writers.py Line 268 in dfb0662
Where, if the directory doesn't exist, the additional bugIn addition, if I create the directory beforehand I get this traceback instead:
Fixing that might be the first thing, since at least then we would have a workaround (create the directory first) patch fix proposalSince this is a regression in 0.10.x I think the right fix for the next 0.10.x release would be to change it to assume directory output always, and only use single-file mode when the output is going to stdout. That latter case isn't a regression since 0.10.0 and earlier refused to do geojson diff output at all when multiple datasets were present and no directory was specified:
longer term fix proposalI think probably to avoid ambiguity, maybe we should split the some options:
|
alternatively, just remove the single-file modelooks like the issue was introduced in bf73da7 - as part of refactoring the diff output code, I think it's probably not terribly useful though. Perhaps we could just remove it again. We could change
|
I was hoping to work on this today but had a lot of other stuff on and so it will be tomorrow at the earliest I think just removing the single-file mode is the best solution, since it fixes the issue, keeps everything simple and removes an unnecessary feature. I also think |
Yes, That's the problem that I am seeing. One thing to note is that I only see the issue in 0.10.4. Reverting to kart 10.2 fixes it and the output is correct. So not exactly what you mention, but I guess it's the same issue |
If there's no useful way for multiple datasets to co-exist in the same file then this seems like a reasonable approach.
We shouldn't have features that only work sometimes, so I'm -1 on this. |
Looks like diff output format has changed in the latest release. Before, if several layers had changes, the output could be sent to a folder, and kart created several files, one for each layer, with the corresponding changes. Now all changes are written to a single file, with no information about the layer that each feature belongs to. It can maybe be figured out from the attributes schema, but that adds complexity to the workflow, and there can be cases where it not possible to do it (several layers might have the same schema, or the user might be looking at an older diff where the layer had a different schema to its most recent one...)
Would it be possible to add an additional property somewhere in the feature definition, so it can be used to separate the affected features into groups, depending on the layer they belong to?
The text was updated successfully, but these errors were encountered: