Skip to content

--with fastapi --with orjson to fix missing package error with github_copilot models #601

Description

@ekr1

Issue

Right now I need to run cecli with the uv tool run ... --with fastapi --with orjson ... cecli options; otherwise it will raise a litellm.APIConnectionError: APIConnectionError: Github_copilotException with the message No module named '...' for either module. Looks like those are missing in the requirements.txt?

This happens with all github_copilot/... models.

N.B. the code just displays "Retrying in ..." and suppresses any meaningful user output for this error unless I add this line:

modified   cecli/models.py
@@ -1416,6 +1416,7 @@ class Model(ModelSettings):
                         return hash_object, self.model_error_response()
 
                 print(f"Retrying in {retry_delay:.1f} seconds...")
+                print(f"LiteLLM API Error: {str(err)}")
                 if interrupt_event:
                     _res, interrupted = await coroutines.interruptible(
                         asyncio.sleep(retry_delay), interrupt_event

So there is a path through this method that displays no info whatsoever; maybe you could make it so at least the bare error message is displayed to the user in any case. I'd rather have a little spam than an error that is unactionable to the user.

As usual, thanks for your great work! :)

Version and model info

cecli v0.100.13.dev9

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions