t008.4: oh-my-opencode compatibility for aidevops-opencode plugin#1157
t008.4: oh-my-opencode compatibility for aidevops-opencode plugin#1157marcusquinn merged 2 commits intomainfrom
Conversation
Detect OMOC presence via OpenCode config, OMOC config files, and npm. Skip MCP registration for MCPs managed by OMOC (context7, websearch, grep_app). Quality hooks are complementary — aidevops handles ShellCheck/secrets/returns, OMOC handles comment-checker/todo-enforcer. No overlap. OMOC state injected into compaction context for session continuity. Stale OMOC tool patterns only disabled when OMOC is not active.
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ✨ Finishing touches🧪 Generate unit tests (beta)
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. Comment |
🔍 Code Quality Report�[0;35m[MONITOR]�[0m Code Review Monitoring Report �[0;34m[INFO]�[0m Latest Quality Status: �[0;34m[INFO]�[0m Recent monitoring activity: 📈 Current Quality Metrics
Generated on: Wed Feb 11 20:16:28 UTC 2026 Generated by AI DevOps Framework Code Review Monitoring |
Summary of ChangesHello @marcusquinn, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
🔍 Code Quality Report�[0;35m[MONITOR]�[0m Code Review Monitoring Report �[0;34m[INFO]�[0m Latest Quality Status: �[0;34m[INFO]�[0m Recent monitoring activity: 📈 Current Quality Metrics
Generated on: Wed Feb 11 20:17:34 UTC 2026 Generated by AI DevOps Framework Code Review Monitoring |
|
There was a problem hiding this comment.
Code Review
This pull request introduces compatibility with oh-my-opencode (OMOC) by detecting its presence and adjusting the plugin's behavior to avoid conflicts. The detection logic is multi-faceted, checking configuration files and npm status, which is a robust approach. The changes are well-documented in both the code and the architecture markdown file. I've identified a couple of areas for improvement in the detection logic to make it more resilient and to better align with the repository's style guide regarding error handling in shell commands. Overall, this is a solid contribution that improves interoperability within the OpenCode ecosystem.
|
|
||
| // 3. If not yet detected, check npm for OMOC installation | ||
| if (!_omocState.detected) { | ||
| const npmCheck = run("npm ls oh-my-opencode --json 2>/dev/null", 5000); |
There was a problem hiding this comment.
The use of 2>/dev/null here and on line 227 appears to violate the repository style guide (line 50), which states that blanket suppression should be avoided. The npm ls command is expected to fail with a non-zero exit code if the package is not found. It would be better to allow the run utility to handle this expected failure gracefully, perhaps with an option to ignore non-zero exit codes, rather than suppressing stderr at the command level.
References
- The style guide prohibits blanket error suppression with
2>/dev/null, allowing it only when redirecting to log files. (link)
| if (npmCheck && npmCheck.includes("oh-my-opencode")) { | ||
| _omocState.detected = true; | ||
| } |
There was a problem hiding this comment.
Checking for the package by using npmCheck.includes("oh-my-opencode") on the JSON output of npm ls is not robust. It could lead to false positives if another package has "oh-my-opencode" in its name or description. Since you're using the --json flag, it would be more reliable to parse the JSON output and check for the existence of oh-my-opencode as a dependency.
| if (npmCheck && npmCheck.includes("oh-my-opencode")) { | |
| _omocState.detected = true; | |
| } | |
| if (npmCheck) { | |
| try { | |
| const npmInfo = JSON.parse(npmCheck); | |
| if (npmInfo.dependencies?.['oh-my-opencode']) { | |
| _omocState.detected = true; | |
| } | |
| } catch { | |
| // Fallback for non-JSON output | |
| if (npmCheck.includes("oh-my-opencode")) { | |
| _omocState.detected = true; | |
| } | |
| } | |
| } |



Summary
Design
Detection strategy (ordered by reliability):
opencode.json) — looks for"oh-my-opencode"in thepluginarray.opencode/oh-my-opencode.json(project) or~/.config/opencode/oh-my-opencode.json(user)npm ls oh-my-opencodeResults are cached after first detection. When OMOC is detected, the plugin logs a summary and adapts its behaviour:
Dependencies
Builds on t008.1 (core plugin, PR #1138), t008.2 (MCP registry, PR #1149), t008.3 (quality hooks, PR #1150).
Testing
node --checksyntax validation passesRef #1097