Skip to content

Fix EQNotify add-tag description exceeding Discord's 100-char limit (boot crash)#267

Merged
ebm5025 merged 1 commit into
mainfrom
claude/eqnotify-castle-bot-integration-5c7l4s
Jul 24, 2026
Merged

Fix EQNotify add-tag description exceeding Discord's 100-char limit (boot crash)#267
ebm5025 merged 1 commit into
mainfrom
claude/eqnotify-castle-bot-integration-5c7l4s

Conversation

@ebm5025

@ebm5025 ebm5025 commented Jul 24, 2026

Copy link
Copy Markdown
Collaborator

Problem

The bot crashes on boot during slash-command registration:

ExpectedConstraintError: Invalid string length
  constraint: 's.string().lengthLessThanOrEqual()',
  given: "Keyword to match at the start of a batphone word (e.g. 'doze' hits 'Dozekar'). Use 'all' for every batphone.",
  expected: 'expected.length <= 100'
  at ... add-tag-subcommand.js:19 (setDescription)

Discord caps slash-command option descriptions at 100 characters. The /eqnotify add-tag description added in #266 was 108 characters. discord.js only validates this at command-registration time (not compile time), so it passed tsc and the unit tests but took down the worker on deploy.

Fix

  • Shortened the description to 93 characters, keeping the doze→Dozekar hint:
    Keyword matched at the start of a batphone word (e.g. 'doze' hits Dozekar). 'all' = every BP.
  • Added an inline comment noting the 100-char cap.
  • Audited every other EQNotify command/subcommand/option description — all are already within the limit; add-tag was the only offender.

Testing

  • yarn tsc — clean.
  • Verified the new literal is 93 chars (≤ 100).

🤖 Generated with Claude Code


Generated by Claude Code

The add-tag option description introduced in #266 was 108 characters, over
Discord's 100-character cap for option descriptions. discord.js validates
this only at command-registration time, so it passed tsc/tests but crashed
the bot on boot ("ExpectedConstraintError: Invalid string length"). Shortened
to 93 characters and noted the limit inline.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BWXRmPbtEz35wquwFd8Cu7
@ebm5025
ebm5025 merged commit b6d6687 into main Jul 24, 2026
1 check passed
@ebm5025
ebm5025 deleted the claude/eqnotify-castle-bot-integration-5c7l4s branch July 24, 2026 16:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants