Skip to content

Grant agents access to each job's screenshot directory - #57

Merged
MonaDevAI merged 6 commits into
mainfrom
users/mobiswal/dashboard-linked-node-modules
Oct 12, 2026
Merged

MonaDevAI merged 6 commits into
mainfrom
users/mobiswal/dashboard-linked-node-modules

Conversation

@MonaDevAI

Copy link
Copy Markdown
Contributor

Problem

Dashboard-launched agents run non-interactively. Uploaded screenshots are stored in the job artifact directory outside the repository, so the agent was denied access and diagnosis blocked ("Permission denied because no interactive user response was available").

Change

Pass only the current job's artifact directory to the agent via --add-dir, in addition to the existing linked dependency directories. Branch also carries earlier commits (linked node_modules access, dismissing blocked jobs, public dev dependencies).

Validation

  • Focused tests pass (node --test: all pass; dashboard test asserts the executor receives the screenshot directory)
  • npm pack --dry-run contains the required files (not run; npm unavailable on this machine)
  • Documentation is updated (no doc change needed)
  • No credentials, tokens, private endpoints, or test data are included

lint, typecheck, docs, agent-rules, policy and self-healing gates pass. format:check reports mcp/server.js, which this PR does not modify (pre-existing). test:e2e and pack:check were skipped because npm is unavailable.

Risk

Grants file access to one job-scoped FixLab-owned directory only; no --allow-all-paths. Requires a dashboard restart to take effect.

MonaDevAI and others added 5 commits October 5, 2026 22:51
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: b5a57f24-f683-48de-abce-24cc5bc03e96
Dashboard and run executors now pass --add-dir for node_modules junctions that
resolve outside the repository, so auto-denied path prompts no longer block jobs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: d8b7888d-c8b2-4e87-95a4-623577cf1e57
A blocked job previously held the queue until resumed; only failed jobs could be
dismissed. Blocked jobs stay blocked in history.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: d8b7888d-c8b2-4e87-95a4-623577cf1e57
Address review: a repository-controlled node_modules symlink no longer grants
--add-dir on its own. Targets must fall under trustedDependencyRoots declared in
the repository profile (filesystem roots ignored), and the profile's configured
working directories are searched instead of only one directory level.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: d8b7888d-c8b2-4e87-95a4-623577cf1e57
Dashboard-launched agents could not read uploaded screenshots stored in the job artifact directory outside the repository, which blocked diagnosis. Pass only that job's artifact directory via --add-dir.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: aa2b2938-9ca6-4b67-a11a-f131b554d603
Copilot AI balanced review requested due to automatic review settings October 12, 2026 17:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Repository-controlled path grants and Windows shell argument handling introduce security risks.

2 open findings
What changed in this PR

Grants agents access to job-scoped screenshot artifacts, alongside bundled dependency-access and blocked-job dismissal changes.

Changes:

  • Adds scoped --add-dir arguments for screenshots and linked dependencies.
  • Allows blocked jobs to be dismissed.
  • Adjusts development dependency versions.
File Description
dashboard/​server.js Adds directory grants and blocked-job dismissal.
dashboard/​public/​app.js Updates dismissal UI for blocked jobs.
bin/​fixlab.js Grants linked dependency directories to CLI agents.
test/​dashboard-server.test.js Tests directory grants and blocked dismissal.
docs/​repository-onboarding.md Documents trusted dependency roots.
package.json Adjusts development dependencies.
package-lock.json Updates locked dependency metadata.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread dashboard/server.js
Comment on lines +1360 to +1365
const trustedRoots = (
Array.isArray(profile?.trustedDependencyRoots)
? profile.trustedDependencyRoots
: []
)
.filter((value) => typeof value === "string" && isAbsolute(value))
Comment thread dashboard/public/app.js
Comment on lines 444 to +449
const canDismissFailedJob =
canResume && job?.status === "failed";
canResume && ["failed", "blocked"].includes(job?.status);
dismissFailedJobButton.textContent =
job?.status === "blocked"
? "Dismiss blocked job and continue queue"
: "Dismiss failed job and continue queue";
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: aa2b2938-9ca6-4b67-a11a-f131b554d603
@MonaDevAI
MonaDevAI merged commit 805e11c into main Oct 12, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants