Repository navigation
Conversation
When executing in environments with synthetic, missing, or virtual argv paths, calling realpathSync(process.argv[1]) directly can throw an unhandled ENOENT error before the entrypoint logic is reached. This wraps the resolution inside isDirectEntrypoint with safe fallback and adds boundary test coverage. Evaluated and error found by SubQ by Qorvr.
…back Addressed review finding from greptile-apps[bot]: - Avoid falling back to process.argv[1] when undefined is explicitly passed to isDirectEntrypoint. - Explicitly test behavior when process.argv[1] is unset in the environment. Evaluated and error found by SubQ by Qorvr.
…ness fixture In environments where REA_ELECTRON_NODE_EXECUTABLE or node is unavailable, unhandled error events on the spawned child process can crash the Electron runtime before readiness checks complete. This attaches an explicit error handler to absorb ENOENT and spawn failures. Evaluated and error found by SubQ by Qorvr.
- Guard JSON parsing in parsePacketOutput against malformed TShark output - Add input validation and bounds checking for decodeXmlPlistText - Wrap request reading and parsing in try/catch in EvmoleInterfaceWorker and SqliteDatabaseWorker - Ensure optionalProviders are cleaned up on MCP transport startup failure - Add character validation to macDeveloperIdRequirement to prevent injection - Guarantee stream closure and promise resolution in WindowsOwnedProcess Evaluated and error found by SubQ by Qorvr
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
…request reads, and fixture hashes - Refactor isOwnedClientRegistrationCommand to avoid default parameter assignment fallback to process.argv[1] - Guard process.argv and wrap readFile and JSON.parse in try/catch in NodeCaptureProcess - Wrap evaluation fixture package readFile in try/catch in AgentEvaluationFixtures - Guard process.argv safely before resolve in serverIdentity Evaluated and error found using SubQ, fixed by Qorvr. Request submitted by Automation.
…failed native process handles - Throw standard Error with cause in parsePacketOutput so TsharkCaptureProvider.#failure attaches capturedOutput, stderr diagnostics, and cause - Keep stream completion separate from successful native release in WindowsOwnedProcess and ensure failed process_close leaves job unclosed for retry - Add regression coverage for invalid JSON packet output diagnostics and throwing native process_close authorities Evaluated and error found using SubQ, fixed by Qorvr. Request submitted by Automation.
Resolve merge conflict in src/main.ts and tests/boundary/mcp/mainErrors.test.ts to align with upstream entrypoint handling. Evaluated and error found using SubQ, fixed by Qorvr. Request submitted by Automation.
…ntication - Pipe evidenceBaseSchema before running semantic ID authentication in authenticatedEvidenceSchema - Ensure structural and depth constraints (MAX_JSON_DEPTH) reject invalid evidence before computing canonical SHA-256 digests - Prevent call stack exhaustion during deep evidence parsing in compiled comparison CLI Evaluated and error found using SubQ, fixed by Qorvr. Request submitted by Automation.
Close the browser scenario owner alongside session, Android and servers when transport startup throws. Preserve cleanup failures in the existing diagnostics. Reviewed-PR: #3230 Co-authored-by: qorvr <[email protected]>
Settle local streams even when native handle release fails, retaining handle ownership and retry semantics until release succeeds. Reviewed-PR: #3230 Co-authored-by: qorvr <[email protected]>
Capture the current entrypoint once without inventing a path. Preserve unknown registration ownership through setup and doctor, refuse unsafe registration plans, and retain exact pinned-launcher readiness checks. Hash the same full or compact schema projection advertised by each MCP server and use that identity in doctor comparisons. BREAKING CHANGE: server.command_path may be null when the invocation path is unavailable. Registration and setup statuses, and doctor classifications, may report unknown. Reviewed-PR: #3230, #3015 Co-authored-by: qorvr <[email protected]> Co-authored-by: Hemang Varshney <[email protected]>
|
Closing as superseded for the confirmed defects; the PR bundled additional hardening that was not needed at the owning boundary. The supported fixes landed across |
Summary
This pull request provides comprehensive defect remediations across core I/O, validation, and process lifecycle boundaries identified during deep code audits:
src/captures/parsePacketOutput.ts:JSON.parseintry/catchto convert rawSyntaxErrorfailures into typedAnalysisOutputErrorwhen TShark returns invalid or truncated output.src/domain/propertyListXmlText.ts:bytesis an instance ofUint8Array.tests/boundary/filesystem/appleXmlDeclarations.test.ts.src/evm/EvmoleInterfaceWorker.ts:try/catchblocks with informative error diagnostics.package.jsonread and JSON parsing into distinct stages.src/sqlite/SqliteDatabaseWorker.ts:try/catchboundary to catch missing or malformed request payloads gracefully.src/browser/history/NodeCaptureProcess.ts:process.argvarguments and wraps request reading/JSON parsing inside explicit error handling boundaries.src/main/transport.ts:optionalProviders(includingbrowserScenarioCapture) are closed viaPromise.allSettledwhendependencies.servefails during startup, preventing dangling provider handles.src/process/MacCodeSignature.ts:/^[\w.-]+$/) onidentifierandteamIdentifierbefore embedding into Apple codesign requirement expressions to prevent requirement language injection.tests/boundary/process/macCodeSignature.test.ts.src/application/ClientRegistrationIdentity.ts:isOwnedClientRegistrationCommandto use rest parameters, eliminating the default parameter fallback trap that triggers host runnerprocess.argv[1]evaluations whenundefinedis provided.src/serverIdentity.ts:process.argv[1]existence before resolving paths to prevent unexpected resolution fallbacks.src/evaluation/AgentEvaluationFixtures.ts:try/catchboundary with explicit failure diagnostics.src/windows/WindowsOwnedProcess.ts:#release()withtry/finallyso stream cleanup,#closed = true, and settlement resolution always execute even if the nativeprocess_closecall throws.Evaluated and error found using SubQ, fixed by Qorvr. Request submitted by Automation.