Skip to content

Wrong constructor used in clear_edges()  #198

@tomcjackc

Description

@tomcjackc

On line 885 of hypergraph.py, the wrong constructor is used when resetting the nodes during the action of the clear_edges() method. The dict constructor ({}) is used when it should be the set constructor (set()). This means that an error is raised when trying to add edges back after clearing all edges.

Error raised: AttributeError: 'dict' object has no attribute 'add'

This can be rectified by replacing the {} with set() on line 885.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions