[Bug]: Fix GitHub workflows errors for bot users
A pull request for this has already been merged.
- #20819 by @calixteman — merged
- Dominant language
- JavaScript
- Stars
- 53.9k
- Forks
- 10.7k
- Avg merge
- 18h 38m
- Merged PRs (30d)
- 130
Description
Attach (recommended) or Link to PDF file
N/A
Web browser and its version
Firefox 148.0
Operating system and its version
Arch Linux
PDF.js version
5.5.207 (and master)
Is the bug present in the latest PDF.js version?
Yes
Is a browser extension
No
Steps to reproduce the problem
If a bot user (Dependabot or the l10n update user) creates a PR the coverage tests fail to run as can be seen on e.g. https://github.com/mozilla/pdf.js/pull/20778. To merge such PRs we now have to bypass the checks, which is not what we want. It's unclear why this happens exactly, but we see this in the coverage workflow logs:
error - 2026-03-02 13:02:03,043 -- Upload failed: {"message":"Token required because branch is protected"}
What is the expected behavior?
The coverage workflows should pass, just like on regular users' PRs.
What went wrong?
The coverage workflows fail for bot users.
Link to a viewer
No response
Additional context
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the coverage workflow logs and the example bot-created PR #20778, comparing them with a regular user's PR. Trace why the protected branch requires a token for Dependabot and l10n update users. Done means the coverage workflows pass for bot-created PRs without bypassing checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, javascript
- Domain
- ci-cd, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100