codex icon indicating copy to clipboard operation
codex copied to clipboard

GitHub connector: inconsistent repository parameter name causes misleading schema error

Open bbk1ng opened this issue 3 months ago • 1 comments

What issue are you seeing?

The GitHub connector exposes inconsistent names for the same repository identifier across sibling tools.

For example, fetch_issue_comments requires repo_full_name, while many other GitHub tools (including create_issue) require repository_full_name. This makes a plausible model-generated call fail before reaching GitHub.

The resulting validation error also includes a workspace-admin message, even though the failure is only an input-field mismatch:

Parameters failed connector schema validation: repo_full_name [required]:
Missing required property (does not match constraints configured by your ChatGPT
workspace admin. If the issue persists, instruct the user to contact their
workspace admin.); repo_full_name [required]: Missing required property

What steps can reproduce the bug?

Call the GitHub connector using the naming convention exposed by many sibling tools:

{
  "repository_full_name": "OWNER/REPO",
  "issue_number": 123
}

Tool:

codex_apps.github.fetch_issue_comments

The call fails schema validation because repo_full_name is required.

Retry with:

{
  "repo_full_name": "OWNER/REPO",
  "issue_number": 123
}

The call succeeds.

What is the expected behavior?

Use one repository-field name consistently across GitHub connector tools, preferably repository_full_name, or accept both forms as compatibility aliases.

For a plain schema mismatch, the error should identify the unexpected/missing field without suggesting workspace-admin intervention.

Additional information

Observed with the OpenAI GitHub plugin version 0.1.8-2841cf9749ae.

This is not an authentication, repository-access, or workspace-policy failure: changing only the parameter name makes the same read-only request succeed.

bbk1ng avatar Aug 12 '26 21:08 bbk1ng

Still reproducing on codex-cli 0.171.0 (gpt-6.2-sol, OpenAI GitHub plugin 0.1.13-77c10e110b37, Linux x86_64) across GitHub connector write tools, in both directions.

This happens even after the model inspects ALL_TOOLS in Code Mode and reads the full TypeScript declaration for the target tool. Switching between adjacent sibling tools still leads to swapping the repository parameter name:

  1. After calling mcp__codex_apps__github_add_comment_to_issue with repo_full_name, calling mcp__codex_apps__github_update_issue with repo_full_name fails:
await tools.mcp__codex_apps__github_update_issue({
  repo_full_name: "OWNER/REPO",
  issue_number: 123,
  state: "closed",
  state_reason: "completed"
});

Error:

{
  "error": "Parameters failed connector schema validation: repository_full_name [required]: Missing required property; repository_full_name [required]: Missing required property",
  "error_code": "INVALID_ARGUMENT",
  "error_data": {
    "reason": "INVALID_PARAMETERS",
    "clamp_errors": [
      {"path": ["repository_full_name"], "message": "Missing required property", "keyword": "required"},
      {"path": ["repository_full_name"], "message": "Missing required property", "keyword": "required"}
    ],
    "clamp_rewrites": []
  }
}

Retrying with repository_full_name succeeds. The same failure also occurs on mcp__codex_apps__github_update_pull_request.

  1. In the reverse direction, after using repository_full_name on sibling tools (such as mcp__codex_apps__github_create_pull_request or mcp__codex_apps__github_update_issue), calling mcp__codex_apps__github_add_comment_to_issue with repository_full_name fails:
await tools.mcp__codex_apps__github_add_comment_to_issue({
  repository_full_name: "OWNER/REPO",
  pr_number: 123,
  comment: "Example comment"
});

Error:

{
  "error": "Parameters failed connector schema validation: repo_full_name [required]: Missing required property; repo_full_name [required]: Missing required property",
  "error_code": "INVALID_ARGUMENT",
  "error_data": {
    "reason": "INVALID_PARAMETERS",
    "clamp_errors": [
      {"path": ["repo_full_name"], "message": "Missing required property", "keyword": "required"},
      {"path": ["repo_full_name"], "message": "Missing required property", "keyword": "required"}
    ],
    "clamp_rewrites": []
  }
}

The same failure also occurs on mcp__codex_apps__github_update_issue_comment.

Two changes/observations since the original report:

  • The misleading ChatGPT workspace-admin message is no longer included in the error text.
  • The missing-property error is still duplicated twice in both the text string and error_data.clamp_errors.

The same split (repo_full_name on 10 comment/reaction tools vs repository_full_name on 7 repository/branch/pull-request tools) is still present in codex-rs/core/assets/consequential_tool_message_templates.json on main. Standardizing on one repository parameter name across the GitHub connector (or accepting both as aliases) and deduplicating clamp_errors would avoid these repeated retry round-trips.

rldyourmnd avatar Nov 26 '26 07:11 rldyourmnd