Skip to content

release(v2.2.0): merge develop into main#101

Merged
wrxck merged 25 commits intomainfrom
develop
Feb 13, 2026
Merged

release(v2.2.0): merge develop into main#101
wrxck merged 25 commits intomainfrom
develop

Conversation

@wrxck
Copy link
Owner

@wrxck wrxck commented Feb 13, 2026

Summary

Release v2.2.0 — merging develop into main.

See release notes for full changelog.

Highlights

  • Async HTTP module with SSRF protection
  • All SQL replaced with PostgreSQL stored procedures
  • 20+ new plugins across all categories
  • 8 new Telegram event hooks
  • Full luacheck compliance (0 warnings, 595 tests pass)
  • Second bot instance support

Matt Hesketh and others added 25 commits February 13, 2026 00:24
- Move hardcoded Tenor API key to config (TENOR_API_KEY)
- Fix restrict_chat_member arg order in wordfilter, join_captcha (permissions
  as 3rd arg, opts as 4th); replace deprecated permission names with modern
  granular permissions
- Fix UTF-8 iteration in flip.lua and aesthetic.lua using proper codepoint
  pattern instead of byte-level iteration
- Replace blocking socket.sleep with copas.pause in purge plugin; batch
  message deletion using delete_messages API (groups of 100)
- Fix callback_query handler creating empty chat context for inline buttons;
  now creates minimal valid context with sender's ID and private type
- Fix config parser stripping inline # comments from quoted .env values
- Implement SpamWatch API integration in blocklist middleware with Redis
  caching (was dead code stub)
- about.lua: use BOT_ADMINS[1] for owner ID instead of hardcoded value
- help.lua: read CHANNEL_URL, SUPPORT_URL, GITHUB_URL, DEV_URL from
  config with current values as defaults
- main.lua: register bot command menu on startup via set_my_commands,
  with separate admin-scoped command list for group administrators
- id.lua: add premium status, profile photo count, bot flag, forum
  status, linked chat, hidden members, and anti-spam fields
- .env.example: add new optional config keys for bot links
Add handler functions and api.run() wiring for:
- chat_join_request: approve/decline join requests via plugins
- chat_member: member status changes (promoted, left, etc.)
- my_chat_member: bot's own status changes (added/removed/promoted)
- message_reaction: emoji reaction changes on messages
- poll: poll state changes (closed, etc.)
- poll_answer: individual user votes on polls
- chat_boost / removed_chat_boost: boost/unboost events
- message_reaction_count: anonymous reaction counts

Each handler uses a lightweight context builder (no full middleware
pipeline) and dispatches to plugin hooks following the same pcall +
error logging pattern as existing handlers.

Also fixes callback_query handler to create valid chat context for
inline button callbacks (was creating empty chat object).
- unpinall: unpin all messages via api.unpin_all_chat_messages
- chatinfo: /settitle and /setdescription for chat metadata
- customtitle: set admin custom titles (16 char limit)
- slowmode: control slow mode delay (off/10s/30s/1m/5m/15m/1h)
- topic: forum topic management (create/close/reopen/delete/rename)
- joinrequest: configurable join request policy (auto-approve,
  auto-reject, manual with approve/reject buttons); hooks into
  on_chat_join_request router event
- chatpermissions: inline keyboard UI to toggle default chat
  permissions with live updates via set_chat_permissions
- poll: create polls and quizzes via /poll and /quiz with pipe-separated
  options; uses native Telegram poll API with quiz mode support
- react: reply to messages with /react <emoji> to set reactions via
  set_message_reaction API; auto-deletes command message
- boosts: view user boost count in chat, hooks on_chat_boost to send
  notification when chat receives a new boost
- bulkops: /forward and /copy commands to forward/copy replied messages
  to target chats using forward_messages/copy_messages API
Rate limiting:
- Add Redis-based rate limiting for callback queries (5/3s per user)
  with toast notification on rate limit hit
- Add Redis-based rate limiting for inline queries (3/2s per user)
  with silent drop on rate limit hit

Opts-based migration (priority plugins):
- help.lua: migrate all send_message/edit_message_text calls from
  positional args to opts table format
- about.lua: migrate send_message to opts
- id.lua: migrate send_message to opts
- wordfilter.lua: migrate send_message calls to opts
- join_captcha.lua: migrate send_message to opts
- gif.lua: migrate send_message to opts

This eliminates deprecation warnings from the telegram-bot-lua compat
layer for these high-traffic plugins.
…ization

- Add async HTTP module (src/core/http.lua) for non-blocking plugin requests
- Replace all inline SQL with PostgreSQL stored procedures
- Add 13 new plugins: autodelete, customcaptcha, slowmode, topic, poll,
  reactions, qr, bookmark, growth, inline, paste, rss, schedule
- Modernize all API calls to opts-based pattern
- Expand router with 8 new event hooks (reactions, polls, boosts, etc.)
- Add migration 006 for import procedures
- Add docker-compose.matticate.yml for second bot instance
- Update docs, rockspec, and plugin counts for v2.2
feat(v2.2): async HTTP, stored procedures, 13 new plugins
fix(content): configurable links, command menu, enhanced /id
# Conflicts:
#	src/plugins/admin/join_captcha.lua
#	src/plugins/admin/purge.lua
#	src/plugins/admin/wordfilter.lua
fix(core): resolve multiple bugs across plugins and middleware
# Conflicts:
#	src/core/router.lua
feat(router): handle 9 new Telegram update types
# Conflicts:
#	src/core/router.lua
#	src/plugins/admin/init.lua
#	src/plugins/admin/slowmode.lua
#	src/plugins/admin/topic.lua
# Conflicts:
#	src/core/router.lua
#	src/plugins/admin/init.lua
#	src/plugins/fun/init.lua
#	src/plugins/utility/init.lua
# Conflicts:
#	src/core/router.lua
#	src/plugins/admin/join_captcha.lua
#	src/plugins/utility/help.lua
- Remove duplicate stub handler functions in router.lua
- Remove undefined on_message_reaction_count reference
- Replace unused variables (code, status, err) with _ in 18 plugins
- Remove unused PERMANENT_PLUGINS variable from loader.lua
- Fix global assignment _ in database.lua
- Break long line in customcaptcha.lua
fix(lint): resolve all luacheck warnings across codebase
# Conflicts:
#	src/core/router.lua
# Conflicts:
#	src/core/router.lua
feat(admin): add 7 new admin plugins
# Conflicts:
#	src/plugins/admin/init.lua
feat(plugins): add poll, react, boosts, and bulk ops
feat(framework): rate limiting and opts-based API migration
@wrxck wrxck merged commit 722fab0 into main Feb 13, 2026
2 checks passed
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.

1 participant