{"record":{"id":"c37d3fa0262e3fa4","repo":"affaan-m/ECC","slug":"published-nasiko-binary-size-mismatch","errorCode":null,"errorMessage":"Published Nasiko binary size mismatch.","messagePattern":"Published Nasiko binary size mismatch\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"scripts/lib/nasiko-release.js","lineNumber":288,"sourceCode":"      if (existing.qualified && existing.version === version) return { ...plan, dryRun: false, installed: true, reused: true };\n      throw new Error('An unqualified or incompatible Nasiko executable or receipt already exists at the destination.');\n    }\n    const retrieve = dependencies.fetchBytes || fetchBytes;\n    const manifestBytes = await retrieve(`${REGISTRY_ORIGIN}/v2/${REPOSITORY}/manifests/${release.manifestDigest}`, { accept: 'application/vnd.oci.image.manifest.v1+json', maxBytes: MAX_MANIFEST_BYTES });\n    assertDigest(manifestBytes, release.manifestDigest, 'Nasiko manifest');\n    const layer = validateManifest(manifestBytes);\n    const archiveBytes = await retrieve(`${REGISTRY_ORIGIN}/v2/${REPOSITORY}/blobs/${layer.digest}`, { maxBytes: MAX_ARCHIVE_BYTES });\n    if (archiveBytes.length !== layer.size) throw new Error('Nasiko archive size mismatch.');\n    assertDigest(archiveBytes, layer.digest, 'Nasiko archive');\n    const binary = (dependencies.extractBinary || extractQualifiedTarGzip)(archiveBytes, release.binaryName);\n    assertDigest(binary, release.binaryDigest, 'Nasiko binary');\n    if (dependencies.beforePublish) dependencies.beforePublish(destination);\n    const descriptor = fs.openSync(destination, 'wx', 0o700);\n    destinationOwned = true;\n    try {\n      fs.writeFileSync(descriptor, binary);\n      fs.fsyncSync(descriptor);\n      if (fs.fstatSync(descriptor).size !== binary.length) throw new Error('Published Nasiko binary size mismatch.');\n    } finally { fs.closeSync(descriptor); }\n    const metadata = { version, platform: release.os, architecture: release.arch, manifestDigest: release.manifestDigest, artifactDigest: layer.digest, binaryDigest: release.binaryDigest, installedPath: destination, license: release.license, sourceUrl: release.sourceUrl };\n    (dependencies.writeMetadata || writeMetadataExclusive)(metadataPath, metadata);\n    metadataOwned = true;\n    return { ...plan, dryRun: false, installed: true, reused: false, artifactDigest: layer.digest };\n  } catch (error) {\n    if (metadataOwned) fs.rmSync(metadataPath, { force: true });\n    if (destinationOwned) fs.rmSync(destination, { force: true });\n    throw error;\n  } finally { releaseLock(); }\n}\n\nfunction uninstallNasiko(options = {}, dependencies = {}) {\n  const version = options.version || 'v0.1.0';\n  const release = getQualifiedRelease(version, dependencies.platform || process.platform, dependencies.arch || process.arch);\n  const installDirectory = validateInstallDirectory(options.installDir || defaultInstallDirectory(release, dependencies.environment || process.env, dependencies.homeDirectory || os.homedir()));\n  const destination = path.join(installDirectory, release.binaryName);\n  const plan = { dryRun: Boolean(options.dryRun), version, destination };","sourceCodeStart":270,"sourceCodeEnd":306,"githubUrl":"https://github.com/affaan-m/ECC/blob/06c5e118c4d3e6c3b7f9445f973a2194c82de193/scripts/lib/nasiko-release.js#L270-L306","documentation":"The published Nasiko binary layer's size does not match what the qualified release metadata declares. This is a pinned-release integrity check: the registry content and the ECC-qualified manifest disagree, so the artifact is not trusted.","triggerScenarios":"Thrown at scripts/lib/nasiko-release.js:288 when the library encounters an invalid state.","commonSituations":"Raised when input validation fails because: Published Nasiko binary size mismatch.. Typically caused by a missing, malformed, or out-of-range argument or configuration value.","solutions":["Provide a value that satisfies the validation: Published Nasiko binary size mismatch.","Check the calling command or configuration for the reported field and correct it, then retry.","Run the command with --help to review the expected input shape and allowed values."],"exampleFix":"Correct the invalid input so that the following holds: Published Nasiko binary size mismatch.","handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"06c5e118c4d3e6c3b7f9445f973a2194c82de193","analyzedAt":"2026-08-18T11:27:13.915Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}