Address remaining code review feedback: improve error messages and add TODO comments

Co-authored-by: johndoe6345789 <224850594+johndoe6345789@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2025-12-27 03:11:52 +00:00
parent 18f8bf99b2
commit 1997479593
4 changed files with 22 additions and 3 deletions

View File

@@ -28,7 +28,18 @@ bool ContainerBackend::executeStep(const core::WorkflowStep& step,
QStringList args;
// Use specified shell or default to sh
// Common shells: bash, sh, dash, ash
QString shell = step.shell.isEmpty() ? "sh" : step.shell;
// Basic shell validation - prefer bash if available, fallback to sh
if (shell == "bash" || shell == "/bin/bash") {
// Try bash first, will fail if not available
shell = "bash";
} else if (shell == "sh" || shell == "/bin/sh") {
shell = "sh";
}
// For other shells, use as specified and let container fail if unavailable
args << "exec" << m_containerId << shell << "-c" << step.run;
process.start(m_containerRuntime, args);