You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 1, 2023. It is now read-only.
Seems as api was changed.
Traceback (most recent call last):
File "D:\user\prog\threads_bot\v2\tests\test.py", line 21, in
loop.run_until_complete(main())
File "C:\Users\Bou\AppData\Local\Programs\Python\Python311\Lib\asyncio\base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "D:\user\prog\threads_bot\v2\tests\test.py", line 17, in main
await post()
File "D:\user\prog\threads_bot\v2\tests\test.py", line 9, in post
result = await api.like_post("1")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\user\prog\threads_bot\v2\venv\Lib\site-packages\threads_api\src\threads_api.py", line 501, in like_post
return res["status"] == "ok"
~~~^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
from threads_api.src.threads_api import ThreadsAPI
import asyncio
import os
async def post():
api = ThreadsAPI()
await api.login("user", "pass", cached_token_path="..\\data\\.session")
result = await api.like_post("1")
print(result)
if result:
print("Post has been successfully posted")
else:
print("Unable to post.")
async def main():
await post()
# Create an event loop and run the main function
loop = asyncio.get_event_loop()
loop.run_until_complete(main())
By hands, on phone, liking works.
The text was updated successfully, but these errors were encountered:
Seems as api was changed.
Traceback (most recent call last):
File "D:\user\prog\threads_bot\v2\tests\test.py", line 21, in
loop.run_until_complete(main())
File "C:\Users\Bou\AppData\Local\Programs\Python\Python311\Lib\asyncio\base_events.py", line 653, in run_until_complete
return future.result()
^^^^^^^^^^^^^^^
File "D:\user\prog\threads_bot\v2\tests\test.py", line 17, in main
await post()
File "D:\user\prog\threads_bot\v2\tests\test.py", line 9, in post
result = await api.like_post("1")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\user\prog\threads_bot\v2\venv\Lib\site-packages\threads_api\src\threads_api.py", line 501, in like_post
return res["status"] == "ok"
~~~^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
By hands, on phone, liking works.
The text was updated successfully, but these errors were encountered: