claude-code - 💡(How to fix) Fix [Bug] Slack MCP connector footer causes self-mention loop with Claude app [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#52129Fetched 2026-04-23 07:35:52
View on GitHub
Comments
0
Participants
1
Timeline
5
Reactions
0
Author
Participants
Timeline (top)
labeled ×4mentioned ×1

Error Message

[{"error":"Error: 127: Command 'code.cmd' not found or is in an unsafe location (current directory) Command 'code.cmd' not found or is in an unsafe location (current directory)\n at oLf (B:/~BUN/root/src/entrypoints/cli.js:1762:4045)\n at async iLf (B:/~BUN/root/src/entrypoints/cli.js:1762:1435)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-22T21:00:48.339Z"}]

Root Cause

Bug Description Recommended to submit here. Please review transcript and issue description: Thanks — the last message confirmed what I suspected: the attribution settings in settings.json only control git commit/PR attribution, not the Slack connector footer. So the Fin AI's fix was a dead end. Please disregard that thread of advice. Let me describe the actual bug so you can route it correctly: What the connector does: Every message sent via the Slack MCP connector (mcp__23fb4be0-717b-4e3f-859b-b99afd3a6450__slack_send_message) has Sent using <@U0A2KQ798JX|Claude> auto-appended by the connector itself — after my generated content, before Slack receives it. I confirmed this with a control test: I sent a message with an explicit "body ends here" sentinel and no attribution in the body. The footer was appended anyway. The text never passes through anything I control, so no prompt, skill, system instruction, or settings.json key can suppress it. Why it causes a loop: U0A2KQ798JX is the user ID of the Claude Slack app itself. Because the footer uses the <@U...|Claude> mention syntax, Slack renders it as a live mention and fires a mention event back to the same app. The Claude app then responds with its default "pick a repository" / "your Claude Code session is complete" prompts into the channel. Every scheduled Cowork task that posts to Slack kicks off this bounce-back. What I've already ruled out: Not fixable via prompt edits or skill instructions (text is injected after Claude). Not fixable in my settings.json (attribution.commit/attribution.pr are git-only). Not fixable at api.slack.com/apps (I don't own the Claude app, so it doesn't appear in my app list). /status shows no managed settings overrides on my side. The fix I'm requesting: Change the connector's footer from the live mention <@U0A2KQ798JX|Claude> to plain text (e.g., Sent using Claude). That preserves attribution without self-triggering the Claude Slack app. This would need to ship on the Anthropic/connector side — there's no user-side lever. Can you file this as a bug against the Slack MCP connector and share a ticket number? Conversation ID for reference: 215474025586338.

Code Example

[{"error":"Error: 127: Command 'code.cmd' not found or is in an unsafe location (current directory) Command 'code.cmd' not found or is in an unsafe location (current directory)\n    at oLf (B:/~BUN/root/src/entrypoints/cli.js:1762:4045)\n    at async iLf (B:/~BUN/root/src/entrypoints/cli.js:1762:1435)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-22T21:00:48.339Z"}]
RAW_BUFFERClick to expand / collapse

Bug Description Recommended to submit here. Please review transcript and issue description: Thanks — the last message confirmed what I suspected: the attribution settings in settings.json only control git commit/PR attribution, not the Slack connector footer. So the Fin AI's fix was a dead end. Please disregard that thread of advice. Let me describe the actual bug so you can route it correctly: What the connector does: Every message sent via the Slack MCP connector (mcp__23fb4be0-717b-4e3f-859b-b99afd3a6450__slack_send_message) has Sent using <@U0A2KQ798JX|Claude> auto-appended by the connector itself — after my generated content, before Slack receives it. I confirmed this with a control test: I sent a message with an explicit "body ends here" sentinel and no attribution in the body. The footer was appended anyway. The text never passes through anything I control, so no prompt, skill, system instruction, or settings.json key can suppress it. Why it causes a loop: U0A2KQ798JX is the user ID of the Claude Slack app itself. Because the footer uses the <@U...|Claude> mention syntax, Slack renders it as a live mention and fires a mention event back to the same app. The Claude app then responds with its default "pick a repository" / "your Claude Code session is complete" prompts into the channel. Every scheduled Cowork task that posts to Slack kicks off this bounce-back. What I've already ruled out: Not fixable via prompt edits or skill instructions (text is injected after Claude). Not fixable in my settings.json (attribution.commit/attribution.pr are git-only). Not fixable at api.slack.com/apps (I don't own the Claude app, so it doesn't appear in my app list). /status shows no managed settings overrides on my side. The fix I'm requesting: Change the connector's footer from the live mention <@U0A2KQ798JX|Claude> to plain text (e.g., Sent using Claude). That preserves attribution without self-triggering the Claude Slack app. This would need to ship on the Anthropic/connector side — there's no user-side lever. Can you file this as a bug against the Slack MCP connector and share a ticket number? Conversation ID for reference: 215474025586338.

Environment Info

  • Platform: win32
  • Terminal: vscode
  • Version: 2.1.117
  • Feedback ID: 0b4fc042-98f1-438e-8ee3-f457717d6508

Errors

[{"error":"Error: 127: Command 'code.cmd' not found or is in an unsafe location (current directory) Command 'code.cmd' not found or is in an unsafe location (current directory)\n    at oLf (B:/~BUN/root/src/entrypoints/cli.js:1762:4045)\n    at async iLf (B:/~BUN/root/src/entrypoints/cli.js:1762:1435)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-22T21:00:48.339Z"}]

extent analysis

TL;DR

The most likely fix is to modify the Slack MCP connector to append a plain text footer instead of a live mention.

Guidance

  • The issue is caused by the Slack MCP connector appending a live mention footer to messages, which triggers a mention event and causes the Claude app to respond.
  • To verify the issue, send a message via the Slack MCP connector and check if the footer is appended as a live mention.
  • The fix requires changing the connector's footer to plain text, which would need to be implemented on the Anthropic/connector side.
  • In the meantime, you can try to mitigate the issue by avoiding the use of the Slack MCP connector for scheduled Cowork tasks that post to Slack.

Example

No code snippet is provided as the issue is related to the Slack MCP connector's behavior, which is not controlled by user code.

Notes

The provided error message seems unrelated to the described issue, as it mentions a command not found error in the vscode terminal.

Recommendation

Apply workaround: Avoid using the Slack MCP connector for scheduled Cowork tasks that post to Slack until the connector is modified to append a plain text footer. This is because the current behavior of the connector is causing an infinite loop of responses from the Claude app.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [Bug] Slack MCP connector footer causes self-mention loop with Claude app [1 participants]