[go: up one dir, main page]

Skip to content

MergeWorker job may be run before squash parameter is saved

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

This came from #32185 (comment 220152835). Right now it's possible that the merge flag isn't committed to the database before MergeWorker runs:

https://gitlab.com/gitlab-org/gitlab/blob/6f1bf83acdb68dc7eb2d83ec59c53ed5069b6a8e/app/controllers/projects/merge_requests_controller.rb#L274-287 updates the squash column.

We could fix this by:

  1. Use run_after_commit if the squash parameter is updated
  2. We appear to pass the squash parameter in MergeWorker. We could use that value as well.
Edited by 🤖 GitLab Bot 🤖