reporters.py 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. class BaseReporter(object):
  2. """Delegate class to provider progress reporting for the resolver.
  3. """
  4. def starting(self):
  5. """Called before the resolution actually starts.
  6. """
  7. def starting_round(self, index):
  8. """Called before each round of resolution starts.
  9. The index is zero-based.
  10. """
  11. def ending_round(self, index, state):
  12. """Called before each round of resolution ends.
  13. This is NOT called if the resolution ends at this round. Use `ending`
  14. if you want to report finalization. The index is zero-based.
  15. """
  16. def ending(self, state):
  17. """Called before the resolution ends successfully.
  18. """
  19. def adding_requirement(self, requirement):
  20. """Called when the resolver adds a new requirement into the resolve criteria.
  21. """
  22. def backtracking(self, candidate):
  23. """Called when the resolver rejects a candidate during backtracking.
  24. """
  25. def pinning(self, candidate):
  26. """Called when adding a candidate to the potential solution.
  27. """