Skip to content

feat: add workflow hardening investigation workflow#712

Open
khaliqgant wants to merge 1 commit intomainfrom
feat/workflow-hardening
Open

feat: add workflow hardening investigation workflow#712
khaliqgant wants to merge 1 commit intomainfrom
feat/workflow-hardening

Conversation

@khaliqgant
Copy link
Copy Markdown
Member

@khaliqgant khaliqgant commented Apr 10, 2026

Summary

  • add a dedicated workflow-hardening investigation workflow
  • use Claude for planning/research and Codex for implementation/review
  • capture environment drift and active-checkout diagnostics up front
  • provide a structured way to separate workflow flaws, repo/tooling flaws, and environment-specific issues

Why

Recent real workflow runs exposed a mix of local-environment issues, workflow design flaws, and repo build/tooling assumptions. This PR adds a workflow specifically for diagnosing and hardening those classes of problems in a repeatable way.


Open with Devin

Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

View 4 additional findings in Devin Review.

Open in Devin Review

Comment on lines +104 to +113
command: `
set -e
if git diff --quiet; then
echo NO_CHANGES_DETECTED
exit 1
fi
git diff --stat
`,
captureOutput: true,
failOnError: true,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 verify-diff uses git diff --quiet which cannot detect new (untracked) files created by the implementer agent

The verify-diff step uses git diff --quiet to confirm the implementer made changes, but this command only compares tracked files in the working tree against the index. It exits 0 (no changes) when only new untracked files exist — confirmed by a live test. The implementer's task explicitly says "add/adjust files needed", making new-file-only output a likely scenario. When that happens, the step prints NO_CHANGES_DETECTED and exits 1, failing the workflow even though the agent did produce output. The same limitation applies to git diff --stat on line 111, meaning the review step would also receive an incomplete or empty diff summary. A more robust check would use git status --porcelain (which detects untracked files and staged changes) and git status --short for the summary passed to the reviewer. The existing add-swift-sdk.ts workflow at workflows/ci/add-swift-sdk.ts:513 already uses the more thorough git diff --quiet HEAD variant, though even that doesn't cover untracked files.

Suggested change
command: `
set -e
if git diff --quiet; then
echo NO_CHANGES_DETECTED
exit 1
fi
git diff --stat
`,
captureOutput: true,
failOnError: true,
command: `
set -e
if [ -z "$(git status --porcelain)" ]; then
echo NO_CHANGES_DETECTED
exit 1
fi
git diff --stat HEAD
echo 'Untracked files:'
git ls-files --others --exclude-standard
`,
Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant