Currently,
I'm able to create 2 stacks for the same repo & branch.
If Merge-Queue is enabled on both, they can interfere with each other.
Suggestion:
Merge-Queue can be enabled only once for a given set of Repo & Branch, regardless of the stack environment.
module Shipit
class Stack < Record
module NoDeployedCommit
...
validates :merge_queue_enabled, uniqueness: {
scope: %i(repository branch),
message: 'cannot be used more than once with this repository and branch. Check (archived) stacks.'
}
...
For backward compatibility, I can add a flag that indicates if this validation should be enforced.
The flag can be added to the repository module: "Single CI per branch".
Currently, I'm able to create 2 stacks for the same repo & branch. If Merge-Queue is enabled on both, they can interfere with each other.
Suggestion: Merge-Queue can be enabled only once for a given set of Repo & Branch, regardless of the stack environment.