Skip to content
This repository has been archived by the owner on Apr 24, 2024. It is now read-only.

Error when using bardapi asynchronously #140

Closed
akos326 opened this issue Jul 26, 2023 · 1 comment · Fixed by #142
Closed

Error when using bardapi asynchronously #140

akos326 opened this issue Jul 26, 2023 · 1 comment · Fixed by #142
Assignees

Comments

@akos326
Copy link

akos326 commented Jul 26, 2023

Describe the bug
I'm trying to use BardAsync following the README's instructions. I've checked, my token is right.
When running the following line, I get a TypeError:

Code

asyncio.run(bard.get_answer("What is Metaverse?"))

Error message

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python3.10/asyncio/runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "/usr/lib/python3.10/asyncio/base_events.py", line 646, in run_until_complete
    return future.result()
  File "/home/akos326/.local/lib/python3.10/site-packages/bardapi/core_async.py", line 82, in get_answer
    self.SNlM0e = await self.SNlM0e
  File "/home/akos326/.local/lib/python3.10/site-packages/bardapi/core_async.py", line 242, in _get_snim0e
    resp = await self.client.get(
TypeError: AsyncClient.get() got an unexpected keyword argument 'follow_redirects'

Version
OS: Ubuntu 22.04
Python: 3.10
Bard API: 0.1.29
Using proxy: no

@yihong0618
Copy link
Contributor

pip install -U httpx

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants