Skip to content

Feature/dashboard navigation#101

Open
kaungzinye wants to merge 4 commits into
mainfrom
feature/dashboard-navigation
Open

Feature/dashboard navigation#101
kaungzinye wants to merge 4 commits into
mainfrom
feature/dashboard-navigation

Conversation

@kaungzinye
Copy link
Copy Markdown
Collaborator

No description provided.

kaungzinye added 2 commits September 6, 2025 19:29
- Add urlparse import for URL validation
- Validate generated URLs before returning them
- Add fallback URL generation if validation fails
- Prevent malformed URLs from causing Telegram API errors
- Fix BUTTON_TYPE_INVALID error in web app buttons

File modified:
- bot/utils/web_app.py: Added URL validation and error handling
- Fix BUTTON_TYPE_INVALID error in group chats by using regular URL buttons
- Keep WebApp buttons for private chats where they work properly
- Group chats now use url parameter instead of web_app parameter
- Maintains functionality while fixing Telegram API compatibility issue

The issue was that WebApp buttons have restrictions in group chats,
causing BUTTON_TYPE_INVALID errors. This fix uses different button
types based on chat type for better compatibility.
@vercel
Copy link
Copy Markdown

vercel Bot commented Sep 6, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
meet-when-ah Ready Ready Preview Comment Sep 8, 2025 7:44am

kaungzinye added 2 commits September 8, 2025 09:38
- In private chats: still replies directly to user's message
- In group chats: sends help message without replying to user's message
- Maintains dashboard button functionality for both chat types
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