Repository navigation
Conversation
[High impact] The PR replaces the app's main scanning workflow and changes how local projects are reviewed. Fix sensitive-file exclusions and lost note edits before merging.
|
| for (const rule of rules) { | ||
| const match = rule.matcher.test(relative(rule.dir, full).split(sep).join("/") + (entry.isDirectory() ? "/" : "")); | ||
| if (match.ignored) ignored = true; | ||
| else if (match.unignored) ignored = false; |
There was a problem hiding this comment.
Excluded files reach the provider
A nested .gitignore can now undo an exclusion in an ancestor .openhackignore. For example, root .openhackignore containing private.json and src/.gitignore containing !private.json will admit src/private.json. The scanner then sends that file to the selected provider, despite the README telling users to exclude sensitive paths with .openhackignore.
Track the two kinds of ignore rules separately so Git exceptions cannot override scan-specific exclusions.
How this was verified: The shared rule list lets a later Git exception clear an earlier scan exclusion, and admitted source is included in remote provider requests.
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/harness/project.ts
Line: 67-70
Comment:
**Excluded files reach the provider**
A nested `.gitignore` can now undo an exclusion in an ancestor `.openhackignore`. For example, root `.openhackignore` containing `private.json` and `src/.gitignore` containing `!private.json` will admit `src/private.json`. The scanner then sends that file to the selected provider, despite the README telling users to exclude sensitive paths with `.openhackignore`.
Track the two kinds of ignore rules separately so Git exceptions cannot override scan-specific exclusions.
**How this was verified:** The shared rule list lets a later Git exception clear an earlier scan exclusion, and admitted source is included in remote provider requests.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.| useEffect(() => { | ||
| const controller = new AbortController(); | ||
| const signal = controller.signal; | ||
| setRecords(undefined); |
There was a problem hiding this comment.
Saving can discard newer edits
setRecords(undefined) removes the selected FindingDetail whenever findings reload. This also happens after a successful save because onSaved calls reload(). If the user keeps typing while the save request is pending, those newer edits were not submitted and disappear when the form remounts. This bypasses the existing revision check meant to preserve them.
Keep the last loaded records during a refresh, and block editing separately when a read fails.
Prompt To Fix With AI
This is a comment left during a code review.
Path: web/src/pages/ScanDetail.tsx
Line: 272
Comment:
**Saving can discard newer edits**
`setRecords(undefined)` removes the selected `FindingDetail` whenever findings reload. This also happens after a successful save because `onSaved` calls `reload()`. If the user keeps typing while the save request is pending, those newer edits were not submitted and disappear when the form remounts. This bypasses the existing `revision` check meant to preserve them.
Keep the last loaded records during a refresh, and block editing separately when a read fails.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.
Replace the hosted Python harness on main with the local Bun/TypeScript scanning harness and React dashboard developed on v2. OpenHack opens a loopback dashboard on port 6969, runs source reviews through API or existing Codex/Claude logins, and stores scan history and findings locally.
The package version is 2.0.0 and the README has been rewritten around standalone installation and the local workflow. This includes inline onboarding with the native folder chooser, the OpenHack Pro page, partial-result handling and resume behavior, and a development-only onboarding replay that is excluded from production builds. Standalone builds embed the runtime and dashboard for macOS, Linux, and Windows on ARM64 and x64; CI builds, smoke-tests, and packages all six targets. CI runs on both main and v2.
Validation: frozen dependency install; typecheck; all 144 tests; production build; package smoke test; dependency audit with no reported vulnerabilities. The README also includes the full animated product demo. Cross-platform CI results are attached to this PR. Linux archive verification now retains gzip on PATH while the executable check stays isolated; Windows avoids unsupported POSIX fchmod operations.
Includes a main-only manual macOS signing workflow: import encrypted Actions credentials into a temporary keychain, apply Developer ID signatures, require Apple notarization, smoke-test on the native architecture, and package final checksums. Apple has accepted notarization for both macOS architectures. Both signatures verify, the signed Apple Silicon executable passes the standalone smoke test, and the exact notarized binaries are packaged with checksums and receipts on the unpublished v2.0.0 draft release. The curl installer detects macOS/Linux and architecture, validates release checksums, retains license notices, and replaces the executable only after download verification. Installer tests cover all four supported targets, failure paths, and upgrades. Windows signing is not implemented, and the v2.0.0 release remains an unpublished draft.