Skip to content

Fix nx.from_pandas_edgelist so edge keys are not added as edge attributes and edge keys - #7445

Merged
dschult merged 4 commits into
networkx:mainfrom
inbalh1:fix-for-issue-7444
May 15, 2024
Merged

dschult merged 4 commits into
networkx:mainfrom
inbalh1:fix-for-issue-7444

Conversation

@inbalh1

@inbalh1 inbalh1 commented May 13, 2024 •

Copy link
Copy Markdown
Contributor

Fixes #7444

inbalh1 added 2 commits May 13, 2024 11:17
	modified:   networkx/convert_matrix.py

@rossbar rossbar left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, thanks @inbalh1 ! Just one docstring formatting nit but the proposed solution looks good - clear, concise, and tested!

Comment thread networkx/convert_matrix.py Resolved
@dschult dschult changed the title Fix for issue 7444 Fix nx.from_pandas_edgelist so edge keys are not added as edge attributes and edge keys May 13, 2024
Co-authored-by: Ross Barnowski <[email protected]>
@inbalh1

inbalh1 commented May 14, 2024

Copy link
Copy Markdown
Contributor Author

Thanks @rossbar !

@dschult dschult left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I also have a tweak of the doc_string. And I agree that this is a good solution.
Thanks!!

Comment thread networkx/convert_matrix.py Resolved
Co-authored-by: Dan Schult <[email protected]>

@dschult dschult left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM! Thanks!

@dschult
dschult merged commit 0e7bbe5 into networkx:main May 15, 2024
@jarrodmillman jarrodmillman added this to the 3.4 milestone May 15, 2024
cvanelteren pushed a commit to cvanelteren/networkx that referenced this pull request May 22, 2024
…utes and edge keys (networkx#7445)

* Add edge_key to reserved_colomns

	modified:   networkx/convert_matrix.py

* add relevant test

* Fix docstring formatting

Co-authored-by: Ross Barnowski <[email protected]>

* Better docstring

Co-authored-by: Dan Schult <[email protected]>

---------

Co-authored-by: Ross Barnowski <[email protected]>
Co-authored-by: Dan Schult <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

keys added as edge attributes when using nx.from_pandas_edgelist

4 participants