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

Uncaught TypeError in http_handler.py line 20 #1390

Closed
MIKEk8 opened this issue Sep 6, 2024 · 2 comments
Closed

Uncaught TypeError in http_handler.py line 20 #1390

MIKEk8 opened this issue Sep 6, 2024 · 2 comments

Comments

@MIKEk8
Copy link

MIKEk8 commented Sep 6, 2024

Aider version: <module 'aider.version' from 'C:\Program Files\Python311\Lib\site-packages\aider\version.py'>
Python version: 3.11.9
Platform: Windows-10-10.0.19045-SP0
Python implementation: CPython
Virtual environment: No
OS: Windows 10 (64bit)
Git version: git version 2.45.1.windows.1

An uncaught exception occurred:

Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "__main__.py", line 7, in <module>
    sys.exit(main())
             ^^^^^^
  File "main.py", line 510, in main
    main_model = models.Model(args.model, weak_model=args.weak_model)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "models.py", line 486, in __init__
    res = self.validate_environment()
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "models.py", line 660, in validate_environment
    res = litellm.validate_environment(model)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "llm.py", line 23, in __getattr__
    self._load_litellm()
  File "llm.py", line 30, in _load_litellm
    self._lazy_module = importlib.import_module("litellm")
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "__init__.py", line 8, in <module>
    from litellm.llms.custom_httpx.http_handler import AsyncHTTPHandler, HTTPHandler
  File "http_handler.py", line 20, in <module>
    _DEFAULT_TIMEOUT = httpx.Timeout(timeout=5.0, connect=5.0)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: Timeout.__init__() got an unexpected keyword argument 'connect'

@MIKEk8
Copy link
Author

MIKEk8 commented Sep 9, 2024

python -m venv aider_env
aider_env\Scripts\activate
pip install aider
pip install httpx==0.27.2
aider

@MIKEk8 MIKEk8 closed this as completed Sep 9, 2024
@fry69
Copy link
Collaborator

fry69 commented Sep 9, 2024

pip install aider

aider's package in PyPI is called aider-chat -> https://pypi.org/project/aider-chat/

See also -> https://aider.chat/docs/install.html

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