garzj / google-photos-migrate

A tool to fix EXIF data and recover filenames from a Google Photos takeout, preserving albums within the directory structure.
https://npmjs.com/package/google-photos-migrate
MIT License
104 stars 11 forks source link

[ISSUE] If Album title holds an Emji in its name, the script terminates #22

Closed MeMyselfAndAI2023 closed 7 months ago

MeMyselfAndAI2023 commented 8 months ago

I had an Album-title like "Someone somewhere 🥰"

On Windows, the script crashes when trying to mkdir such a directory.

Error-Output:

node:internal/fs/promises:769 return binding.mkdir(pathModule.toNamespacedPath(path), ^

Error: ENOENT: no such file or directory, mkdir at mkdir (node:internal/fs/promises:769:18) at _restructureAndProcess_1 (C:\Users\admin\AppData\Local\npm-cache_npx\ab500ac20a79f2a5\node_modules\google-photos-migrate\lib\dir\restructure-and-process.js:47:48) at _restructureAndProcess_1.next () at resume (C:\Users\admin\AppData\Local\npm-cache_npx\ab500ac20a79f2a5\node_modules\google-photos-migrate\lib\dir\restructure-and-process.js:20:44) at fulfill (C:\Users\admin\AppData\Local\npm-cache_npx\ab500ac20a79f2a5\node_modules\google-photos-migrate\lib\dir\restructure-and-process.js:22:31) { errno: -4058, code: 'ENOENT', syscall: 'mkdir' }

Node.js v20.9.0

How could that be fixed?

garzj commented 7 months ago

Seems like it's this issue, so downgrading to Node version <= v20.3.1 should fix it.

I recommend nvm for Windows: nvm use 20.3.1.