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

the handler is closed #27

Open
3 tasks done
fivepe opened this issue May 19, 2024 · 8 comments
Open
3 tasks done

the handler is closed #27

fivepe opened this issue May 19, 2024 · 8 comments

Comments

@fivepe
Copy link

fivepe commented May 19, 2024

Checklist

  • I am sure the error is coming from Pyrogram's code and not elsewhere
  • I have searched in the issue tracker for similar bug reports, including closed ones
  • I ran pip3 install -U https://github.com/pyrogram/pyrogram/archive/master.zip and reproduced the issue using the latest development version

Description

i am getting this exact error when sending files. it looks like this though,
this is really interrupting my bot. would appreciate any advice.

Steps to reproduce

Traceback (most recent call last):
File "//venv/lib/python3.12/site-packages/pyrogram/methods/advanced/save_file.py", line 109, in worker
await session.invoke(data)
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 422, in invoke
return await self.invoke(query, retries - 1, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 422, in invoke
return await self.invoke(query, retries - 1, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 422, in invoke
return await self.invoke(query, retries - 1, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[Previous line repeated 7 more times]
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 412, in invoke
raise e from None
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 399, in invoke
return await self.send(query, timeout=timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 350, in send
raise e
File "//venv/lib/python3.12/site-packages/pyrogram/session/session.py", line 347, in send
await self.connection.send(payload)
File "//venv/lib/python3.12/site-packages/pyrogram/connection/connection.py", line 69, in send
await self.protocol.send(data)
File "//venv/lib/python3.12/site-packages/pyrogram/connection/transport/tcp/tcp_abridged.py", line 38, in send
await super().send(
File "//venv/lib/python3.12/site-packages/pyrogram/connection/transport/tcp/tcp.py", line 104, in send
raise OSError(e)
OSError: unable to perform operation on <TCPTransport closed=True reading=False 0x105e929b0>; the handler is closed
[10] Retrying "upload.SaveBigFilePart" due to: unable to perform operation on <TCPTransport closed=True reading=False 0x105e929b0>; the handler is closed
[10] Retrying "upload.SaveBigFilePart" due to: unable to perform operation on <TCPTransport closed=True reading=False 0x105e929b0>; the handler is closed
[10] Retrying "upload.SaveBigFilePart" due to: unable to perform operation on <TCPTransport closed=True reading=False 0x105e929b0>; the handler is closed
[10] Retrying "upload.SaveBigFilePart" due to: unable to perform operation on <TCPTransport closed=True reading=False 0x105e929b0>; the handler is closed
unable to perform operation on <TCPTransport closed=True reading=False 0x105e929b0>; the handler is closed

Code example

No response

Logs

No response

@SpEcHiDe SpEcHiDe added bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed labels May 19, 2024
@SpEcHiDe
Copy link
Contributor

I am also facing same issue, but I do not know how to solve it.

@annihilatorrrr
Copy link

I am also facing same issue, but I do not know how to solve it.

same and A LOT LOT.

@annihilatorrrr
Copy link

I am also facing same issue, but I do not know how to solve it.

same and A LOT LOT.

i do restart only as only solution, happens too much for userbots than bots.

@fivepe
Copy link
Author

fivepe commented May 19, 2024

my current solution is also to restart the client, but this will affect other ongoing tasks

I am also facing same issue, but I do not know how to solve it.

same and A LOT LOT.

i do restart only as only solution, happens too much for userbots than bots.

my current solution is also to restart the client, but this will affect other ongoing tasks

@annihilatorrrr
Copy link

my current solution is also to restart the client, but this will affect other ongoing tasks

I am also facing same issue, but I do not know how to solve it.

same and A LOT LOT.

i do restart only as only solution, happens too much for userbots than bots.

my current solution is also to restart the client, but this will affect other ongoing tasks

true, same.

@SpEcHiDe
Copy link
Contributor

SpEcHiDe commented Jun 20, 2024

Please retry with pyrotgfork==2.1.32.9 and reply here if issue still persists.

@SpEcHiDe SpEcHiDe added waiting-for-input and removed bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed labels Jun 20, 2024
@fivepe
Copy link
Author

fivepe commented Jun 21, 2024

Please retry with pyrotgfork==2.1.32.9 and reply here if issue still persists.

still persists
image

@SpEcHiDe
Copy link
Contributor

Please try again with

pip uninstall -y pyrogram && pip install https://github.com/TelegramPlayGround/pyrogram/archive/unfixe-error-d.zip

@TelegramPlayGround TelegramPlayGround locked as resolved and limited conversation to collaborators Jul 16, 2024
@SpEcHiDe SpEcHiDe reopened this Dec 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants