Skip to content

GH#940: docs(agents): expand bash:other guidance for WP test suite, npm build, and PHP one-liners#941

Merged
superdav42 merged 1 commit intomainfrom
feature/auto-20260425-051518-gh940
Apr 25, 2026
Merged

GH#940: docs(agents): expand bash:other guidance for WP test suite, npm build, and PHP one-liners#941
superdav42 merged 1 commit intomainfrom
feature/auto-20260425-051518-gh940

Conversation

@superdav42
Copy link
Copy Markdown
Collaborator

@superdav42 superdav42 commented Apr 25, 2026

Summary

Follows up on PR #933 (GH#932) which added the bash:other section. Four new bash:other errors (+5) occurred since that fix — the most significant increase of the four tracked patterns:

  • bash:other (+5, 24→29): Three new failure modes not covered by existing guidance:

    1. vendor/bin/phpunit fails when WordPress test environment is not installed — agents attempt to run tests without the bootstrap from bin/install-wp-tests.sh.
    2. npm run build is a release command (runs encryption, minification) not a dev-testing shortcut — agents confuse it with npm run check.
    3. Bare php -r one-liners calling WordPress functions (add_filter, get_option, etc.) fail because WP is not bootstrapped in that context.
  • Other patterns unchanged or at ±1 (marginal): webfetch:other +1, read:file_not_found 0, edit:not_read_first +1.

Changes

AGENTS.md### Common bash:other Failures section only:

  • Added WordPress test suite not installed entry: failure message, bin/install-wp-tests.sh invocation example, and a pre-check command for /tmp/wordpress-tests-lib.
  • Added npm run build is a release command entry: explains it runs encryption/minification, and lists the correct dev alternatives (npm run check, npm run lint, npm test).
  • Added PHP functions unavailable in one-liners entry: explains WP functions require WP bootstrap; shows wp eval as the correct alternative.

Verification

Documentation-only change. No code modified. Guidance directly addresses the specific new bash:other failure classes observed.

Resolves #940


aidevops.sh v3.11.0 plugin for OpenCode v1.3.17 with claude-sonnet-4-6 spent 5m and 12,836 tokens on this as a headless worker.

Summary by CodeRabbit

  • Documentation
    • Expanded troubleshooting guidance for common WordPress development setup issues.
    • Clarified test suite requirements and installation steps for running unit tests.
    • Documented proper commands for development quality checks versus release builds.
    • Added guidance on executing WordPress functions from the command line with correct bootstrapping.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 25, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 4bb47899-2273-4dbd-a243-8ad817460233

📥 Commits

Reviewing files that changed from the base of the PR and between 97fd08b and 2a3060d.

📒 Files selected for processing (1)
  • AGENTS.md

📝 Walkthrough

Walkthrough

Expands AGENTS.md with WordPress-specific troubleshooting guidance, documenting phpunit test suite installation requirements, clarifying npm build as release-oriented, and explaining WordPress function invocation without proper bootstrap, recommending wp eval instead with examples.

Changes

Cohort / File(s) Summary
WordPress Troubleshooting Documentation
AGENTS.md
Adds multiple "Common bash:other Failures" sections addressing phpunit test suite installation, npm build command purpose, WordPress function invocation constraints, and recommended alternatives using wp eval with before/after examples.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Poem

🐰 A bunny hops through docs so fine,
WordPress woes in each new line,
Test suites, builds, and bootstrap care,
Now agents know what's hiding there! ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title accurately describes the main documentation expansion in AGENTS.md, covering the three specific areas addressed: WordPress test suite setup, npm build clarification, and PHP one-liners guidance.
Linked Issues check ✅ Passed The PR directly addresses the bash:other error pattern (29 occurrences) documented in issue #940 by providing targeted troubleshooting guidance for three common failure modes identified in real usage logs.
Out of Scope Changes check ✅ Passed All changes are documentation-only updates to AGENTS.md focused on expanding the 'Common bash:other Failures' section, directly aligned with issue #940 objectives.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/auto-20260425-051518-gh940

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Copy Markdown

🔨 Build Complete - Ready for Testing!

📦 Download Build Artifact (Recommended)

Download the zip build, upload to WordPress and test:

🌐 Test in WordPress Playground (Very Experimental)

Click the link below to instantly test this PR in your browser - no installation needed!
Playground support for multisite is very limitied, hopefully it will get better in the future.

🚀 Launch in Playground

Login credentials: admin / password

@github-actions
Copy link
Copy Markdown

Performance Test Results

Performance test results for 96e3659 are in 🛎️!

Note: the numbers in parentheses show the difference to the previous (baseline) test run. Differences below 2% or 0.5 in absolute values are not shown.

URL: /

Run DB Queries Memory Before Template Template WP Total LCP TTFB LCP - TTFB
0 41 37.79 MB 910.50 ms (+21.00 ms / +2% ) 168.50 ms (-8.00 ms / -5% ) 1158.50 ms (-35.00 ms / -3% ) 2250.00 ms 2153.65 ms 96.05 ms
1 56 49.03 MB 982.00 ms (-42.00 ms / -4% ) 152.50 ms 1132.00 ms (-44.00 ms / -4% ) 2180.00 ms (-58.00 ms / -3% ) 2095.50 ms (-49.20 ms / -2% ) 84.50 ms

@superdav42
Copy link
Copy Markdown
Collaborator Author

Merge Summary

Issue #940 — docs(agents): expand bash:other guidance for WP test suite, npm build, and PHP one-liners

Changes: Added 3 new entries to ### Common bash:other Failures in AGENTS.md:

  1. WP test suite not installed (bin/install-wp-tests.sh required before phpunit)
  2. npm run build is a release command, not a dev testing shortcut — use npm run check
  3. PHP functions unavailable in bare php -r one-liners — use wp eval instead

CI: All 10 checks passed (PHP 8.2-8.5, Cypress, Code Quality, PHP Lint, Build, WP Performance).


aidevops.sh v3.11.0 plugin for OpenCode v1.3.17 with claude-sonnet-4-6 spent 17m and 17,738 tokens on this as a headless worker.

@superdav42 superdav42 merged commit e4ecc70 into main Apr 25, 2026
11 checks passed
@superdav42 superdav42 deleted the feature/auto-20260425-051518-gh940 branch April 25, 2026 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Contributor insight: 4 recurring error pattern(s) from superdav42

1 participant