You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I believe this is similar to #7, in that it is related to the text of column names, or in this case the key names in JSON. If they have ".." in the name of the key, like "name..date_range": then I get an error like:
Taggerty:prov-api-harvester mwalker$ uv run --with csv-diff csv-diff --format=json --key=citation "a.json" "b.json"
Traceback (most recent call last):
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/bin/csv-diff", line 10, in <module>
sys.exit(cli())
~~~^^
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/lib/python3.13/site-packages/click/core.py", line 1157, in __call__
return self.main(*args, **kwargs)
~~~~~~~~~^^^^^^^^^^^^^^^^^
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/lib/python3.13/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/lib/python3.13/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/lib/python3.13/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/lib/python3.13/site-packages/csv_diff/cli.py", line 76, in cli
diff = compare(previous_data, current_data, show_unchanged)
File "/Users/mwalker/.cache/uv/archive-v0/PsALVJ9vZC43tN78TBpb-/lib/python3.13/site-packages/csv_diff/__init__.py", line 98, in compare
for _, field, (prev_value, current_value) in diffs
^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: not enough values to unpack (expected 2, got 1)
Sample JSON files:
a.json
[
{
"_id": "F6E388C2-F1A7-11E9-AE98-B368FE166A06",
"category": "Agency",
"citation": "VA 421",
"name.date_range": null,
"name.aka.date_range": null,
"name.official_title.date_range": "[1979 TO 1992]",
"status": "Published",
"timestamp": 1614747820,
"title": "Ministry for Police and Emergency Services"
}
]
b.json
[
{
"_id": "F6E388C2-F1A7-11E9-AE98-B368FE166A06",
"category": "Agency",
"citation": "VA 421",
"name..date_range": null,
"name.aka.date_range": null,
"name.official_title.date_range": "[1979 TO 1993]",
"status": "Published",
"timestamp": 1614787820,
"title": "Ministry for Police and Emergency Services"
}
]
My quick attempts to resolve it so far have not been successful. Thanks for a great tool!
The text was updated successfully, but these errors were encountered:
I believe this is similar to #7, in that it is related to the text of column names, or in this case the key names in JSON. If they have ".." in the name of the key, like
"name..date_range":
then I get an error like:Sample JSON files:
a.json
b.json
My quick attempts to resolve it so far have not been successful. Thanks for a great tool!
The text was updated successfully, but these errors were encountered: