Troubleshooting

Troubleshooting Bob Shell

Find solutions to issues you might encounter when using Bob Shell.

Authentication

Certificate errors

Error: Unable to verify certificate

Cause: You are on a corporate network with a firewall that intercepts and inspects SSL/TLS traffic. This requires a custom root CA certificate to be trusted by Node.js.

Solution: Set the NODE_EXTRA_CA_CERTS environment variable to the absolute path of your corporate root CA certificate file:

export NODE_EXTRA_CA_CERTS=/path/to/your/corporate-ca.crt

Configuration issues

.bobignore not working

Error: Bob Shell ignores files you want it to access, or accesses files you want it to ignore.

Cause: The .bobignore file might have conflicting patterns, incorrect pattern order, or be in the wrong location. Changes might not have taken effect yet.

Solution:

  1. Check your .bobignore file for conflicting patterns.
  2. Ensure more specific patterns (like negations with !) come after general patterns.
  3. Wait about 30 seconds after editing .bobignore. Bob Shell re-reads ignore patterns automatically; you do not need to restart.
  4. Write patterns relative to the directory that contains the .bobignore file, as in .gitignore.
  5. Verify the .bobignore file is in your workspace root or in the subdirectory you want it to apply to. Nested .bobignore files apply when Bob Shell reads or writes a file, but directory listings apply only the workspace-root .bobignore.

Settings not applying

Error: Bob Shell settings changes do not take effect.

Cause: The settings file might be in the wrong location, have invalid JSON syntax, or be overridden by higher-priority configuration sources. Changes might not have taken effect yet.

Solution:

  1. Check the settings file location. User settings are stored in ~/.bob/settings/settings.json in your home directory. For details, see Configuring.
  2. Verify the JSON syntax is valid (use a JSON validator).
  3. Remember that command-line flags override values from the settings file for the current session.
  4. Restart Bob Shell after changing settings files.

Custom instructions not loading

Error: Custom instructions are not being applied to Bob Shell sessions.

Cause: Custom instruction files might be in the wrong location, have incorrect file extensions, or not be loaded into the current context.

Solution:

  1. Verify files are in the correct location:
    • Workspace-wide: .bob/rules/ in your project root
    • Mode-specific: .bob/rules-{modeSlug}/ in your project root
  2. Check that the files are readable text files. Bob Shell loads every file in these directories, including subdirectories, in alphabetical order.
  3. Start a new task with /clear so Bob Shell reloads the rules.

Command running issues

Command not found

Error: command not found: bob

Cause: Bob Shell is not correctly installed or not in your system's PATH.

Solution:

  1. Verify Bob Shell is installed:
    which bob
  2. If not found, reinstall Bob Shell using the installation instructions.
  3. Check that your shell's PATH includes the Bob Shell installation directory.

Shell mode not working

Error: Shell mode (! command) does not run commands.

Cause: You might not be typing ! at an empty prompt, lack necessary permissions, or the command itself might be invalid.

Solution:

  1. Verify you're typing ! at an empty prompt.
  2. Check that you have the necessary permissions to run shell commands.
  3. Try running the command directly in your terminal first to verify it works.

Performance issues

Slow response times

Error: Bob Shell responds slowly to requests.

Cause: Network connectivity issues, too many files loaded as context, or large binary files included in the context.

Solution:

  1. Check your network connection.
  2. Reduce the number of files in context by using .bobignore.
  3. Avoid including large binary files or directories like node_modules/.
  4. Consider using more specific file references with @ instead of loading all files.

High memory usage

Error: Bob Shell consumes excessive memory.

Cause: Too many files loaded as context, or large directories not excluded.

Solution:

  1. Limit the number of files loaded as context.
  2. Use .bobignore to exclude large directories.
  3. Restart Bob Shell periodically during long sessions.

Tips for debugging Bob Shell

Enable debug logging

To increase log verbosity for a session, use the --log-level flag or the BOB_LOG_LEVEL environment variable:

bob run --log-level debug "Explain @app.js"
BOB_LOG_LEVEL=debug bob chat

You can also set a persistent log level in your settings file:

{
  "logging": {
    "logLevel": "debug"
  }
}

Verify your version of Bob Shell

Run the following command to see your version of Bob Shell:

Interactive session:

/status

Non-interactive session:

bob --version

Log files

Bob Shell writes log files to ~/.bob/logs/shell/. Log files rotate automatically:

  • Maximum of 10 log files are retained
  • Each file is capped at 5 MB

To find the current log file for a session:

ls -lt ~/.bob/logs/shell/ | head

Share relevant log excerpts when reporting issues.

Workspace root resolution

Bob Shell determines the workspace root by walking up from the current working directory until it finds a .git directory or a .bob directory. The first match becomes the workspace root.

If no .git or .bob directory is found, Bob Shell uses the current working directory as the workspace root.

How is this topic?