Skip to content

match up the interface with nx#6840 #1

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

Merged
merged 1 commit into from
Aug 25, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions graphblas_algorithms/interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,9 @@ def convert_from_nx(
node_attrs=None,
preserve_edge_attrs=None,
preserve_node_attrs=None,
preserve_graph_attrs=None,
name=None,
graph_name=None,
*,
weight=None, # For nx.__version__ <= 3.1
):
Expand All @@ -191,6 +193,10 @@ def convert_from_nx(
raise NotImplementedError("non-None `node_attrs` is not implemented")
if preserve_node_attrs:
raise NotImplementedError("`preserve_node_attrs=True` is not implemented")
if preserve_graph_attrs:
raise NotImplementedError("`preserve_graphs_attrs=True` is not implemented")
if graph_name:
raise NotImplementedError("Not possible to set a graph name")
Comment on lines +198 to +199
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

btw, this graph_name corresponds to the argument name in the networkx algorithm, which can be useful for debugging and logging. Also, graphblas_algorithms Graphs also support setting the name. Nevertheless, I'll merge this just to add you as a contributor ;)

if edge_attrs:
if len(edge_attrs) > 1:
raise NotImplementedError(
Expand Down