-
Notifications
You must be signed in to change notification settings - Fork 416
Description
Opencommit Version
3.2.11
Node Version
25.6.0
NPM Version
11.8.0
What OS are you seeing the problem on?
Other Linux Distro
What happened?
When setting OCO_API_URL to use a custom endpoint, the DeepSeek engine completely ignores it and always sends requests to the hardcoded https://api.deepseek.com/v1.
In src/engine/deepseek.ts, the constructor spreads config before the hardcoded baseURL:
super({
...config,
baseURL: 'https://api.deepseek.com/v1'
});Since baseURL comes after ...config, it always overwrites the user's OCO_API_URL setting. The fix is to reverse the order so the hardcoded URL acts as a default:
super({
baseURL: 'https://api.deepseek.com/v1',
...config,
});Expected Behavior
OCO_API_URL should be respected by all engines. The hardcoded URL should only be used as a default when no custom URL is configured.
Current Behavior
The DeepSeek engine completely ignores OCO_API_URL and always sends requests to the hardcoded https://api.deepseek.com/v1`
Possible Solution
DeepSeek: Put baseURL before ...config in constructor
Groq: Use config.baseURL = config.baseURL || '...'
OpenRouter: Use config.baseURL || '...' in axios.create()
Steps to Reproduce
oco config set OCO_AI_PROVIDER=deepseek
oco config set OCO_API_URL=https://proxy.example.comThen run oco — requests still go to api.deepseek.com