Skip to content
TheChatArchiveThe Chat Archive
DeepSeekdeepseek/deepseek-v4-pro· deepseekHugging Face ibragim-bad/swe_rebench_07_2026_trajectories

ISSUE DESCRIPTION jarvis agents list Traceback Description Learning OpenJarvis on a…

  1. User

    ISSUE DESCRIPTION

    jarvis agents list Traceback

    Description

    Learning OpenJarvis on a Windows machine with WSL2. I was wondering what would happen on a clean reboot and listed the agents. This worked the first two times and listed the "... My Assistant │ deep_research ...". I even used the ID to ask it questions which worked (jarvis agents ask b0e6dece007b "How can I contribute to the OpenJarvis Project"). I had not loaded the model (Gemma 4 31b) into Ollama (this was direct from an open WSL Ubuntu window). My alias for jarvis is jarvis() { cd "OPENJARVISHOME"∣∣return1uvrunjarvis"OPENJARVIS_HOME" || return 1 uv run jarvis "@" }

    My config is terse # OpenJarvis configuration # Hardware: 13th Gen Intel(R) Core(TM) i9-13900K (32 cores, 62.6 GB RAM) # GPU: NVIDIA GeForce RTX 4090 (24.0 GB VRAM) # Full reference config: jarvis init --full

    [engine] default = "ollama"

    [engine.ollama] # host = "http://localhost:11434" # set to remote URL if engine runs elsewhere

    [intelligence] default_model = "gemma4:31b"

    [agent] default_agent = "simple"

    [tools] enabled = ["code_interpreter", "web_search", "file_read", "shell_exec"]

    Steps to Reproduce

    1. Start an initial WSL Ubuntu shell
    2. run "jarvis"
    3. this will list the --help command
    4. run "jarvis agents list"
    5. this will list a table with one agent b0e6dece007b │ My Assistant │ deep_research │ idle │ 0 │ 0
    6. run "jarvis agents ask b0e6dece007b "How are you""
    7. this will respond after it loads and starts the model, GPU memory is utilized
    8. run "ps -aux|grep ollama" in another shell window
    9. this will output two processes:
    10. ollama 196 0.0 0.3 3405152 220636 ? Ssl 11:29 0:01 /usr/local/bin/ollama serve
    11. ollama 1078 66.2 6.9 195616136 4544716 ? Sl 12:39 5:25 /usr/local/bin/ollama runner --ollama-engine --model usr/share/ollama/.ollama/models/blobs/sha256-280af6832eca23cb322c4dcc65edfea98a21b8f8ab07dc7553bd6f7e6e7a3313 --port 42291
    12. run "jarvis agents ask b0e6dece007b "How can I contribute to the OpenJarvis Project""
    13. This will respond
    14. Wait a bit, until GPU memory frees
    15. run the "ps -aux|grep ollama" in another shell window and see only the one ollam process for the "serve"
    16. run "jarvis agents list"
    17. see Traceback

    Expected Behavior

    Expected the table listing with one idle agent: b0e6dece007b │ My Assistant │ deep_research │ idle │ 0 │ 0

    Actual Behavior

    Traceback

    Operating System

    Linux

    Python Version

    3.12

    Hardware

    NVIDIA GPU

    Engine

    Ollama

    Logs / Traceback

    Traceback (most recent call last):
      File "/home/gru/projects/OpenJarvis/.venv/bin/jarvis", line 10, in <module>
        sys.exit(main())
                 ^^^^^^
      File "/home/gru/projects/OpenJarvis/src/openjarvis/cli/__init__.py", line 122, in main
        cli()
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/click/core.py", line 1485, in __call__
        return self.main(*args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/click/core.py", line 1406, in main
        rv = self.invoke(ctx)
             ^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/click/core.py", line 1873, in invoke
        return _process_result(sub_ctx.command.invoke(sub_ctx))
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/click/core.py", line 1873, in invoke
        return _process_result(sub_ctx.command.invoke(sub_ctx))
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/click/core.py", line 1269, in invoke
        return ctx.invoke(self.callback, **ctx.params)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/click/core.py", line 824, in invoke
        return callback(*args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/src/openjarvis/cli/agent_cmd.py", line 91, in list_agents
        console.print(f"[red]Error: {exc}[/red]")
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/rich/console.py", line 1698, in print
        renderables = self._collect_renderables(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/rich/console.py", line 1558, in _collect_renderables
        self.render_str(
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/rich/console.py", line 1448, in render_str
        rich_text = render_markup(
                    ^^^^^^^^^^^^^^
      File "/home/gru/projects/OpenJarvis/.venv/lib/python3.12/site-packages/rich/markup.py", line 167, in render
        raise MarkupError(
    rich.errors.MarkupError: closing tag '[/red]' at position 65 doesn't match any open tag
    

    ADDITIONAL ADVICE

    Since you are given a git repository, you can use git commands to simplify your work. For example, if you made a mistake and want to revert your changes, you can use git checkout <file> to restore the file to its original state. You can also reset all changes in the repository using git reset --hard command. Additionally, you can use git stash and git stash pop to temporarily save your changes and restore them later. Finally, you can see the changes that you've made (which will be submitted when you call submit) using git status or git diff commands. However you don't need to use git add or git commit before submitting your changes. In fact, submit only submits currently unstaged changes because it uses git diff to get the changes that need to be submitted.

    CHECKLIST

    Before submitting your solution, please go over the following checklist and make sure you've done everything:

    • If an error was reported in the issue description, I have successfully reproduced it.
    • If an error was reported in the issue description, I have confirmed that my fix resolves the error.
    • I have thought about edge cases and made sure my fix handles them as well.
    • I have run existing tests in the repository that might have been affected by the change I made and confirmed that they pass. I want you to list every bullet from this checklist and write your reasoning for why you think you did it or didn't need to.

    Repository has been uploaded and your shell is currently at the repository root. Time to solve the issue!

    (Current directory: /OpenJarvis, current file: none) bash-$

  2. DeepSeek Assistant

    Let me analyze the issue. The traceback shows:

    File "/home/gru/projects/OpenJarvis/src/openjarvis/cli/agent_cmd.py", line 91, in list_agents
        console.print(f"[red]Error: {exc}[/red]")
    

    And the error is:

    rich.errors.MarkupError: closing tag '[/red]' at position 65 doesn't match any open tag
    

    This means that the error message (exc) contains something that Rich's markup parser interprets as a closing tag [/red] before the actual [/red] at the end. This is likely because the exception message contains square brackets that Rich interprets as markup tags.

    The fix should be to escape the exception message so that Rich doesn't try to parse it as markup. Let me look at the relevant code first.

  3. DeepSeek Assistant

    I can see the issue on line 91. The exception message exc is being interpolated into a Rich markup string, and if it contains square brackets (like [/red] or other markup-like content), Rich will try to parse them as markup tags, causing the MarkupError.

    Let me search for all similar patterns in this file and check for the escape function usage.

  4. DeepSeek Assistant

    Let me run a single command.

  5. DeepSeek Assistant

    I can see the issue clearly. On line 91 (and many other lines), the exception message exc is interpolated into a Rich markup string. If the exception message contains square brackets, Rich tries to interpret them as markup, causing the MarkupError.

    The fix is to use rich.markup.escape() on any dynamic content being interpolated into Rich markup strings. Let me first look at the imports:

  6. DeepSeek Assistant

    Now let me add the import for escape from rich.markup and fix all the lines that interpolate dynamic values (like exc or agent_id) into Rich markup strings

  7. DeepSeek Assistant

    I need to use proper syntax for the edit command. Let me use heredoc syntax.

  8. DeepSeek Assistant

    Let me try a different approach with the replace command.

  9. DeepSeek Assistant

    Let me try quoting the arguments

  10. DeepSeek Assistant

    Good, the import is added. Now I need to fix all the lines where dynamic values are interpolated into Rich markup. Let me use replace --all to fix all {exc} patterns and {agent_id}

  11. DeepSeek Assistant

    Now let me fix the remaining dynamic interpolations. Let me search for all remaining unsafe patterns.

  12. DeepSeek Assistant

    The main fix (escaping exc) is done. Now let me fix the remaining unsafe interpolations where dynamic values are placed inside Rich markup tags. Let me fix the agent_id ones

  13. DeepSeek Assistant

    Now let me fix the Paused, Resumed, Archived agent messages:

  14. DeepSeek Assistant

    Lines 188 and 201 still have {agent_id} without escape. Let me fix those too.

  15. DeepSeek Assistant

    Line 201 still has {agent_id} without escape. Let me fix that.

  16. DeepSeek Assistant

    Now let me fix line 126 (the info command) and line 135 (the task

  17. DeepSeek Assistant

    Now let me fix lines 126 and 135.

  18. DeepSeek Assistant

    Now let me fix line 135.

  19. DeepSeek Assistant

    Now let me verify all changes look correct by checking the diff

  20. DeepSeek Assistant

    I notice that the replace --all also changed a click.echo line that doesn't use Rich markup. click.echo doesn't parse Rich markup, so escaping is not needed there and would actually show escape characters in the output. Let me revert that line

  21. DeepSeek Assistant

    Let me go to that line first

  22. DeepSeek Assistant

    Now let me fix line 330

  23. DeepSeek Assistant

    Good, the click.echo line is reverted. Now let me check if there are tests I can run to verify the changes aren't breaking anything

  24. DeepSeek Assistant

    Let me verify the fix is syntactically correct by trying to import the module

  25. DeepSeek Assistant

    Let me check the Python environment setup.

  26. DeepSeek Assistant

    The module imports successfully. Now let me create a quick test script to confirm the Rich markup error is

  27. DeepSeek Assistant

    I see - escape() expects a string but exc is an exception object. Let me check:

  28. DeepSeek Assistant

    Ah, I see the issue. escape() doesn't accept exception objects directly - we need str(exc). Let me fix all {escape(exc)} to {escape(str(exc))}:

  29. DeepSeek Assistant

    Now let me verify the import still works:

  30. DeepSeek Assistant

    Let me run a more comprehensive test to verify the fix works properly

  31. DeepSeek Assistant

    All tests pass. Let me review the final diff

  32. DeepSeek Assistant

    The diff looks clean. Let me check if there are similar patterns in other files that might have the same issue

  33. DeepSeek Assistant

    There are many other files with the same pattern, but the issue is specifically about agent_cmd.py in list_agents. Let me check if there are existing tests for this module.

  34. DeepSeek Assistant

    Let me run any existing tests to make sure the changes don't break anything.

  35. DeepSeek Assistant

    Let me run pytest without the timeout option.

  36. DeepSeek Assistant

    Let me skip that failing test and run the rest.

  37. DeepSeek Assistant

    Let me run only the relevant tests.

  38. DeepSeek Assistant

    The failing test (test_identical_calls_blocked) is unrelated to my changes - it's a pre-existing failure in the loop guard test. All 210 other tests pass.

    Let me clean up my temporary files and review the final state.

  39. DeepSeek Assistant

    Let me do a final review of the diff

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.