code-yeongyu / code-yeongyu/senpi
cursor-cli-oauth: login does not enable the provider, models hidden despite valid credentials
- Dominant language
- TypeScript
- Stars
- 429
- Forks
- 98
- Avg merge
- 4h 57m
- Merged PRs (30d)
- 540
Description
## Summary
After successfully logging in to `cursor-cli-oauth` via `/login`, the provider remains disabled because `settings.json` does not get `cursorCliOauthProvider.enabled` set to `true`. The default in `DEFAULT_SETTINGS` is `enabled: false`, so cursor models never appear in the TUI model selector despite valid credentials being stored in `auth.json`.
## Root cause
In `settings.js`:
```js
const DEFAULT_SETTINGS = {
enabled: false, // ← default is disabled
...
};
```
The login flow (`oauth-login.js` → `createCursorCliOauthConfig.login()`) stores credentials via `addAccount()` but never writes `enabled: true` to the settings file. The `assessConfiguration` function then hits `if (!settings.enabled) return { status: "disabled" }` and `check()` returns `undefined`, hiding all cursor models from the TUI.
## Steps to reproduce
1. Install cursor-agent: `curl https://cursor.com/install -fsS | bash`
2. Run `/login cursor-cli-oauth` → complete the OAuth flow successfully
3. Open TUI model selector → no cursor-cli-oauth models appear
4. `omo --list-models` shows cursor-cli-oauth models exist (15 models)
## Workaround
Manually add to `~/.senpi/agent/settings.json`:
```json
{
"cursorCliOauthProvider": {
"enabled": true
}
}
```
## Expected behavior
A successful `/login cursor-cli-oauth` should either:
- Automatically set `cursorCliOauthProvider.enabled: true` in settings, or
- Default `enabled` to `true` and use login/credential presence as the gating mechanism
The current behavior requires users to know about an undocumented settings key to use a provider they just logged into.
## Environment
- omo-ai: 5.0.0-0.beta.9
- OS: macOS (Apple Silicon)
Contributor guide
Research direction
Start in settings.js and oauth-login.js, tracing createCursorCliOauthConfig.login() through addAccount() and the enabled check in assessConfiguration. Reproduce with /login cursor-cli-oauth, then verify that a successful login enables the provider and that cursor models appear in the TUI selector and omo --list-models without manual settings changes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- authentication, cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 78/100