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

Running main.py Error #28

Open
mehrdad-data opened this issue Nov 23, 2023 · 2 comments
Open

Running main.py Error #28

mehrdad-data opened this issue Nov 23, 2023 · 2 comments

Comments

@mehrdad-data
Copy link

Hi
I cant run the code becuase of below error ,
Whats the problem ?
Thanks

(savebot) C:\Save-Restricted-Bot>python main.py
Traceback (most recent call last):
File "main.py", line 22, in
acc.start()
File "C:\Save-Restricted-Bot\savebot\lib\site-packages\pyrogram\sync.py", line
66, in async_to_sync_wrap
return loop.run_until_complete(coroutine)
File "C:\python\lib\asyncio\base_events.py", line 616, in run_until_complete
return future.result()
File "C:\Save-Restricted-Bot\savebot\lib\site-packages\pyrogram\methods\utilit
ies\start.py", line 58, in start
is_authorized = await self.connect()
File "C:\Save-Restricted-Bot\savebot\lib\site-packages\pyrogram\methods\auth\c
onnect.py", line 40, in connect
await self.load_session()
File "C:\Save-Restricted-Bot\savebot\lib\site-packages\pyrogram\client.py", li
ne 616, in load_session
await self.storage.open()
File "C:\Save-Restricted-Bot\savebot\lib\site-packages\pyrogram\storage\memory
_storage.py", line 59, in open
dc_id, api_id, test_mode, auth_key, user_id, is_bot = struct.unpack(
struct.error: unpack requires a buffer of 271 bytes

@mehrdad-data
Copy link
Author

problem solved
rename json file to py and open ir with IDLE python and change data then save and rename it to json.

@kcoffical6
Copy link

Please explain in detail

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

2 participants