graph_matching icon indicating copy to clipboard operation
graph_matching copied to clipboard

circular require warning

Open martindemello opened this issue 2 years ago • 2 comments

I get a circular require warning when loading weighted_graph:

graph_matching-0.2.1/lib/graph_matching/algorithm/mwm_general.rb:3: warning: loading in progress, circular require considered harmful - graph_matching-0.2.1/lib/graph_matching/graph/weighted_graph.rb

The require in mwm_general seems to be solely for the check

        assert(graph).is_a(Graph::WeightedGraph)

so perhaps it could check for a sentinel method from Weighted instead.

martindemello avatar Jun 04 '23 03:06 martindemello

Hi Martin, Do you get this warning when running the test suite (bundle exec rspec)? If not, do you want to try reproducing this warning with a test, as a first step towards a PR?

jaredbeck avatar Jun 06 '23 00:06 jaredbeck

no, i just tried and i don't! i get it when running tests in my own project. i'll investigate further.

martindemello avatar Jun 06 '23 00:06 martindemello