If agent-shell-path-resolver-function is set globally to #'agent-shell-devcontainer-resolve-path, sessions in projects without .devcontainer/devcontainer.json fail with (error "Not found:"). The resolver unconditionally calls agent-shell-devcontainer--get-workspace-path, and the helper throws an error when the config file is missing.
Practical consequence: Anyone using projects with and without devcontainers in the same Emacs cannot simply set the variable globally, but needs their own wrapper that first checks whether the project is actually a devcontainer project.
Proposal: If no .devcontainer/devcontainer.json exists in the CWD, agent-shell-devcontainer-resolve-path should return the path unchanged. This makes the variable safe to set globally, and devcontainer translation only applies when relevant.
Checklist
If
agent-shell-path-resolver-functionis set globally to#'agent-shell-devcontainer-resolve-path, sessions in projects without.devcontainer/devcontainer.jsonfail with(error "Not found:"). The resolver unconditionally callsagent-shell-devcontainer--get-workspace-path, and the helper throws an error when the config file is missing.Practical consequence: Anyone using projects with and without devcontainers in the same Emacs cannot simply set the variable globally, but needs their own wrapper that first checks whether the project is actually a devcontainer project.
Proposal: If no
.devcontainer/devcontainer.jsonexists in the CWD,agent-shell-devcontainer-resolve-pathshould return the path unchanged. This makes the variable safe to set globally, and devcontainer translation only applies when relevant.Checklist