From 442fef31959860e846d50e633579a715d712b60e Mon Sep 17 00:00:00 2001 From: YellowSnnowmann <167776381+YellowSnnowmann@users.noreply.github.com> Date: Thu, 28 May 2026 17:55:32 +0530 Subject: [PATCH] refactor(tools): update GitHub tool slugs for clarity and remove deprecated entry (#2766) Co-authored-by: Claude Sonnet 4.6 --- .../memory_sync/composio/providers/github/tests.rs | 9 +++++++++ .../memory_sync/composio/providers/github/tools.rs | 14 ++++++++++++-- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/src/openhuman/memory_sync/composio/providers/github/tests.rs b/src/openhuman/memory_sync/composio/providers/github/tests.rs index c47441389..34bcc989b 100644 --- a/src/openhuman/memory_sync/composio/providers/github/tests.rs +++ b/src/openhuman/memory_sync/composio/providers/github/tests.rs @@ -167,6 +167,15 @@ fn curated_tools_contains_core_actions() { assert!(slugs.contains(&"GITHUB_GET_THE_AUTHENTICATED_USER")); assert!(slugs.contains(&"GITHUB_SEARCH_ISSUES_AND_PULL_REQUESTS")); assert!(slugs.contains(&"GITHUB_LIST_REPOSITORY_ISSUES")); + assert!(slugs.contains(&"GITHUB_LIST_REPOSITORIES_FOR_THE_AUTHENTICATED_USER")); + assert!(slugs.contains(&"GITHUB_CREATE_A_REPOSITORY_FOR_THE_AUTHENTICATED_USER")); + // DELETE_A_REFERENCE replaces DELETE_A_BRANCH (Composio v3 rename). + assert!(slugs.contains(&"GITHUB_DELETE_A_REFERENCE")); + // CLOSE_AN_ISSUE was removed — callers must use UPDATE_AN_ISSUE with state:"closed". + assert!( + !slugs.contains(&"GITHUB_CLOSE_AN_ISSUE"), + "GITHUB_CLOSE_AN_ISSUE was removed — use GITHUB_UPDATE_AN_ISSUE with state:closed" + ); } #[test] diff --git a/src/openhuman/memory_sync/composio/providers/github/tools.rs b/src/openhuman/memory_sync/composio/providers/github/tools.rs index 3daf4e2f1..10b462412 100644 --- a/src/openhuman/memory_sync/composio/providers/github/tools.rs +++ b/src/openhuman/memory_sync/composio/providers/github/tools.rs @@ -117,7 +117,8 @@ pub const GITHUB_CURATED: &[CuratedTool] = &[ slug: "GITHUB_UPDATE_AN_ISSUE", scope: ToolScope::Write, }, - // GITHUB_CLOSE_AN_ISSUE removed — use GITHUB_UPDATE_AN_ISSUE with state=closed + // GITHUB_CLOSE_AN_ISSUE — removed: no dedicated Composio slug. + // Use GITHUB_UPDATE_AN_ISSUE with state:"closed" instead. CuratedTool { slug: "GITHUB_CREATE_AN_ISSUE_COMMENT", scope: ToolScope::Write, @@ -163,7 +164,16 @@ pub const GITHUB_CURATED: &[CuratedTool] = &[ slug: "GITHUB_DELETE_A_REPOSITORY", scope: ToolScope::Admin, }, - // GITHUB_DELETE_A_BRANCH removed from Composio catalog — use GITHUB_DELETE_A_REFERENCE + // DELETE_A_REFERENCE maps to DELETE /repos/{owner}/{repo}/git/refs/{ref}. + // The ref must be a full path (e.g. `refs/heads/branch-name` or + // `refs/tags/v1.0`) — passing a bare branch name deletes nothing (404). + // This replaces the old GITHUB_DELETE_A_BRANCH slug (Composio v3 rename); + // it is broader — it can delete tags too — so agents should always specify + // a `refs/heads/` prefix when the intent is branch deletion. + CuratedTool { + slug: "GITHUB_DELETE_A_REFERENCE", + scope: ToolScope::Admin, + }, CuratedTool { slug: "GITHUB_DELETE_A_FILE", scope: ToolScope::Admin,