Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

playwright._impl._errors.TimeoutError: Timeout 30000ms exceeded. #340

Open
TuanTool opened this issue Nov 25, 2023 · 3 comments
Open

playwright._impl._errors.TimeoutError: Timeout 30000ms exceeded. #340

TuanTool opened this issue Nov 25, 2023 · 3 comments

Comments

@TuanTool
Copy link

I don't know what happenning when I'm running
2023-11-25 22:06:21 | INFO | 🥳 TikTokPy initialized. Version: 0.9.4
2023-11-25 22:06:21 | INFO | 🔧 Settings successfully loaded
2023-11-25 22:06:21 | INFO | 🛑 Cookies not found, anonymous mode
2023-11-25 22:06:22 | INFO | 📈 Getting trending items
2023-11-25 22:06:54 | INFO | ✋ TikTokPy finished working. Session lasted: 32 seconds
Traceback (most recent call last):
File "D:\Bot_Tiktok\tiktokpy-master\quickstart.py", line 37, in
asyncio.run(main())
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\asyncio\runners.py", line 194, in run
return runner.run(main)
^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\asyncio\runners.py", line 118, in run
return self.loop.run_until_complete(task)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\asyncio\base_events.py", line 664, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "D:\Bot_Tiktok\tiktokpy-master\quickstart.py", line 9, in main
trending_items = await bot.trending(amount=5)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Bot_Tiktok\tiktokpy-master\tiktokpy\bot_init
.py", line 79, in trending
items = await Trending(client=self.client).feed(amount=amount)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Bot_Tiktok\tiktokpy-master\tiktokpy\client\trending.py", line 33, in feed
_ = await self.client.goto(
^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Bot_Tiktok\tiktokpy-master\tiktokpy\client_init_.py", line 102, in goto
response = await page.goto(full_url, *args, wait_until=wait_until, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\site-packages\playwright\async_api_generated.py", line 9260, in goto
await self._impl_obj.goto(
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\site-packages\playwright_impl_page.py", line 475, in goto
return await self._main_frame.goto(**locals_to_params(locals()))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\site-packages\playwright_impl_frame.py", line 139, in goto
await self._channel.send("goto", locals_to_params(locals()))
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\site-packages\playwright_impl_connection.py", line 62, in send
return await self._connection.wrap_api_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\site-packages\playwright_impl_connection.py", line 492, in wrap_api_call
return await cb()
^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python312\Lib\site-packages\playwright_impl_connection.py", line 100, in inner_send
result = next(iter(done)).result()
^^^^^^^^^^^^^^^^^^^^^^^^^
playwright._impl._errors.TimeoutError: Timeout 30000ms exceeded.

@Deathcrash
Copy link

+++ i have this error

@guowei3399
Copy link

me too

@robertonscjr
Copy link

A workaround that worked here was to change tiktokpy\client_init_.py", line 102 and add timeout=0 as an argument of page.goto call: response = await page.goto(full_url, timeout=0, *args, wait_until=wait_until, **kwargs).

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

No branches or pull requests

4 participants