mirror of
https://pagure.io/fm-orchestrator.git
synced 2026-11-28 23:24:49 +08:00
Some debugging on the stop_condition.
This commit is contained in:
@@ -6,6 +6,9 @@ import moksha.hub
|
||||
import module_build_service.models
|
||||
import module_build_service.scheduler.consumer
|
||||
|
||||
import logging
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
||||
def main(initial_messages, stop_condition):
|
||||
""" Run the consumer until some condition is met.
|
||||
@@ -66,6 +69,8 @@ def make_simple_stop_condition(session):
|
||||
# XXX should this one be removed?
|
||||
module_build_service.models.BUILD_STATES["done"],
|
||||
)
|
||||
return module.state in done
|
||||
result = module.state in done
|
||||
log.debug("stop_condition checking %r, got %r" % (module, result))
|
||||
return result
|
||||
|
||||
return stop_condition
|
||||
|
||||
Reference in New Issue
Block a user