elastic / elastic/ai-github-actions

Reduce PR Buildkite Detective comment spam with marker-based upsert

Open
#1,358 0 comments 0 reactions 0 assignees View on GitHub
agentic-workflows
Dominant language
Python
Stars
11
Forks
16
Avg merge
22h 9m
Merged PRs (30d)
31

Description

> [!CAUTION]
> Protected files were modified in this change.
> This pull request is in `request_review` mode and requires explicit human scrutiny before merge.
>
> Protected files: `README.md`, `.github/workflows/trigger-estc-pr-buildkite-detective.yml`, `.github/workflows/gh-aw-estc-pr-buildkite-detective.lock.yml`, `.github/workflows/gh-aw-estc-pr-buildkite-detective.md`

Resolves merge conflicts by merging `main` (Remove COPILOT_GITHUB_TOKEN secret requirement #1336) into this PR branch.

**Conflict resolution:**
- The `.md` source auto-merged correctly, preserving all PR features (marker-based upsert, `reply_to_id`, `gh-aw-detective` HTML marker) while incorporating main's changes (`COPILOT_GITHUB_TOKEN` removed, `copilot-requests: write` added)
- The `.lock.yml` conflict was resolved by recompiling from the merged `.md` source

All lock files verified clean after `make compile`.

---
[What is this?](https://ela.st/github-ai-tools) | [From workflow: Mention in Issue (no sandbox)](https://github.com/elastic/ai-github-actions/actions/runs/27942881470)

Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.

---

> [!NOTE]
> This was originally intended as a pull request, but the git push operation failed.
>
> **Workflow Run:** [View run details and download bundle artifact](https://github.com/elastic/ai-github-actions/actions/runs/27942881470)
>
> The bundle file is available in the `agent` artifact in the workflow run linked above.

To create a pull request with the changes:

```sh
# Download the artifact from the workflow run
gh run download 27942881470 -n agent -D /tmp/agent-27942881470

# Fetch the bundle into a temporary ref, then update the local branch
git fetch /tmp/agent-27942881470/aw-copilot-reduce-comment-spamming.bundle refs/heads/copilot/reduce-comment-spamming:refs/bundles/create-pr-copilot-reduce-comment-spamming-6d0674bac7604155-72587c90
git update-ref refs/heads/copilot/reduce-comment-spamming-6d0674bac7604155 refs/bundles/create-pr-copilot-reduce-comment-spamming-6d0674bac7604155-72587c90
git checkout copilot/reduce-comment-spamming-6d0674bac7604155
# Ensure the working tree matches the updated branch
git reset --hard
# Remove the temporary bundle ref
git update-ref -d refs/bundles/create-pr-copilot-reduce-comment-spamming-6d0674bac7604155-72587c90

# Push the branch to origin
git push origin copilot/reduce-comment-spamming-6d0674bac7604155

# Create the pull request
gh pr create --title 'Reduce PR Buildkite Detective comment spam with marker-based upsert' --base main --head copilot/reduce-comment-spamming-6d0674bac7604155 --repo elastic/ai-github-actions
```

Contributor guide

Open the contributing guide

Research direction

Start with .github/workflows/gh-aw-estc-pr-buildkite-detective.md and compare its compiled .lock.yml counterpart, then review the conflict-resolution changes from main. Run make compile to verify the lock file remains clean; the work is done when the Buildkite Detective workflow uses the marker-based upsert behavior described in the title without producing duplicate comments.

Written by the indexing model from the issue text.

Assessment

Tech stack
git, github-actions
Domain
ci-cd
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.