affaan-m/ECC · error · Error
Nasiko install directory must be a real directory, not a sym
Error message
Nasiko install directory must be a real directory, not a symlink.
What it means
validateInstallDirectory (via the symlink check in the Nasiko install path) found the candidate install directory resolves through a symlink. The installer requires a real directory so path-based ownership and permissions checks cannot be bypassed by a symlinked path.
Source
Thrown at scripts/lib/nasiko-release.js:158
function validateInstallDirectory(directory) {
if (typeof directory !== 'string' || directory.includes('\0') || !path.isAbsolute(directory)) throw new Error('Nasiko install directory must be an absolute path.');
if (/^(?:\\\\|\\\\\?\\|\\\\\.\\)/.test(directory)) throw new Error('Nasiko install directory must be on a local filesystem.');
const resolved = path.resolve(directory);
if (resolved === path.parse(resolved).root) throw new Error('Nasiko cannot install directly into a filesystem root.');
let ancestor = resolved;
while (!fs.existsSync(ancestor)) {
const parent = path.dirname(ancestor);
if (parent === ancestor) throw new Error('Nasiko install directory has no resolvable filesystem ancestor.');
ancestor = parent;
}
const canonical = fs.realpathSync(ancestor);
return path.join(canonical, path.relative(ancestor, resolved));
}
function assertPrivateInstallDirectory(directory) {
const stats = fs.lstatSync(directory);
if (!stats.isDirectory() || stats.isSymbolicLink()) throw new Error('Nasiko install directory must be a real directory, not a symlink.');
if (process.platform !== 'win32') {
if (typeof process.getuid === 'function' && stats.uid !== process.getuid()) throw new Error('Nasiko install directory must be owned by the current user.');
if ((stats.mode & 0o022) !== 0) throw new Error('Nasiko install directory must not be group- or world-writable.');
}
}
function metadataPathFor(executable) { return path.join(path.dirname(executable), METADATA_FILENAME); }
function readBoundedRegularFile(filePath, maximumBytes) {
const noFollow = fs.constants.O_NOFOLLOW;
const descriptor = fs.openSync(filePath, fs.constants.O_RDONLY | (noFollow || 0));
try {
const stats = fs.fstatSync(descriptor);
if (!stats.isFile() || stats.size <= 0 || stats.size > maximumBytes) return null;
if (!noFollow) {
const pathStats = fs.lstatSync(filePath);
if (pathStats.isSymbolicLink()
|| pathStats.dev !== stats.devView on GitHub (pinned to 06c5e118c4)
Solutions
- Provide a value that satisfies the validation: Nasiko install directory must be a real directory, not a symlink.
- 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.
Example fix
Correct the invalid input so that the following holds: Nasiko install directory must be a real directory, not a symlink.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at scripts/lib/nasiko-release.js:158 when the library encounters an invalid state.
Common situations: Raised when input validation fails because: Nasiko install directory must be a real directory, not a symlink.. Typically caused by a missing, malformed, or out-of-range argument or configuration value.
AI-assisted analysis of affaan-m/ECC@06c5e118c4 (2026-08-18).
Data as JSON: /api/errors/84dce8798400e3fb.
Report an issue: GitHub.