yafp / media-dupes

a minimal content duplicator for common media services like youtube

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[bug] Updating youtube-dl fails because of permission issues

hitman05 opened this issue · comments

Error: EPERM: operation not permitted, open 'C:\Program Files\media-dupes\resources\app\node_modules\youtube-dl\bin\details'
    at Object.openSync (fs.js:440:3)
    at Object.func (electron/js2c/asar.js:140:31)
    at Object.func [as openSync] (electron/js2c/asar.js:140:31)
    at Object.writeFileSync (fs.js:1265:35)
    at error (C:\Program Files\media-dupes\resources\app\node_modules\youtube-dl\lib\downloader.js:79:8)
    at Request.end (C:\Program Files\media-dupes\resources\app\node_modules\youtube-dl\lib\downloader.js:55:7)
    at Request.emit (events.js:215:7)
    at Request.EventEmitter.emit (domain.js:476:20)
    at IncomingMessage.<anonymous> (C:\Program Files\media-dupes\resources\app\node_modules\request\request.js:1083:12)
    at Object.onceWrapper (events.js:299:28)
    at IncomingMessage.emit (events.js:215:7)
    at IncomingMessage.EventEmitter.emit (domain.js:476:20)
    at endReadableNT (_stream_readable.js:1183:12)
    at processTicksAndRejections (internal/process/task_queues.js:80:21)

media-dupes 0.6.0
Electron 8.1.0
win32 10.0.19041
Locale: en-US

Thank you very much for your first issue to this project. It is much appreciated.

commented

@hitman05
first of all - thanks for reporting this issue.

For me it looks like you have tried updating the bundled youtube-dl version.
While trying to update the files - this failed, most likely because the file was not writeable.

till now I thought media-dupes is checking the permission situation before even offering an update for youtube-dl ... but it seems like i am wrong. Sorry

Am i assuming right that you used the installer and installed media-dupes for all users on your system?

Greetings
yafp

commented

Gonna fix that in the upcoming version 0.7.0.

Until then you can handle the problem as follows:

  • either use the portable version
  • or install media-dupes using the installer only user-specific
  • or don't try to update youtube-dl

Sorry - but the real fix can only be realized with an update from my side.

commented

todo:

  • Settings dialog should disable the update button - if details file is not writeable.
  • each check for youtube-dl updates should check first if details file is writeable - and only continue if it is.
commented

Its kinda hard for me to test this - as i don't have a windows machine myself.
I guess i fixed it - i can't reproduce this issue at linux ... let's see ;)

Greetings
fidel