From d0fb18b6b0e205dfb0de99e590750fcd77662370 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Wed, 8 Jul 2009 22:02:17 +0000 Subject: [PATCH] Add a --debug warning message inside _add_pkg in case a potentially infinite backtracking loop is detected (it should never happen). svn path=/main/trunk/; revision=13808 --- pym/_emerge/depgraph.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 61edea2a8..6689f33e3 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -758,7 +758,19 @@ class depgraph(object): return 1 else: # A slot conflict has occurred. + # The existing node should not already be in + # runtime_pkg_mask, since that would trigger an + # infinite backtracking loop. if self._dynamic_config._allow_backtracking and \ + existing_node in \ + self._dynamic_config._runtime_pkg_mask: + if "--debug" in self._frozen_config.myopts: + writemsg( + "!!! backtracking loop detected: %s %s\n" % \ + (existing_node, + self._dynamic_config._runtime_pkg_mask[ + existing_node]), noiselevel=-1) + elif self._dynamic_config._allow_backtracking and \ not self._accept_blocker_conflicts(): self._add_slot_conflict(pkg) if dep.atom is not None and dep.parent is not None: -- 2.26.2