Don't refresh change when enqueuing an dequeue event
We only fetch the change object in order to verify that it's a real change and to compare it to the queue item. We don't need to have up-to-date information about the change for that. On the enqueue side, we do have further use of the change object in that it is handed off to the pipeline manager for enqueing, so we should refresh the change, just as we do when processing trigger events. Change-Id: Ibe835d22945c8c42c37ad97baaf0500b5f809c5d
This commit is contained in:
parent
37b354a88c
commit
881b74d745
|
@ -981,7 +981,7 @@ class Scheduler(threading.Thread):
|
|||
(trusted, project) = tenant.getProject(event.project_name)
|
||||
if project is None:
|
||||
raise ValueError('Unknown project %s' % event.project_name)
|
||||
change = project.source.getChange(event, refresh=True)
|
||||
change = project.source.getChange(event)
|
||||
if change.project.name != project.name:
|
||||
if event.change:
|
||||
item = 'Change %s' % event.change
|
||||
|
|
Loading…
Reference in New Issue