Problem Description
Since Graph().canonical_label(immutable=True) gives
TypeError: GenericGraph.canonical_label() got an unexpected keyword argument 'immutable'
one is forced to use an additional .copy() call like Graph().canonical_label().copy(immutable=True) to get an immutable canonical label of a given graph.
Proposed Solution
It will be more straightforward to have immutable= keyword argument supported by any function that creates and returns a new graph (like .canonical_copy()) to save on an extra call to .copy(immutable=True) when the returned graph is needed to be immutable.
Alternatives Considered
N/A
Additional Information
No response
Is there an existing issue for this?
Problem Description
Since
Graph().canonical_label(immutable=True)givesone is forced to use an additional
.copy()call likeGraph().canonical_label().copy(immutable=True)to get an immutable canonical label of a given graph.Proposed Solution
It will be more straightforward to have
immutable=keyword argument supported by any function that creates and returns a new graph (like.canonical_copy()) to save on an extra call to.copy(immutable=True)when the returned graph is needed to be immutable.Alternatives Considered
N/A
Additional Information
No response
Is there an existing issue for this?