Fixes
Errors coding agents hit, and how to fix them
DMN reads past agent sessions and keeps the fix whenever the same error is fixed the same way twice. Most of these are ones it learned from our own sessions building DMN, mostly on Windows, each written up with the cause and the fix.
Shell and quoting
- unexpected EOF while looking for matching: long Bash commands cut off on Windows.
-
SyntaxError: unterminated string literal: code
passed through
python -c. - sed: unknown option to `s': slashes and backslashes in the expression.
-
sed: can't read : No such file or directory: an
empty file name, or macOS's
-i ''. - The '<' operator is reserved for future use: a bash heredoc in PowerShell.
- The string is missing the terminator: ": a bash-style quote escape in PowerShell.
- SyntaxError: Invalid or unexpected token: a JavaScript string broken by a patch script.
- Get-Content : Cannot find path because it does not exist: a guessed path, another folder, or brackets in the name.
- The term 'git' is not recognized as the name of a cmdlet: Git missing from the PATH PowerShell started with.
Python
- UnicodeEncodeError: 'charmap' codec can't encode character: output captured on Windows.
- SyntaxWarning: invalid escape sequence '\d': regexes and Windows paths.
-
SyntaxError: (unicode error) 'unicodeescape' codec
can't decode bytes:
C:\Usersin a string. -
FileNotFoundError: [WinError 2]: npm and other
.cmdtools fromsubprocess. - FileNotFoundError: [Errno 2] No such file or directory: '/tmp/...': Git Bash paths in Windows Python.
- No module named pytest: the global Python instead of the project's environment.
- NameError: name '__file__' is not defined: a script's code run without its file.
Windows tools and Git
- rg: os error 123: glob paths that never get expanded.
- rg: The system cannot find the file specified. (os error 2): a path that isn't there.
- rg: regex parse error: unclosed character class: brackets in the text you search for.
- mklink: Invalid switch: junctions from Git Bash.
-
fatal: Needed a single revision:
git rev-parse --shortwith two refs. - error: cannot lock ref 'refs/remotes/origin/main': two fetches at once, from agents in worktrees of one clone.
- cargo: failed to remove file, Access is denied: rebuilding a program that's still running.
-
error: no library targets found in package:
cargo test --libon a binary.
Agent setup
- Codex doesn't list the MCP server you added: the config in the wrong folder.
- This client is no longer supported for Gemini Code Assist for individuals: Gemini CLI and a personal Google account.
-
batch file arguments are invalid: Rust starting
claude.cmdorcodex.cmd.
How DMN learns these
DMN reads your agents' past sessions on your machine. When the same error is fixed the same way in two or more of them, it keeps the fix as a one-line lesson. When the error turns up again, Claude Code is told the fix straight away, and any agent can search what earlier sessions found. How DMN keeps what agents learn.