[Bug]: Cannot set provider or log in
Bug Description
I installed Forgecode for the first time. Following the docs:
$ forge provider login
● [11:47:26] Cancelled
I tried running forge by itself and discovered that some config files are missing:
$ ls -alF ~/forge/
total 76
drwxrwxr-x 3 mslinn mslinn 4096 Apr 10 11:26 ./
drwxr-xr-x 95 mslinn mslinn 4096 Apr 10 10:46 ../
-rw-rw-r-- 1 mslinn mslinn 425 Apr 10 10:44 .credentials.json
-rw-r--r-- 1 mslinn mslinn 57344 Apr 10 11:26 .forge.db
-rw-rw-r-- 1 mslinn mslinn 94 Apr 10 11:26 .forge_history
drwxrwxr-x 3 mslinn mslinn 4096 Apr 10 10:44 cache/
Without a config file, nothing works.
$ forge config set provider google
● [11:17:13] ERROR: Provider Google is not available. Login again to configure it.
mslinn@Bear instrument_recorder (master)
$ forge config set provider gemini
● [11:17:20] ERROR: Provider Gemini is not available. Login again to configure it.
mslinn@Bear instrument_recorder (master)
$ forge config set provider minimax
● [11:17:33] ERROR: Parameter selection cancelled
As a new user, I think the road ahead with this product looks bleak.
Steps to Reproduce
As described
Expected Behavior
As described
Actual Behavior
As described
Forge Version
2.8.0
Operating System & Version
WSL (current)
AI Provider
None possible
Model
None possible
Installation Method
npm install -g forgecode@latest
Configuration
Missing
Can u try exec zsh once and then retry.
❯ exec zsh ● [11:54:42] ERROR: No default provider set.
Can u run forge zsh doctor. Most probably fzf isn't installed.
Also if you install via curl you won't need to install fzf.
curl -fsSL https://forgecode.dev/cli | sh
We had a small issue in the script for a few hours, but its fixed now.
$ curl -fsSL https://forgecode.dev/cli | sh
Installing Forge and dependencies (fzf, bat, fd)...
Detected platform: x86_64-unknown-linux-gnu
Removing any previous npm-managed forge installation...
removed 1 package in 287ms
Downloading Forge from https://github.com/tailcallhq/forgecode/releases/latest/download/forge-x86_64-unknown-linux-gnu...
Installing to /home/mslinn/.local/bin/forge...
✓ Forge has been successfully installed!
forge 2.9.8
Run 'forge' to get started.
Installing dependencies...
✓ fzf 0.60 is already installed and compatible
Installing bat...
✓ bat installed successfully
Installing fd...
✓ fd installed successfully
Installation complete!
Tools installed: forge, fzf, bat, fd
Because this installer runs via '| sh', your current shell may still use old PATH values.
Open a new terminal or run: exec bash
$ forge zsh doctor
-bash: /home/mslinn/.nvm/versions/node/v25.8.2/bin/forge: No such file or directory
$ exec bash
$ forge zsh doctor
● [12:00:44] ERROR: Failed to execute zsh doctor script
Caused by: No such file or directory (os error 2)
Can u run exec zsh instead of exec bash
For me similar problem since 2.9.8 Forge cli works, but zsh setup : Hi doesn't work with error message ERROR: Provider MiniMax is not available. Login again to configure it. Only as example, other providers don't work either
Same here with the ZaiCoding on mac, mostly plain zsh profile:
ERROR: Provider ZaiCoding is not available. Login again to configure it.
First prompt in the conversation often works tho, then it breaks.
forge running in repl mode seems to be working fine, claude with the same API key is fine too
The same problem. Looks like only with zsh plugin. After ForgeService logout only first request, eg : hi proceed successfully, but all next requests return error. Using forge directly doesn't have this problem.
Info: forge
2.10.0&& zsh5.9(arm64-apple-darwin25.0)
Probably fixed with new release? I can confirm that the problem most likely from binary, because I built again with source code, then it was working Ok, no such behavior.
Is anyone facing this in latest release?
I'm kind of do. It's working much better, but still failing from time to time
D:\aa-forgecode>forge provider login ● [17:05:39] Cancelled
D:\aa-forgecode>forge provider logout ● [17:05:40] Cancelled
D:\aa-forgecode>forge --version forge 2.11.0
@HuangXinHao can u run forge doctor? May be u don't have fzf?
I'm kind of do. It's working much better, but still failing from time to time
Is it happening for any specific provider?
I'm kind of do. It's working much better, but still failing from time to time
Is it happening for any specific provider?
Only using it with Z.ai Coding Plan here, so can't say for sure
I'm kind of do. It's working much better, but still failing from time to time
Is it happening for any specific provider?
I tried, it's not provider specific error
Same for me.
% forge --version
forge 2.11.0
% zsh --version
zsh 5.9 (arm64-apple-darwin25.0)
% zimfw version
1.20.0
[!NOTE] The error is only visible for few millis and then disappears.
i can use it by npm , but not in .sh
Actually I can confirm that I'm seeing this errors from time to time even with local ollama now.
Also might or might not be related, often seeing this:
● [08:11:37] Continue f6fe483a-7656-4302-b792-9b24fee6481e
● [08:11:38] ERROR: POST http://127.0.0.1:11434/v1/chat/completions
Caused by:
0: error sending request for url (http://127.0.0.1:11434/v1/chat/completions)
1: client error (Connect)
2: tcp open error
3: Too many open files (os error 24)