← Back to Pull requests

feat(mcp): add --enable-odooly to oa-mcp/oa-mcp-multi #25

Closed
unknown closed this pull request without merging on Aug 24, 2026 13:16 UTC
View on GitHub
unknown unknown commented on Aug 21, 2026 09:11 UTC
Author

Summary

Adds a --enable-odooly flag to oa-mcp / oa-mcp-multi, mirroring the
TUI's existing oa --enable-odooly. When set, three new MCP tools become
available:

  • list_odooly_envs — list every environment section in ~/odooly.ini

  • instance_odooly_env — resolve which odooly env serves a given

  • instance/db pair
  • odooly_run_script — run one of the packaged odooly scripts

  • (create_test_job, restore_app_icons, send_test_mail) against an env

    This is the one non-read-only exception in the MCP server: odooly logs in
    and can write to the matched database. Following the same launch-time-only
    pattern as --include-sensitive-information, the flag can only be set on
    the command line when the server starts — no tool call can enable it from
    within a session — and all three tools raise if --enable-odooly wasn't
    passed.

    odooly_run_script/instance_odooly_env always resolve locally against
    this machine's own ~/odooly.ini, regardless of host/ssh_port used to
    pin the server — odooly reaches instances over the network, not over ssh.

    send_test_mail sends one real email through mail.mail to check outbound
    mail actually reaches an inbox; it requires a to recipient, validated
    before the script is even invoked.

    Test plan

  • tests/test_mcp_server.py — new tests cover refusal when the flag is

  • off (test_odooly_tools_refuse_without_the_launch_time_flag),
    delegation to probes once enabled
    (test_odooly_tools_delegate_to_probes_once_enabled), and the
    send_test_mail recipient guard
    (test_send_test_mail_needs_a_recipient)
  • make check / make test
  • Diff: 205 lines (+153 / -52) across 2 files Reviewer: Kimkhoi3010 Review duration: 4564m
    All Vouch review confidence checks passed
    Residual risk 0.14 = Change Risk (0.36) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.36 · 205 lines diff across 2 files
    0.36
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.319
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #25"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 36.3% (MEDIUM) · Higher = larger blast radius
    36.3%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 14.3% · Safe to merge
    14.3%