deepseek-ai/deepseek-harness · error · Error

MoveFileExW ${code} (Win32 ${win32Code}): ${path} -> ${dest}

Error message

MoveFileExW ${code} (Win32 ${win32Code}): ${path} -> ${dest}

What it means

Error "MoveFileExW ${code} (Win32 ${win32Code}): ${path} -> ${dest}" thrown in deepseek-ai/deepseek-harness.

Source

Thrown at packages/session/session-persistence-jsonl/src/win32.ts:119

    error.path = path
    throw error
  } catch (error) {
    if (isENOENT(error)) return false
    throw error
  }
}

/**
 * Publish `existing` at `replacement` with Windows write-through rename
 * semantics. The destination must not already exist; the move must stay within
 * the volume (no copy fallback flag is set).
 * @param existing - the synced staging path to move.
 * @param replacement - the final path, which must not already exist.
 */
export async function publishNewFileWin32(existing: string, replacement: string): Promise<void> {
  const api = await win32()
  const ok = api.moveFileExW(toNamespacedPath(existing), toNamespacedPath(replacement), MOVEFILE_WRITE_THROUGH)
  if (ok === 0) throw win32Error('MoveFileExW', api.getLastError(), existing, replacement)
}

/**
 * Create `target` and its missing ancestors with durable Windows namespace
 * publication. Each missing directory is first created as a random staging
 * sibling, then moved to its final name with `MOVEFILE_WRITE_THROUGH`; races
 * with another creator are accepted only after verifying the winner is a
 * directory.
 * @param target - the absolute directory path to create durably when absent.
 */
export async function ensureDurableDirectoryWin32(target: string): Promise<void> {
  const absolute = resolve(target)
  const root = parse(absolute).root
  await assertDirectory(root)

  const segments = absolute.slice(root.length).split(/[\\/]+/).filter(part => part.length > 0)
  let current = root
  for (const segment of segments) {

View on GitHub (pinned to b150a551b8)

Solutions

  1. Close handles to source and destination; check the Win32 error code and retry the move.

When it happens

Trigger: Thrown at packages/session/session-persistence-jsonl/src/win32.ts:119 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of deepseek-ai/deepseek-harness@b150a551b8 (2026-08-24). Data as JSON: /api/errors/af2a24861a7e4c71. Report an issue: GitHub.