paul-gauthier / aider

aider is AI pair programming in your terminal
https://aider.chat/
Apache License 2.0
18.93k stars 1.75k forks source link

Uncaught AttributeError in sendchat.py line 30 #1649

Closed viktorbezdek closed 2 hours ago

viktorbezdek commented 2 hours ago

Aider version: 0.56.0 Python version: 3.12.4 Platform: macOS-14.5-arm64-arm-64bit Python implementation: CPython Virtual environment: Yes OS: Darwin 23.5.0 (64bit) Git version: git version 2.39.5 (Apple Git-154)

An uncaught exception occurred:

Traceback (most recent call last):
  File "aider", line 10, in <module>
    sys.exit(main())
             ^^^^^^
  File "main.py", line 698, in main
    return 1
  File "base_coder.py", line 735, in run
    return self.io.get_input(
                ^^^^^^^^^^^^^^
  File "base_coder.py", line 778, in run_one
    def check_for_urls(self, inp):
            ^^^^^^^^^^^^^^^^^^^^^^^
  File "base_coder.py", line 1202, in send_message
  File "base_coder.py", line 1885, in auto_commit
    self.io.tool_error(f"Unable to commit: {str(err)}")
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "repo.py", line 102, in commit
    commit_message = self.get_commit_message(diffs, context)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "repo.py", line 187, in get_commit_message
    commit_message = simple_send_with_retries(
                     ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "sendchat.py", line 38, in wrapper
    retry_exceptions(),
    ^^^^^^^^^^^^^^^^^^
  File "sendchat.py", line 30, in retry_exceptions
    litellm.llms.anthropic.chat.AnthropicError,
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'litellm.llms.anthropic' has no attribute 'AnthropicError'
fry69 commented 2 hours ago

Thank you for filing this issue.

The fix is in the latest version (0.57.1), please update aider with

aider --upgrade
viktorbezdek commented 2 hours ago

Thank you 🙇🏻