You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
HOME_DIRECTORY passes NaN to fs.existsSync on macOS/Linux #247
On macOS and Linux, HOMEDRIVE and HOMEPATH env vars are undefined. The expression process.env.HOMEDRIVE + process.env.HOMEPATH evaluates to NaN (number), which is then passed to fs.existsSync().
Node 24 deprecated non-string arguments to fs.existsSync (DEP0187), and this triggers a deprecation warning which causes node:test to fail an entire AAT test file.
Location:lib/util/constants.js:17
exportconstHOME_DIRECTORY=[process.env.HOME,(process.env.HOMEDRIVE+process.env.HOMEPATH),// ← NaN on non-Windowsprocess.env.USERPROFILE,'/tmp','/temp'].filter(fs.existsSync)[0]
Suggested fix: Guard the concatenation and filter out non-string values before calling existsSync.
changed the title [-]Fix: HOME_DIRECTORY passes NaN to fs.existsSync on macOS/Linux[/-][+]HOME_DIRECTORY passes NaN to fs.existsSync on macOS/Linux[/+]on Mar 24, 2026
Activity
[-]Fix: HOME_DIRECTORY passes NaN to fs.existsSync on macOS/Linux[/-][+]HOME_DIRECTORY passes NaN to fs.existsSync on macOS/Linux[/+]