Missed Team ’24? Catch up on announcements here.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Trigger based on code insights in custom merge checks

Martin Kovacik
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
December 22, 2023

This is such a cool feature released before Christmas. I've spend already some time migrating our merge check logic to forge.

In our pipeline we run checks using source code analysis tools and uploading them via code insights. I'm trying to build logic, that would prevent merge in case there is a failed report. 

I realised that when a report is uploaded, the merge check is not re-evaluated. Similar situation is with associated build. When the build is re-run I can't find a way to re-evaluate the merge check automatically. 

Is there a way to intercept these events and trigger merge check code?

1 answer

Suggest an answer

Log in or Sign up to answer
2 votes
Jeroen De Raedt
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
December 27, 2023

Hi @Martin Kovacik

great to hear that you are already enjoying the new Checks feature! 

As it is still in beta, the feature set is still somewhat limited. This is why currently Checks are only triggered through an `on-code-pushed` or `on-merge` trigger.
From the sounds of it, you would want a type of trigger that would fire when reports are uploaded through code-insights? 

As a work around, you could declare your check to listen to the `on-merge` trigger. This Check could then query the uploaded reports and perform your validation upon them. This Check would then only be invoked during the PR merge process. Maybe this could be a valid work around until we build a more appropriate trigger type? 

Diogo Borges
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 14, 2024

A more appropriate option would be to allow any kind of `event` as a trigger for

TAGS
AUG Leaders

Atlassian Community Events