Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent debug UI action from showing up in forked OTP projects #6402

Open
wants to merge 1 commit into
base: dev-2.x
Choose a base branch
from

Conversation

t2gran
Copy link
Member

@t2gran t2gran commented Jan 22, 2025

Summary

This action is run today in entur downstream fork when someone changes a file under /client/**. The action is aborted, but it clutter up the list of run actions. I am not an expert on workflows, but I chaned it slightly so the trigger now filter on both path and branch for pushes. This also make the script a bit cleaner, since the branch filter does not need to be repeated in the run section.

Issue

🟥 There is no issue for this.

Unit tests

🟥 This is CI config change, we do not have tests for this.

Documentation

🟥 I have not changed/added doc.

Changelog

🟥 Not relevant

Bumping the serialization version id

🟥 There is no changes to the OTP code.

@t2gran t2gran added this to the 2.7 (next release) milestone Jan 22, 2025
@t2gran t2gran requested a review from a team as a code owner January 22, 2025 15:05
Copy link

codecov bot commented Jan 22, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 69.73%. Comparing base (5ab75af) to head (494d80a).

Additional details and impacted files
@@            Coverage Diff             @@
##             dev-2.x    #6402   +/-   ##
==========================================
  Coverage      69.73%   69.73%           
+ Complexity     18023    18021    -2     
==========================================
  Files           2057     2057           
  Lines          76978    76978           
  Branches        7845     7845           
==========================================
  Hits           53678    53678           
  Misses         20550    20550           
  Partials        2750     2750           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@leonardehrenfried leonardehrenfried changed the title Prevent this action from showing up in forked OTP projects Prevent debug UI action from showing up in forked OTP projects Jan 24, 2025
Copy link
Member

@optionsome optionsome left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The title is slightly misleading as this only prevents the workflow being run in a fork if the fork doesn't use the same branch naming convention as upstream. Unfortunately I don't think there is a way to define on which repositories the action should run on (apart from the repository owner check that we already do here but with that solution the workflow still starts but is then aborted).

@@ -2,6 +2,8 @@ name: Debug client

on:
push:
branches:
- dev-2.x
paths:
- 'client/**'
pull_request:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could add the same branch restriction here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants