This guide covers common issues you might encounter when using Kimaki and how to resolve them.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/remorses/kimaki/llms.txt
Use this file to discover all available pages before exploring further.
Bot Not Responding
Check Permissions
Only users with specific Discord permissions can interact with the bot:- Server Owner
- Administrator
- Manage Server
- “Kimaki” role (case-insensitive)
How to verify your permissions
How to verify your permissions
- Check if you have one of the required Discord permissions
- Look for a “Kimaki” role in your server’s role list
- Verify you don’t have the “no-kimaki” role assigned
Check if Bot is Running
The Kimaki CLI must be running on your machine for the bot to respond:Verify Channel Metadata
Each Kimaki channel should have metadata in its topic. Check the channel topic for XML metadata:/add-project again.
Permission Errors
”no-kimaki” Role Blocking Access
If you have the “no-kimaki” role, you cannot trigger sessions even if you’re a server owner. Solution: Remove the “no-kimaki” role from your Discord user.Permission Prompts in Thread
When the AI tries to run a tool that requires approval, Kimaki shows permission buttons in the Discord thread:- Accept - approve this one request
- Accept Always - auto-approve similar requests for the rest of the session
- Deny - block the request
opencode.json:
If you change
opencode.json while the bot is running, restart the OpenCode server using /restart-opencode-server or restart Kimaki.Multiple Instances Issues
Lock Port Conflicts
If you run multiple Kimaki instances on the same machine without setting different lock ports, they will conflict: Error:Database Conflicts
Each Kimaki instance needs its own database. Use--data-dir to separate instances:
OpenCode Server Issues
Server Not Starting
Symptoms:- No response from the bot
- Error messages about server startup
Server in Error State
If you see “ServerNotReadyError: OpenCode server is in an error state”: Solution:- Check the log file at
~/.kimaki/kimaki.log - Look for errors related to the specific directory
- Try restarting the OpenCode server with
/restart-opencode-server - If that doesn’t work, restart the entire Kimaki process
Voice Message Transcription Issues
API Key Missing
Error:ApiKeyMissingError: Gemini API key is required
Solution: Kimaki will prompt you for a Gemini API key during setup. If you skipped this step, restart the setup wizard:
Invalid Audio Format
Error:InvalidAudioFormatError: Invalid audio format
Solution: Discord sends voice messages in Opus format. Kimaki handles decoding automatically, but if you encounter this error:
- Try recording a new voice message
- Check your Discord client is up to date
- Verify the voice message uploaded successfully (you can play it back in Discord)
Empty Transcription
Error:EmptyTranscriptionError: Model returned empty transcription
This happens when the audio is silent or the model couldn’t transcribe it.
Solutions:
- Ensure your microphone is working
- Speak clearly and avoid background noise
- Try a shorter voice message first
- Check your Gemini API key is valid
Session Management Issues
Session Not Found
Error:SessionNotFoundError: Session <id> not found
This happens when trying to resume or fork a session that doesn’t exist.
Solutions:
Use autocomplete
Use autocomplete
The
/resume command has autocomplete - start typing to see available sessions.Check session ID
Check session ID
Verify the session ID is correct. Session IDs are stored in the database at
~/.kimaki/discord-sessions.db.Session Aborted Unexpectedly
Error:SessionAbortError: Session aborted: <reason>
Reasons for session abort:
- User ran
/abortcommand - Server process crashed
- Network connection lost
- Timeout or resource limit reached
~/.kimaki/kimaki.log for details.
Git Worktree Issues
Dirty Worktree Error
Error:DirtyWorktreeError: Uncommitted changes in worktree. Commit all changes before merging.
Solution: Commit all changes in the worktree before running /merge-worktree:
Rebase Conflict
Error:RebaseConflictError: Rebase conflict while rebasing onto main. Resolve conflicts, then run merge again.
Solution:
Nothing to Merge
Error:NothingToMergeError: No commits to merge -- branch is already up to date with main
This means the worktree branch has no new commits compared to the target branch.
Solution: This isn’t an error - the branches are already in sync. You can safely delete the worktree.
CI Automation Issues
Bot Token Not Found
Error: MissingKIMAKI_BOT_TOKEN environment variable
Solution: Add the bot token to your CI secrets:
Session Not Starting from CI
Symptoms:- Thread created in Discord but no AI response
- Command succeeds in CI but nothing happens
Verify bot is running
Verify bot is running
The Kimaki bot must be running on your machine to pick up threads created by CI.
Check channel ID
Check channel ID
Verify the
--channel ID is correct. Right-click the channel in Discord and select “Copy Channel ID”.Verify bot is installed
Verify bot is installed
Ensure the bot is installed in the server where the channel exists.
Check log file
Check log file
Read
~/.kimaki/kimaki.log on the machine running the bot for error messages.Debugging Tips
Check Log File
Kimaki writes logs to<data-dir>/kimaki.log (default: ~/.kimaki/kimaki.log). The log file is reset on every bot startup, so it only contains logs from the current run.
Enable Debug Mode
SetDEBUG=kimaki:* to see more detailed logs:
Check Database
The SQLite database at~/.kimaki/discord-sessions.db contains:
- Bot credentials
- Channel mappings
- Session history
- Scheduled tasks
Graceful Restart
To restart the bot without losing connections, sendSIGUSR2 signal: