openclaw - ✅(Solved) Fix [Bug]: Windows regression after 2026.3.31 update: Telegram plugin fails to load (Cannot find module 'grammy') [1 pull requests, 2 comments, 2 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#58676Fetched 2026-04-08 01:59:24
View on GitHub
Comments
2
Participants
2
Timeline
9
Reactions
0
Participants
Timeline (top)
cross-referenced ×3labeled ×2closed ×1commented ×1

After updating OpenClaw on Windows to the 2026-03-31 build, the Telegram plugin regressed and no longer starts.

This setup was working before the update. After the update, Telegram fails to load at startup with:

telegram failed to load from C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\extensions\telegram\index.js: Error: Cannot find module 'grammy'
Require stack:
- C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\sticker-cache-1Tf7t-45.js

Error Message

telegram failed to load from C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\extensions\telegram\index.js: Error: Cannot find module 'grammy' Require stack:

  • C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\sticker-cache-1Tf7t-45.js

Steps to reproduce

  1. Start from a Windows machine where Telegram was previously working with OpenClaw 2026.3.28
  2. Update OpenClaw to 2026.3.31
  3. Start OpenClaw / gateway normally
  4. Observe plugin startup logs

Expected behavior

The Telegram plugin should load successfully and the Telegram bot/channel should continue working after the update.

Actual behavior

The Telegram plugin fails to load during startup because module grammy cannot be found, and Telegram becomes unusable.

OpenClaw version

2026.03.31

Operating system

Windows 11

Install method

powershell -c "irm https://openclaw.ai/install.ps1 | iex"

Model

minimax M2.7

Provider / routing chain

openclaw -> minimax

Additional provider/model setup details

No response

Logs, screenshots, and evidence

Root Cause

The Telegram plugin fails to load during startup because module grammy cannot be found, and Telegram becomes unusable.

PR fix notes

PR #58705: fix(plugins): repair bundled runtime deps within plugin install dirs

Description (problem / solution / changelog)

Summary

  • repair bundled plugin runtime dependency installation by targeting each plugin's own install directory
  • stop relying on package-root node_modules as the primary repair target for bundled extension runtime deps
  • align postinstall repair behavior with the existing plugin-local runtime dependency staging model
  • add regression coverage for plugin-local installs, plugin-local sentinels, and shared deps across multiple plugins

Root cause

Issue #58676 exposed that bundled extension runtime dependencies are currently fragile in installed builds, especially on Windows global installs.

The current build/runtime model already supports plugin-local runtime dependency staging via stageRuntimeDependencies, but the postinstall repair path was still installing missing dependencies into the package root. That creates a split model:

  • build-time staging is plugin-local
  • install-time repair is root-level

In global install environments, especially on Windows, this makes bundled extension runtime resolution too dependent on root node_modules layout and nested postinstall repair behavior.

What this PR changes

This PR changes the postinstall repair path so that missing bundled runtime dependencies are installed into:

  • dist/extensions/<plugin>/node_modules

instead of the package root.

That makes the repair path consistent with the plugin-local runtime dependency model and reduces the chance of runtime resolution failures like the Telegram grammy regression.

Why this is different from a quick fix

This is not a Telegram-specific workaround and it does not paper over the issue by manually adding grammy to the root package.

Instead, it fixes the broader bundled extension runtime dependency delivery model so that all extensions using stageRuntimeDependencies benefit from the same more reliable behavior.

Tests

Added/updated coverage in:

  • test/scripts/postinstall-bundled-plugins.test.ts

Validated scenarios:

  • installs missing bundled runtime deps into plugin-local directories
  • skips reinstall when the plugin-local sentinel already exists
  • installs only missing plugin deps
  • installs shared runtime deps separately for each plugin that needs them

Validation

  • pnpm exec vitest run test/scripts/postinstall-bundled-plugins.test.ts

Changed files

  • scripts/postinstall-bundled-plugins.mjs (modified, +86/-43)
  • test/scripts/postinstall-bundled-plugins.test.ts (modified, +251/-41)

Code Example

telegram failed to load from C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\extensions\telegram\index.js: Error: Cannot find module 'grammy'
Require stack:
- C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\sticker-cache-1Tf7t-45.js


### Steps to reproduce

1. Start from a Windows machine where Telegram was previously working with OpenClaw 2026.3.28
2. Update OpenClaw to 2026.3.31
3. Start OpenClaw / gateway normally
4. Observe plugin startup logs

### Expected behavior

The Telegram plugin should load successfully and the Telegram bot/channel should continue working after the update.

### Actual behavior

The Telegram plugin fails to load during startup because module grammy cannot be found, and Telegram becomes unusable.

### OpenClaw version

2026.03.31

### Operating system

Windows 11

### Install method

powershell -c "irm https://openclaw.ai/install.ps1 | iex"

### Model

minimax M2.7

### Provider / routing chain

openclaw -> minimax

### Additional provider/model setup details

_No response_

### Logs, screenshots, and evidence
RAW_BUFFERClick to expand / collapse

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

Summary

After updating OpenClaw on Windows to the 2026-03-31 build, the Telegram plugin regressed and no longer starts.

This setup was working before the update. After the update, Telegram fails to load at startup with:

telegram failed to load from C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\extensions\telegram\index.js: Error: Cannot find module 'grammy'
Require stack:
- C:\Users\Illidan\AppData\Roaming\npm\node_modules\openclaw\dist\sticker-cache-1Tf7t-45.js


### Steps to reproduce

1. Start from a Windows machine where Telegram was previously working with OpenClaw 2026.3.28
2. Update OpenClaw to 2026.3.31
3. Start OpenClaw / gateway normally
4. Observe plugin startup logs

### Expected behavior

The Telegram plugin should load successfully and the Telegram bot/channel should continue working after the update.

### Actual behavior

The Telegram plugin fails to load during startup because module grammy cannot be found, and Telegram becomes unusable.

### OpenClaw version

2026.03.31

### Operating system

Windows 11

### Install method

powershell -c "irm https://openclaw.ai/install.ps1 | iex"

### Model

minimax M2.7

### Provider / routing chain

openclaw -> minimax

### Additional provider/model setup details

_No response_

### Logs, screenshots, and evidence

```shell

Impact and severity

No response

Additional information

No response

extent analysis

TL;DR

The Telegram plugin fails to load after updating OpenClaw to the 2026-03-31 build due to a missing 'grammy' module, and a potential workaround is to manually install the missing dependency.

Guidance

  • Verify the node_modules directory for the presence of the grammy module to confirm it's missing.
  • Check the OpenClaw update logs or release notes for any mentions of changes to dependencies or compatibility issues with the Telegram plugin.
  • Attempt to manually install the grammy module using npm or yarn to see if it resolves the issue.
  • Review the index.js file in the Telegram plugin directory to ensure it's correctly referencing the grammy module.

Example

No code example is provided as the issue doesn't imply a specific code change is needed, but rather a potential dependency issue.

Notes

The solution assumes that the grammy module is a required dependency for the Telegram plugin and that its absence is the root cause of the failure. If manual installation of the grammy module does not resolve the issue, further investigation into the OpenClaw update or the Telegram plugin's compatibility may be necessary.

Recommendation

Apply workaround: Manually install the missing grammy module as a temporary fix until an official update or patch is released that addresses the dependency issue.

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

The Telegram plugin should load successfully and the Telegram bot/channel should continue working after the update.

Still need to ship something?

×6

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

Back to top recommendations

TRENDING