Skip to content

Debugger launch failure doesn't redact environment variables #50007

@notpeter

Description

@notpeter

Reproduction steps

  1. Have a sensitive environment variable set in your shell environment, for example:
echo 'export GEMINI_API_KEY="AI_I_AM_A_SECRET"' > ~/.zshrc
  1. Have a partially invalid debug config in .zed/debug.json. Mine was:
[
  {
    "label": "Playdate Simulator: Build and Debug",
    "adapter": "playdate",
    "request": "launch",
    "program": "$ZED_WORKTREE_ROOT/playdate-snood.pdx",
    "tcp_connection": {
      "host": "127.0.0.1",
      "port": 55934,
      "timeout": 10000,
    },
  },
]
  1. cmd-shift-p, "Debugger: Start" (or F4).

(it will error)

Current vs. Expected behavior

Expected: Debugger console and zed.log should redact sensitive environment variables.

Current Expected
Image Image

Zed version and system specs

Zed: v0.226.0+nightly.2226.b5eeeb98e4b7ca92e42b8a3b5395aee2dc4067ec (Zed Nightly b5eeeb9)
OS: macOS 26.3
Memory: 64 GiB
Architecture: x86_64

Attach Zed log file

Zed.log:

2026-02-24T10:52:20-05:00 ERROR [debugger_ui::debugger_panel] failed to start debug adapter.:
failed to spawn command CLOUDFLARE_API_TOKEN="oOoOoOoOoOoOoOoOoOo" COMMAND_MODE="unix2003" DIGITALOCEAN_TOKEN="...." 

Metadata

Metadata

Assignees

No one assigned

    Labels

    state:needs triagetriage is not complete: no `area:*` label, or no `priority:*`/`frequency:*` for Bugs/Crashes

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions