openclaw - 💡(How to fix) Fix [Bug]: grammy module missing after every update - telegram extension breaks repeatedly [2 comments, 3 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
openclaw/openclaw#70615Fetched 2026-04-24 05:55:41
View on GitHub
Comments
2
Participants
3
Timeline
7
Reactions
0
Author
Timeline (top)
commented ×2cross-referenced ×2labeled ×2closed ×1

After every openclaw update, the grammy module is missing from dist/extensions/telegram/node_modules/, causing openclaw doctor to fail with "Cannot find module 'grammy'" and breaking the entire Telegram channel. Happened at least 2 consecutive updates.

Error Message

Error output from openclaw update:

Error: Cannot find module 'grammy' Require stack:

  • /opt/homebrew/lib/node_modules/openclaw/dist/extensions/telegram/allowed-updates-BD2bJyzD.js

Telegram extension package.json confirms the dependency:

"dependencies": { "grammy": "^1.42.0" }

openclaw doctor --fix installs acpx, node-edge-tts but NOT grammy. grammy is missing from the bundled plugin deps auto-install list.

Root Cause

Root cause analysis:

  1. openclaw update replaces the entire install directory, wiping manually-installed node_modules
  2. grammy is NOT in openclaw doctor --fix's bundled plugin deps list (only [email protected], node-edge-tts@^1.2.10, [email protected] are auto-installed)
  3. The npm/homebrew package does not ship dist/extensions/telegram/node_modules/

Fix Action

Fix / Workaround

openclaw doctor fails with Cannot find module 'grammy'. The telegram extension's package.json declares "grammy": "^1.42.0" as a dependency, but dist/extensions/telegram/node_modules/ does not exist after update. The module must be manually installed with cd /opt/homebrew/lib/node_modules/openclaw/dist/extensions/telegram && npm install --production. This workaround must be repeated after every single update.

Code Example

Error output from openclaw update:

Error: Cannot find module 'grammy'
Require stack:
- /opt/homebrew/lib/node_modules/openclaw/dist/extensions/telegram/allowed-updates-BD2bJyzD.js


Telegram extension package.json confirms the dependency:

"dependencies": { "grammy": "^1.42.0" }


openclaw doctor --fix installs acpx, node-edge-tts but NOT grammy. grammy is missing from the bundled plugin deps auto-install list.
RAW_BUFFERClick to expand / collapse

Bug type

Behavior bug (incorrect output/state without crash)

Beta release blocker

No

Summary

After every openclaw update, the grammy module is missing from dist/extensions/telegram/node_modules/, causing openclaw doctor to fail with "Cannot find module 'grammy'" and breaking the entire Telegram channel. Happened at least 2 consecutive updates.

Steps to reproduce

  1. Install OpenClaw via Homebrew (/opt/homebrew/lib/node_modules/openclaw/)
  2. Configure a Telegram channel (bot token, etc.)
  3. Run openclaw update when a new version becomes available
  4. Run openclaw doctor
  5. Observe: Error: Cannot find module 'grammy' — Require stack: /opt/homebrew/lib/node_modules/openclaw/dist/extensions/telegram/allowed-updates-BD2bJyzD.js
  6. Telegram channel is broken; gateway cannot start properly for Telegram

Expected behavior

After openclaw update, the Telegram extension should have all its dependencies available. Either:

  • openclaw doctor --fix should auto-install grammy (like it does for acpx, node-edge-tts, playwright-core), OR
  • The update/package process should ship grammy inside dist/extensions/telegram/node_modules/, OR
  • The update process should run npm install for extensions declaring their own dependencies.

Actual behavior

openclaw doctor fails with Cannot find module 'grammy'. The telegram extension's package.json declares "grammy": "^1.42.0" as a dependency, but dist/extensions/telegram/node_modules/ does not exist after update. The module must be manually installed with cd /opt/homebrew/lib/node_modules/openclaw/dist/extensions/telegram && npm install --production. This workaround must be repeated after every single update.

OpenClaw version

2026.4.21 (f788c88)

Operating system

macOS Darwin 25.4.0

Install method

Homebrew (/opt/homebrew/lib/node_modules/openclaw/)

Model

N/A (packaging bug, not model-related)

Provider / routing chain

N/A (packaging bug, not model-related)

Additional provider/model setup details

No response

Logs, screenshots, and evidence

Error output from openclaw update:

Error: Cannot find module 'grammy'
Require stack:
- /opt/homebrew/lib/node_modules/openclaw/dist/extensions/telegram/allowed-updates-BD2bJyzD.js


Telegram extension package.json confirms the dependency:

"dependencies": { "grammy": "^1.42.0" }


openclaw doctor --fix installs acpx, node-edge-tts but NOT grammy. grammy is missing from the bundled plugin deps auto-install list.

Impact and severity

Affected: All Homebrew-installed OpenClaw users with Telegram channel configured Severity: High — completely breaks Telegram channel after every update Frequency: Always — 2/2 consecutive updates observed (versions before and including 2026.4.21) Consequence: Telegram bot goes offline after every update; agents cannot send/receive Telegram messages until user manually fixes

Additional information

Root cause analysis:

  1. openclaw update replaces the entire install directory, wiping manually-installed node_modules
  2. grammy is NOT in openclaw doctor --fix's bundled plugin deps list (only [email protected], node-edge-tts@^1.2.10, [email protected] are auto-installed)
  3. The npm/homebrew package does not ship dist/extensions/telegram/node_modules/

This is a packaging/pack-out gap, not a runtime regression. The fix should be to add grammy (and other telegram extension deps like @grammyjs/runner, @grammyjs/transformer-throttler, undici) to the doctor --fix bundled deps list, or to include extension node_modules in the package.

extent analysis

TL;DR

The most likely fix is to add grammy to the openclaw doctor --fix bundled plugin dependencies list or include extension node_modules in the package.

Guidance

  • Verify that the grammy dependency is declared in the Telegram extension's package.json file.
  • Check if openclaw doctor --fix can be modified to auto-install grammy and other required dependencies.
  • Consider including node_modules for extensions in the package to prevent dependencies from being wiped during updates.
  • Manually installing grammy with npm install --production in the extension directory can serve as a temporary workaround.

Example

No code snippet is provided as the issue is related to packaging and dependencies.

Notes

The root cause analysis suggests that the issue is due to the openclaw update process wiping manually installed node_modules and grammy not being included in the openclaw doctor --fix bundled plugin dependencies list.

Recommendation

Apply a workaround by manually installing grammy with npm install --production in the extension directory until a permanent fix is implemented, such as adding grammy to the openclaw doctor --fix bundled plugin dependencies list.

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…

FAQ

Expected behavior

After openclaw update, the Telegram extension should have all its dependencies available. Either:

  • openclaw doctor --fix should auto-install grammy (like it does for acpx, node-edge-tts, playwright-core), OR
  • The update/package process should ship grammy inside dist/extensions/telegram/node_modules/, OR
  • The update process should run npm install for extensions declaring their own dependencies.

Still need to ship something?

×6

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

Back to top recommendations

TRENDING