pygraphistry
pygraphistry copied to clipboard
[BUG] as_files consistency checking
When using as_files=True:
- should compare settings
- should check for use-after-delete
Additional scenario:
edges = pd.DataFrame({'s': ['a'], 'd': ['b']})
nodes = pd.DataFrame({'n': ['a', 'b']}
graphistry.nodes(nodes, 'n').edges(edges, 's', 'd').plot())
graphistry.nodes(nodes.rename(columns={'n': 'n2'}), 'n2').edges(edges, 's', 'd').plot()
=>
422 Client Error: for url: http://nginx/api/v2/upload/datasets/***/nodes/arrow
{"data":{"bindings":{"node":"n2","node_title":"n2"},"dataset_id":"***","error_message":"Node binding 'node' to a column named 'n2' that does not exist, is there a typo in the column name?"},"message":"Invalid nodes bindings","success":false}
Switching the last line to disable memoization makes it work:
graphistry.nodes(nodes.rename(columns={'n': 'n2'}), 'n2').edges(edges, 's', 'd').plot(memoize=False)