mirror of
https://github.com/stablyai/orca.git
synced 2026-11-15 18:37:24 +00:00
Explain executable launch type assertions
This commit is contained in:
@@ -29,6 +29,7 @@ export function gitExecFileSync(
|
||||
// Host Git only: a WSL path would make this a synchronous wsl.exe that can boot the distro.
|
||||
throw new Error('Synchronous Git cannot run in a WSL folder. Use asynchronous Git for it.')
|
||||
}
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: A BufferEncoding is always supplied, so execFileSync returns text.
|
||||
return execNativeFileSync(
|
||||
resolved.binary,
|
||||
resolved.args,
|
||||
|
||||
@@ -96,6 +96,7 @@ function noChildSyncFailure(result: unknown): boolean {
|
||||
if (result === null || typeof result !== 'object') {
|
||||
return false
|
||||
}
|
||||
// oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: Every read is compared with an exact value or passed to the unknown-value error guard.
|
||||
const value = result as {
|
||||
pid?: number
|
||||
status?: number | null
|
||||
|
||||
Reference in New Issue
Block a user