Skip to content

fix(resources): validate required executables - #188

Merged
Emin017 merged 4 commits into
mainfrom
fix/review-required-executable-health
Aug 26, 2026
Merged

Emin017 merged 4 commits into
mainfrom
fix/review-required-executable-health

Conversation

@Luyoung0001

Copy link
Copy Markdown
Member

Context

This is remediation 5 of 6 extracted from the code review follow-up in #182. It addresses incomplete resource health checks found during review of f5e9af0f536878f804ef51887e5f5ab734388a24.

Finding

A resource could be reported as installed when its marker path merely existed. Directories, non-executable files, or incomplete staged archives could therefore pass health checks and fail only when the tool was launched.

Changes

  • Require executable markers to be ordinary files.
  • Check execute permission on POSIX and file accessibility on Windows.
  • Validate required markers for ECC-FE, Verilator, and the RISC-V toolchain.
  • Apply the same validation to staged archives, installed-resource health, UI status, and runtime path resolution.
  • Preserve the previous healthy installation and manifest when replacement validation fails.
  • Add regression coverage for directory markers and missing executable permissions.

Result

Resource Manager now reports Installed only when the required tool entry points are present and usable. Broken replacement archives fail before activation without destroying a working installation.

Verification

  • Cherry-picked independently onto the latest main.
  • Complete pnpm run check passed on this single-fix branch.
  • Resource refresh was manually verified to keep healthy resources in the Installed state.

Review lineage

Comment thread ecos/gui/apps/desktop-electron/electron/services/resourceManagerService.ts Outdated

@Emin017 Emin017 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The previous canonical-policy duplication has been fixed by the new focused module. One blocking marker-type gap remains: non-executable markers still use existence-only validation, so incomplete archives can pass the same staged and installed health boundary this PR is intended to harden.

Comment thread ecos/gui/apps/desktop-electron/electron/services/toolHealthPolicy.ts Outdated

@Emin017 Emin017 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The marker-type behavior from the previous review is fixed. One test-quality blocker remains.

Comment thread ecos/gui/apps/desktop-electron/electron/services/toolHealthPolicy.test.ts Outdated
@Luyoung0001
Luyoung0001 requested a review from Emin017 August 26, 2026 02:01
@Emin017 Emin017 added the bug Something isn't working label Aug 26, 2026
@Emin017 Emin017 added this to the 0.1.0-Alpha.9 milestone Aug 26, 2026
@Emin017
Emin017 merged commit 5ced238 into main Aug 26, 2026
7 checks passed
@Emin017
Emin017 deleted the fix/review-required-executable-health branch August 26, 2026 02:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants