tma.js: Async call timeout exceeded. Timeout 100
Platform
Select platforms where this bug is reproducible:
- Telegram for Android
- Telegram for iOS
- Telegram for macOS
- Telegram Desktop
- Telegram Web A
- Telegram Web K
Describe the bug
I am having situations on initialization getting this error: “Async call timeout exceeded. Timeout 100” The same miniapp is working fine in other devices but specially in an android phone I have 2 telegram user and trying switching between them and getting that error 90% of the time when opening the application. In other devices, the application is always opening fine with the same users.
The application is done with next.js, so I am doing async loading.
'use client'
import type { PropsWithChildren } from 'react'
import { SDKProvider } from '@tma.js/sdk-react'
export function TmaSDKLoader({ children }: PropsWithChildren) {
return (
<SDKProvider
options={{
cssVars: true,
acceptCustomStyles: true,
async: true,
}}
>
{children}
</SDKProvider>
)
}
To Reproduce
Steps to reproduce the behavior:
Do loading process and show error result:
const { loading, initResult, error } = useSDKContext()
Expected behavior
Expected to obtain a value on initResult when loading finishes.
About this issue
- Original URL
- State: closed
- Created 6 months ago
- Comments: 21 (10 by maintainers)
I am currently working on several things:
Update will be available in the next several days, so you could try it
And if we have a beta release, maybe @Mergemat can test also his scenario.