Opened 5 years ago

Last modified 5 years ago

#18045 closed defect

Wrong result returned by is_planar on a given embedding — at Version 2

Reported by: ncohen Owned by:
Priority: major Milestone: sage-6.6
Component: graph theory Keywords:
Cc: Merged in:
Authors: Nathann Cohen Reviewers:
Report Upstream: N/A Work issues:
Branch: public/18045 (Commits) Commit:
Dependencies: Stopgaps:

Description (last modified by ncohen)

As reported on AskSage [1], the function .is_planar can return wrong results when given a specific embedding to run its computations on.

This actually comes from a mistake in a if/else and variable types, as bool(a_dictionary) returns True when the dictionary is nonempty. The original authors did not seem to be aware of that, and once fixed the code does not make the mistake again.

The problem was that the computations were run on the cached embedding (i.e _embedding) instead of the one provided by the user.



Change History (2)

comment:1 Changed 5 years ago by ncohen

  • Branch set to public/18045
  • Description modified (diff)
  • Status changed from new to needs_review

comment:2 Changed 5 years ago by ncohen

  • Description modified (diff)
Note: See TracTickets for help on using tickets.