Repository navigation
EN Troubleshooting
Русский: RU-Troubleshooting
- Register routes before
Start. - Use
/by default; for!help, setCommandPrefixes("/", "!"). - On Discord, enable the Message Content Intent for text commands or use slash commands.
Fallback is used only when there are no Message handlers. For a catch-all route, keep a single Message handler.
An active state.FSM intercepts the event before the router. Handle cancellation through ctx.Input() inside the scene.
storage/memory is ephemeral. Connect PostgreSQL, call EnsureSchema, and use its Sessions repository.
Call ctx.AnswerCallback(...). Create callback routes with payload.New(...).
This is the portable fallback only when the adapter reports platform.ErrEditUnavailable. Operational edit errors are returned and do not trigger Send. Use ctx.CanEdit() or a native adapter API when you need platform-specific behavior.
Event.UserID and PrivateMessenger are required. The method deliberately does not fall back to the public chat.
Event.Platform must match Platform.Name(), and the adapter must be added before dispatch/start.
An App cannot run concurrently. Cancel the context of the first Start call.
With VK_TOKEN, you also need a positive VK_GROUP_ID, Community Long Poll, and the correct token permissions.
Pass command definitions in discord.Config.Commands. GuildID speeds up development registration; global commands do not propagate immediately.
postgres.New does not create the schema. Call EnsureSchema.
The runtime retries startup with a 1–30 second backoff. The cause is in the platform stopped, retrying log entry.
Adapters subscribe only to event types required by registered routes. Add the necessary On, Command, Callback, Message, or Fallback route before Start.