feat: implement provider deactivation and enhance configuration updates
- Added a new function to deactivate the active provider without deleting credentials, facilitating smoother transitions between different provider types. - Updated the model flow logic to ensure the active provider is correctly set in the configuration, including handling custom endpoints and OAuth providers. - Improved error handling in the CLI to consistently format authentication error messages. - Enhanced the model selection process to reflect the effective provider based on configuration and environment variables.
This commit is contained in:
3
cli.py
3
cli.py
@@ -782,8 +782,7 @@ class HermesCLI:
|
||||
timeout_seconds=float(os.getenv("HERMES_NOUS_TIMEOUT_SECONDS", "15")),
|
||||
)
|
||||
except Exception as exc:
|
||||
from hermes_cli.auth import AuthError
|
||||
message = format_auth_error(exc) if isinstance(exc, AuthError) else str(exc)
|
||||
message = format_auth_error(exc)
|
||||
self.console.print(f"[bold red]{message}[/]")
|
||||
return False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user