Advice on handling scheduled event builds
See original GitHub issueHi @dorny,
We have a workflow containing multiple triggers:
- push events (to the default branch)
- pull requests (against the default branch)
- workflow dispatch (i.e. manually-triggered)
- scheduled events (i.e. cron)
Your paths-filter
action works great for the first three use-cases, detecting the context and base to compare against. However, it fails for scheduled events giving the error This action requires 'base' input to be configured or 'repository.default_branch' to be set in the event payload
.
Looking in your code at where the error is thrown, we could set a base
, but I’m not sure how to set that in a way that would work for the other triggers.
Any suggestions on how to handle this? For a scheduled build there is obviously no “base” to compare against as it’s just a specific commit that is used, but ideally it would fall-back and handle this situation without raising an error?
Thanks,
Joe.
Issue Analytics
- State:
- Created 2 years ago
- Comments:10 (3 by maintainers)
Top Results From Across the Web
Planning an Event Timeline: 4 Tips for Smooth Schedules
1. First schedule the non-negotiables · 2. Include your vendors' timing · 3. Iterate on your timeline draft, then do it again ·...
Read more >Employee Scheduling Tips | 10 Techniques To Build Better ...
We've compiled our own list of employee scheduling tips to help you determine what practices you should implement to build a better schedule...
Read more >How to Build Event Schedules that Make Sense for Vendors
Want to avoid annoyed vendors? Start here. Put yourself in his or her shoes. Say you're supposed to be on site to set...
Read more >How to Make an Event Schedule - Eventbrite Blog
This will tell you how long you have to fit in speaker sessions, networking, breakout sessions and so on. When you know your...
Read more >Project Schedules 101: Why You Need One and How to Make ...
Managing your project schedule, and all project assets, in a central location will help everyone have a single source of truth and ensure ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Sorry for the delay, I’ve been quite busy the last few months.
IMHO, there’s not much use for this action with scheduled events. At the same time, it should not stay in the way and complicate the workflow definitions more than necessary. So, I’ve come to the conclusion:
if
s. The most common usage of this action is for running tests, so running everything by default seems like a sensible default.base
is specified:This way it should support both behaviors that were proposed in this issue. I will make it part of the next release later this month or so. I haven’t gone through all the reported issues yet, so depends on what I will find there.
Hi @dorny - yep, agreed, I think the best thing is for this action to just consider everything as having changed for a scheduled event. If people want specific behaviour for scheduled events, they can always do that, but the main thing is just having it not cause an error on that event type.