A repository owner wants a workflow that detects overlapping file changes between Copilot-created pull requests before they enter review. The workflow should run on pull requests to main, read repository and pull request metadata, and upload a conflict report for maintainers. Which option completes the workflow?
name: detect-agent-overlap
on:
(Missing value 1):
branches:
- main
permissions:
contents: (Missing value 2)
pull-requests: read
issues: read
jobs:
overlap-report:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Generate overlap report
run: |
mkdir -p reports
node scripts/find-agent-overlap.js > reports/agent-overlap.md
- name: Upload overlap report
uses: (Missing value 3)
with:
name: agent-overlap-report
path: reports/agent-overlap.mdChoose an answer
Tap an option to check your answer.
Correct answer: Missing value 1 = pull_request Missing value 2 = read Missing value 3 = actions/upload-artifact@v4.
Why this is the answer
The workflow needs to run when a pull request is opened or updated, making pullrequest the correct trigger for Missing value 1. The workflow requires reading repository contents and pull request metadata, so contents: read and pull-requests: read are appropriate permissions for Missing value 2. issues: read is also needed to access pull request comments or other issue-related data. Finally, to store the generated report for later access by maintainers, the actions/upload-artifact@v4 action is used for Missing value 3. push is incorrect as it triggers on merges, not PRs. write permissions are not needed for this read-only analysis. actions/cache is for caching dependencies, not uploading reports. actions/download-artifact is for retrieving, not uploading. actions/upload-pages-artifact is for GitHub Pages deployments.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed