fix: silently skip repos without digger config for org-wide installation #2488
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Fixes the issue where Digger posts error comments to PRs in repositories without
digger.ymlconfiguration files when the GitHub App is installed org-wide.Changes:
handlePullRequestEvent(lines 141-149) to detect missing config file errorsdigger.ymlordigger.yamlis not found, Digger now logs the skip and returns earlyBehaviour:
digger.yml- continue to work normallydigger.yml- silently skipped (no error comments posted)digger.yml- still get error comments (as expected)Industry Standard Pattern:
This config-file-based activation pattern is used by many popular GitHub Apps when installed org-wide:
renovate.jsonor.github/renovate.json.github/dependabot.yml.github/workflows/*.ymlfiles.pre-commit-config.yamlAll of these tools silently skip repos without their config files rather than posting error messages, which is the expected behavior for org-wide installations.
Testing
Unit Tests:
🧠 Ai UsageDetails (if applicable):
This PR was written primarily by Claude (Roo Code mode). The solution was:
The human contributor understands the changes and can answer questions about:
handlePullRequestEventChecklist
developRelated
Addresses the requirement for org-wide GitHub App installation without impacting existing repos, as discussed in the task description.