Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WinError 183 when embedding thumbnail in directory #24387

Closed
ProducerMatt opened this issue Mar 17, 2020 · 1 comment
Closed

WinError 183 when embedding thumbnail in directory #24387

ProducerMatt opened this issue Mar 17, 2020 · 1 comment

Comments

@ProducerMatt
Copy link

@ProducerMatt ProducerMatt commented Mar 17, 2020

Checklist

  • I'm reporting a broken site support issue bug (this is the bug report template)
  • I've verified that I'm running youtube-dl version 2020.03.08
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

Long location (bug)

PS C:\Users\Matt\bin> ./youtube-dl.exe -o "K:\_-ARCHIVE-_\Vinesauce_MainChannel\%(upload_date)s__%(title)s__%(id)s.%(ext
)s" --embed-thumbnail -v -i -f best https://www.youtube.com/watch?v=TSEP28c0psI 2>&1 > log.txt
youtube-dl.exe : [debug] System config: []
At line:1 char:17
+ ./youtube-dl.exe <<<<  -o "K:\_-ARCHIVE-_\Vinesauce_MainChannel\%(upload_date)s__%(title)s__%(id)s.%(ext)s" --embed-t
humbnail -v -i -f best https://www.youtube.com/watch?v=TSEP28c0psI 2>&1 > log.txt
    + CategoryInfo          : NotSpecified: ([debug] System config: []:String) [], RemoteException
    + FullyQualifiedErrorId : NativeCommandError
 
[debug] User config: []

[debug] Custom config: []

[debug] Command-line args: ['-o', 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\%(upload_date)s__%(title)s__%(id)s.%(ext)s',
 '--embed-thumbnail', '-v', '-i', '-f', 'best', 'https://www.youtube.com/watch?v=TSEP28c0psI']

[debug] Encodings: locale cp1252, fs mbcs, out cp1252, pref cp1252

[debug] youtube-dl version 2020.03.08

[debug] Python version 3.4.4 (CPython) - Windows-7-6.1.7601-SP1

[debug] exe versions: ffmpeg 3.4.1, ffprobe 3.4.1, phantomjs 2.1.1, rtmpdump 2.3

[debug] Proxy map: {}

[youtube] TSEP28c0psI: Downloading webpage
[youtube] TSEP28c0psI: Downloading thumbnail ...
[youtube] TSEP28c0psI: Writing thumbnail to: K:\_-ARCHIVE-_\Vinesauce_MainChannel\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.jpg
[debug] Invoking downloader on 'https://r1---sn-q4fl6ne7.googlevideo.com/videoplayback?expire=1584501408&ei=QD5xXoiGG4K8wQGR653oAw&ip=47.184.157.31&id=o-AH3WT5GfQ7qsysFjAD2oHk4ejT4IpOxAdCF0Y6_nCGhm&itag=22&source=youtube&requiressl=yes&mh=ZG&mm=31%2C29&mn=sn-q4fl6ne7%2Csn-q4flrnes&ms=au%2Crdu&mv=m&mvi=0&pl=14&initcwndbps=2010000&vprv=1&mime=video%2Fmp4&ratebypass=yes&dur=2249.293&lmt=1584181093203324&mt=1584479676&fvip=1&fexp=23842630%2C23882513&c=WEB&txp=5516222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cratebypass%2Cdur%2Clmt&sig=ADKhkGMwRAIgaz2evHOKibUsiX75gDG4a0E_c5BICDLkKpBHYEZ5wZ0CIGlFZBIZM3Nt_-_5r1GCAfAWQ22incpQ3a-9FJ2oIDmL&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ABSNjpQwRAIgHkd_dwBvk4F1Ki-XPz4EkfPsVErmMTG4OtK7hsU2z9UCIB2b5uGyPkACVIZtLv4F3BEe_sF-DxFyJ1gmLI8fo4en'
[download] Destination: K:\_-ARCHIVE-_\Vinesauce_MainChannel\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4

[download]   0.0% of 518.67MiB at Unknown speed ETA Unknown ETA
[download] 100% of 518.67MiB in 00:58                          
[atomicparsley] Adding thumbnail to "K:\_-ARCHIVE-_\Vinesauce_MainChannel\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4"
[debug] AtomicParsley command line: AtomicParsley "K:\_-ARCHIVE-_\Vinesauce_MainChannel\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4" --artwork "K:\_-ARCHIVE-_\Vinesauce_MainChannel\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.jpg" -o "K:\_-ARCHIVE-_\Vinesauce_MainChannel\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.temp.mp4"
ERROR: [WinError 183] Cannot create a file when that file already exists: 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\2020
0312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.temp.mp4' -> 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\2020031
2__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4'

Traceback (most recent call last):
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 808, in extract_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 863, in process_ie_result
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 1644, in process_video_result
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 2000, in process_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 2065, in post_process
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\postprocessor\embed
thumbnail.py", line 89, in run
FileExistsError: [WinError 183] Cannot create a file when that file already exists: 'K:\\_-ARCHIVE-_\\Vinesauce_MainCha
nnel\\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.temp.mp4' -> 'K:\\_-ARCHIVE-_\\Vinesauce_MainChanne
l\\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4'

Different, short location (no bug)

PS C:\Users\Matt\bin> ./youtube-dl.exe -o "C:\Users\Matt\bin\%(upload_date)s__%(title)s__%(id)s.%(ext)s" --embed-thumbna
il -v -i -f best https://www.youtube.com/watch?v=TSEP28c0psI 2>&1 > log.txt
youtube-dl.exe : [debug] System config: []
At line:1 char:17
+ ./youtube-dl.exe <<<<  -o "C:\Users\Matt\bin\%(upload_date)s__%(title)s__%(id)s.%(ext)s" --embed-thumbnail -v -i -f b
est https://www.youtube.com/watch?v=TSEP28c0psI 2>&1 > log.txt
    + CategoryInfo          : NotSpecified: ([debug] System config: []:String) [], RemoteException
    + FullyQualifiedErrorId : NativeCommandError
 
[debug] User config: []

[debug] Custom config: []

[debug] Command-line args: ['-o', 'C:\\Users\\Matt\\bin\\%(upload_date)s__%(title)s__%(id)s.%(ext)s', '--embed-thumbnai
l', '-v', '-i', '-f', 'best', 'https://www.youtube.com/watch?v=TSEP28c0psI']

[debug] Encodings: locale cp1252, fs mbcs, out cp1252, pref cp1252

[debug] youtube-dl version 2020.03.08

[debug] Python version 3.4.4 (CPython) - Windows-7-6.1.7601-SP1

[debug] exe versions: ffmpeg 3.4.1, ffprobe 3.4.1, phantomjs 2.1.1, rtmpdump 2.3

[debug] Proxy map: {}

[youtube] TSEP28c0psI: Downloading webpage
[youtube] TSEP28c0psI: Downloading thumbnail ...
[youtube] TSEP28c0psI: Writing thumbnail to: C:\Users\Matt\bin\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.jpg
[debug] Invoking downloader on 'https://r1---sn-q4flrnes.googlevideo.com/videoplayback?expire=1584501937&ei=UUBxXtPNDemLir4P2JmEuAs&ip=47.184.157.31&id=o-AAosWpDzaQYkaU5T1Guck10Cl-4k463NPK8nwZInGykO&itag=22&source=youtube&requiressl=yes&mh=ZG&mm=31%2C26&mn=sn-q4flrnes%2Csn-vgqsdn7s&ms=au%2Conr&mv=m&mvi=0&pl=14&initcwndbps=1946250&vprv=1&mime=video%2Fmp4&ratebypass=yes&dur=2249.293&lmt=1584181093203324&mt=1584480276&fvip=1&fexp=23842630&c=WEB&txp=5516222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cratebypass%2Cdur%2Clmt&sig=ADKhkGMwRQIhAMYGqHrqbJb0CkRqCQklu8yIWvhXwcdqOtJj08iajFazAiA-9oURpkRAJv5F8gzqYM67IINffJwo7AqjbZljXruoVg%3D%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ABSNjpQwRQIgcKYt-VwE6p9iDBBrmkPBTPnQBfInzFTEHSKxE9wbrOsCIQDTcG9hompfxmeq7Id4oNhjyZwVtgJitDN5u0ylzB76vg%3D%3D'
[download] Destination: C:\Users\Matt\bin\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4

[download]   0.0% of 518.67MiB at Unknown speed ETA Unknown ETA
[download] 100% of 518.67MiB in 00:57                          
[atomicparsley] Adding thumbnail to "C:\Users\Matt\bin\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4"
[debug] AtomicParsley command line: AtomicParsley "C:\Users\Matt\bin\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.mp4" --artwork "C:\Users\Matt\bin\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.jpg" -o "C:\Users\Matt\bin\20200312__[Vinesauce] Vinny - Minecraft (PART 2)__TSEP28c0psI.temp.mp4"

Tiny filename in same long directory (bug):

youtube-dl.exe : [debug] System config: []
At line:1 char:17
+ ./youtube-dl.exe <<<<  -o "K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.%(ext)s" --embed-thumbnail -v -i -f best https://ww
w.youtube.com/watch?v=TSEP28c0psI 2>&1 > log.txt
    + CategoryInfo          : NotSpecified: ([debug] System config: []:String) [], RemoteException
    + FullyQualifiedErrorId : NativeCommandError
 
[debug] User config: []

[debug] Custom config: []

[debug] Command-line args: ['-o', 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\a.%(ext)s', '--embed-thumbnail', '-v', '-i',
 '-f', 'best', 'https://www.youtube.com/watch?v=TSEP28c0psI']

[debug] Encodings: locale cp1252, fs mbcs, out cp1252, pref cp1252

[debug] youtube-dl version 2020.03.08

[debug] Python version 3.4.4 (CPython) - Windows-7-6.1.7601-SP1

[debug] exe versions: ffmpeg 3.4.1, ffprobe 3.4.1, phantomjs 2.1.1, rtmpdump 2.3

[debug] Proxy map: {}

[youtube] TSEP28c0psI: Downloading webpage
[youtube] TSEP28c0psI: Downloading thumbnail ...
[youtube] TSEP28c0psI: Writing thumbnail to: K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.jpg
[debug] Invoking downloader on 'https://r1---sn-q4flrnes.googlevideo.com/videoplayback?expire=1584502224&ei=cEFxXt_zEsGEwQHppKSACw&ip=47.184.157.31&id=o-AJDLor1GzFXLGHdI6PiFToHenGs0JbfC_Z5s4RN0W8VL&itag=22&source=youtube&requiressl=yes&mh=ZG&mm=31%2C29&mn=sn-q4flrnes%2Csn-q4fl6ne7&ms=au%2Crdu&mv=m&mvi=0&pl=14&initcwndbps=1807500&vprv=1&mime=video%2Fmp4&ratebypass=yes&dur=2249.293&lmt=1584181093203324&mt=1584480518&fvip=1&fexp=23842630&c=WEB&txp=5516222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cratebypass%2Cdur%2Clmt&sig=ADKhkGMwRgIhAKaep9-VftaxzBxeNejYEMMjtwbLKIcZxtAz5Vj54SdIAiEAuROS7YmZ__tgmMH5RTgb8IWIKzYSxxTw3aESdr6te5E%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ABSNjpQwRQIgfBb5Wl1ydIOWuBg3BTWP8raussSpVeMwOYSaSK0ROZsCIQCPh5tYYNzX0Oj0YCyshSWfVSFdb4WZH9U4D_00v64-iw%3D%3D'
[download] Destination: K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.mp4

[download]   0.0% of 518.67MiB at 83.33KiB/s ETA 01:46:13
[download] 100% of 518.67MiB in 00:53                    
[atomicparsley] Adding thumbnail to "K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.mp4"
[debug] AtomicParsley command line: AtomicParsley "K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.mp4" --artwork "K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.jpg" -o "K:\_-ARCHIVE-_\Vinesauce_MainChannel\a.temp.mp4"
ERROR: [WinError 183] Cannot create a file when that file already exists: 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\a.te
mp.mp4' -> 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\a.mp4'

Traceback (most recent call last):
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 808, in extract_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 863, in process_ie_result
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 1644, in process_video_result
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 2000, in process_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\YoutubeDL.py", line
 2065, in post_process
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmp378onz6j\build\youtube_dl\postprocessor\embed
thumbnail.py", line 89, in run
FileExistsError: [WinError 183] Cannot create a file when that file already exists: 'K:\\_-ARCHIVE-_\\Vinesauce_MainCha
nnel\\a.temp.mp4' -> 'K:\\_-ARCHIVE-_\\Vinesauce_MainChannel\\a.mp4'

Tiny filename in root of hard disk (no bug):

youtube-dl.exe : [debug] System config: []
At line:1 char:17
+ ./youtube-dl.exe <<<<  -o "K:\a.%(ext)s" --embed-thumbnail -v -i -f best https://www.youtube.com/watch?v=TSEP28c0psI 
2>&1 > log.txt
    + CategoryInfo          : NotSpecified: ([debug] System config: []:String) [], RemoteException
    + FullyQualifiedErrorId : NativeCommandError
 
[debug] User config: []

[debug] Custom config: []

[debug] Command-line args: ['-o', 'K:\\a.%(ext)s', '--embed-thumbnail', '-v', '-i', '-f', 'best', 'https://www.youtube.
com/watch?v=TSEP28c0psI']

[debug] Encodings: locale cp1252, fs mbcs, out cp1252, pref cp1252

[debug] youtube-dl version 2020.03.08

[debug] Python version 3.4.4 (CPython) - Windows-7-6.1.7601-SP1

[debug] exe versions: ffmpeg 3.4.1, ffprobe 3.4.1, phantomjs 2.1.1, rtmpdump 2.3

[debug] Proxy map: {}

[youtube] TSEP28c0psI: Downloading webpage
[youtube] TSEP28c0psI: Downloading thumbnail ...
[youtube] TSEP28c0psI: Writing thumbnail to: K:\a.jpg
[debug] Invoking downloader on 'https://r1---sn-q4flrnes.googlevideo.com/videoplayback?expire=1584503205&ei=RUVxXtqSBovZigTI8KPYCQ&ip=47.184.157.31&id=o-ABwdEKqGqn5F4czkZjzlSMSZbAWUOcfr2-Gedomfra5_&itag=22&source=youtube&requiressl=yes&mh=ZG&mm=31%2C29&mn=sn-q4flrnes%2Csn-q4fl6ne7&ms=au%2Crdu&mv=m&mvi=0&pl=14&initcwndbps=2008750&vprv=1&mime=video%2Fmp4&ratebypass=yes&dur=2249.293&lmt=1584181093203324&mt=1584481481&fvip=1&fexp=23842630&c=WEB&txp=5516222&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cvprv%2Cmime%2Cratebypass%2Cdur%2Clmt&sig=ADKhkGMwRQIgR8uYpgRS8jyzSaTMdkkhSEOFqncizNWPrTQZXD2ftO0CIQDW6_gQIs-CsMA-SFgxMwzlG5SS8tMVaj2_hUD_4mt4xA%3D%3D&lsparams=mh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Cinitcwndbps&lsig=ABSNjpQwRAIgRg9mHVz-hHYx5UjwnQ8W7s4AYuIz-Vwfg4ajUnxpaJICIFkA4aRHBx4Zg9WFzvyxixFUov6u_gDSD3Y47xg8l6Hi'
[download] Destination: K:\a.mp4

[download]   0.0% of 518.67MiB at Unknown speed ETA Unknown ETA
[download] 100% of 518.67MiB in 00:55                          
[atomicparsley] Adding thumbnail to "K:\a.mp4"
[debug] AtomicParsley command line: AtomicParsley "K:\a.mp4" --artwork "K:\a.jpg" -o "K:\a.temp.mp4"

Description

This error started happening a couple weeks ago after updating, and I'm really stumped. When a thumbnail embed is requested in my archive folder, an error occurs. Something like:

ERROR: [WinError 183] Cannot create a file when that file already exists: 'coolvideo.temp.mp4' -> 'coolvideo.mp4'

two files remain: coolvideo.temp.mp4 file, and the thumbnail.jpg. The file that "already exists," coolvideo.mp4, does not exist anywhere. It's not totally clear to me whether the error is from AtomicParsley or Youtube-DL.

I made sure my config file is empty.

I wonder whether the underscores and dashes in the directory path are tripping stuff up when they weren't before.

I wish I had more info for you. After investigating the bug for a couple hours and rewriting this post several times, I'm stuck and don't know how to proceed, and I'm not able to finish archiving work with this bug in place. I would appreciate your help.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Mar 20, 2020

Something creates files after youtube-dl deletes them. Most likely due to K:\_-ARCHIVE-_\ being monitored by DropBox or similar software. Nothing to do with youtube-dl.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.