Conversation
|
…dded-after-construction
…dded-after-construction
abussy-pasqal
left a comment
Member
There was a problem hiding this comment.
If I understand, data was duplicated between the inherited nx.Graph and internal dicts. And both were not syncronized correctly. So this PR removes the latter ?
Collaborator
Author
Correct! It removes the internal duplicated (but not updated) dicts. |
abussy-pasqal
approved these changes
Aug 13, 2026
sgrava
deleted the
sg/431-edge_weights-does-not-reflect-edges-added-after-construction
branch
August 13, 2026 11:44
This was referenced Aug 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix bug #431, where graph's weights were going out of sync when added after the creation of a graph.
Main fix is computing node coordinates and node/edge weights on the fly.
Changes
_rested_dict()method and all its calls_coords,_node_weights, _edge_weights``DataGraphmethodscoords,node_weightsandedge_weightsnow extract the attributes directly from the graph rather then relying on the internal dicts of point 2.Additional Changes
BaseGraphandDataGraph.