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

[Errno 36] File name too long #7765

Open
UnveilTech opened this issue Dec 5, 2015 · 5 comments
Open

[Errno 36] File name too long #7765

UnveilTech opened this issue Dec 5, 2015 · 5 comments

Comments

@UnveilTech
Copy link

@UnveilTech UnveilTech commented Dec 5, 2015

Hi,

./youtube-dl --ignore-errors --no-playlist --all-formats "http://www.hardsextube.com/video/1152690/Lovely-Arabian-Muslim-Kareemah-fucked-by-Small-Four-Inch-Oriental-Arab-Dick-on-Webcam"
[generic] Lovely-Arabian-Muslim-Kareemah-fucked-by-Small-Four-Inch-Oriental-Arab-Dick-on-Webcam: Requesting header
WARNING: Falling back on generic information extractor.
[generic] Lovely-Arabian-Muslim-Kareemah-fucked-by-Small-Four-Inch-Oriental-Arab-Dick-on-Webcam: Downloading webpage
[generic] Lovely-Arabian-Muslim-Kareemah-fucked-by-Small-Four-Inch-Oriental-Arab-Dick-on-Webcam: Extracting information
ERROR: unable to open for writing: [Errno 36] File name too long: 'Lovely Arabian Muslim Kareemah fucked by Small Four Inch Oriental Arab Dick on Webcam - Hardsextube-s7krq56ztqlqv0bv3bcnm5c0hht455zA5n6687k84bzc4qx3y2q84wchgbnrcj8qzvk1vtzlqkAxzA6y5qb57Aq2cw8rrkgb2t6cfvpl2blm0pcnA5A9zAgA04Ahs3kgs3tfv6ykyh6qjl92d4tzhb536036h8dn912skkd1zqq4jp1wv51y4n003vcrjgl2rjwq3n155222hkshrv5zfpx28560jwpl66jnsh7z1jj36mAjkjq9dAdzqgAm207x57bn8n05pmh68b5xq82n39kpzft8w44lj40z69sch6p98gwAghsrt8lx5vzmcd7n8mAtd3s07dc0hsxstnsk5tsq4k427y0fk95gqjqyqvs1xdhg1l00c45bf0hvtlc4.unknown_video.part'

@agicquel
Copy link

@agicquel agicquel commented Jan 3, 2016

size doesn't matter ;)

@nicolas-raoul
Copy link

@nicolas-raoul nicolas-raoul commented Feb 20, 2016

Probably same issue as #5908
UnveilTech, I guess you have en encrypted home folder?

@Zefling
Copy link

@Zefling Zefling commented Jun 9, 2018

With long japanese title, I have this message:

[0.0%] 2018/06: Downloading video 1....ERROR: unable to open for writing: [Errno 36] File name too long: '\xe3\x80\x90\xe5\x85\xac\xe5\xbc\x8f\xe3\x80\x91TV\xe3\x82\xa2\xe3\x83\x8b\xe3\x83\xa1\xe3\x80\x8e\xe8\xbb\xa2\xe7\x94\x9f\xe3\x81\x97\xe3\x81\x9f\xe3\x82\x89\xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe3\x81\xa0\xe3\x81\xa3\xe3\x81\x9f\xe4\xbb\xb6\xe3\x80\x8f - \xe3\x80\x8e\xe8\xbb\xa2\xe7\x94\x9f\xe3\x81\x97\xe3\x81\x9f\xe3\x82\x89\xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe3\x81\xa0\xe3\x81\xa3\xe3\x81\x9f\xe4\xbb\xb6\xe3\x80\x8f2018\xe5\xb9\xb4\xe7\xa7\x8bTV\xe3\x82\xa2\xe3\x83\x8b\xe3\x83\xa1\xe6\x94\xbe\xe9\x80\x81\xe9\x96\x8b\xe5\xa7\x8b\xef\xbc\x81  \xef\xbd\x9e\xe3\x83\xaa\xe3\x83\xa0\xe3\x83\xab\xe6\xa7\x98\xe3\x81\xae\xe8\x8f\xaf\xe9\xba\x97\xe3\x81\xaa\xe3\x82\x8b\xe5\xa4\x89\xe8\xba\xab\xe3\x82\x92\xe3\x81\x94\xe8\xa6\xa7\xe3\x81\x8f\xe3\x81\xa0\xe3\x81\x95\xe3\x81\x84\xef\xbd\x9e  \xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe2\x87\x94\xe4\xba\xba\xe5\x9e\x8b  \xe5\x85\xac\xe5\xbc\x8f\xe3\x82\xb5\xe3\x82\xa4\xe3\x83\x88\xef\xbc\x9ahttps -_t.co_O5x8HRa0At  \xe5\xae\xa3\xe4\xbc\x9dT #\xe8\xbb\xa2\xe3\x82\xb9\xe3\x83\xa9-1004997002927616000.mp4.part'
ERROR: unable to open for writing: [Errno 36] File name too long: '\xe3\x80\x90\xe5\x85\xac\xe5\xbc\x8f\xe3\x80\x91TV\xe3\x82\xa2\xe3\x83\x8b\xe3\x83\xa1\xe3\x80\x8e\xe8\xbb\xa2\xe7\x94\x9f\xe3\x81\x97\xe3\x81\x9f\xe3\x82\x89\xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe3\x81\xa0\xe3\x81\xa3\xe3\x81\x9f\xe4\xbb\xb6\xe3\x80\x8f - \xe3\x80\x8e\xe8\xbb\xa2\xe7\x94\x9f\xe3\x81\x97\xe3\x81\x9f\xe3\x82\x89\xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe3\x81\xa0\xe3\x81\xa3\xe3\x81\x9f\xe4\xbb\xb6\xe3\x80\x8f2018\xe5\xb9\xb4\xe7\xa7\x8bTV\xe3\x82\xa2\xe3\x83\x8b\xe3\x83\xa1\xe6\x94\xbe\xe9\x80\x81\xe9\x96\x8b\xe5\xa7\x8b\xef\xbc\x81  \xef\xbd\x9e\xe3\x83\xaa\xe3\x83\xa0\xe3\x83\xab\xe6\xa7\x98\xe3\x81\xae\xe8\x8f\xaf\xe9\xba\x97\xe3\x81\xaa\xe3\x82\x8b\xe5\xa4\x89\xe8\xba\xab\xe3\x82\x92\xe3\x81\x94\xe8\xa6\xa7\xe3\x81\x8f\xe3\x81\xa0\xe3\x81\x95\xe3\x81\x84\xef\xbd\x9e  \xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe2\x87\x94\xe4\xba\xba\xe5\x9e\x8b  \xe5\x85\xac\xe5\xbc\x8f\xe3\x82\xb5\xe3\x82\xa4\xe3\x83\x88\xef\xbc\x9ahttps -_t.co_O5x8HRa0At  \xe5\xae\xa3\xe4\xbc\x9dT #\xe8\xbb\xa2\xe3\x82\xb9\xe3\x83\xa9-1004997002927616000.mp4.part'
[0.0%] 2018/06: Downloading video 1...ERROR: unable to open for writing: [Errno 36] File name too long: '\xe3\x80\x90\xe5\x85\xac\xe5\xbc\x8f\xe3\x80\x91TV\xe3\x82\xa2\xe3\x83\x8b\xe3\x83\xa1\xe3\x80\x8e\xe8\xbb\xa2\xe7\x94\x9f\xe3\x81\x97\xe3\x81\x9f\xe3\x82\x89\xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe3\x81\xa0\xe3\x81\xa3\xe3\x81\x9f\xe4\xbb\xb6\xe3\x80\x8f - \xe3\x80\x8e\xe8\xbb\xa2\xe7\x94\x9f\xe3\x81\x97\xe3\x81\x9f\xe3\x82\x89\xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe3\x81\xa0\xe3\x81\xa3\xe3\x81\x9f\xe4\xbb\xb6\xe3\x80\x8f2018\xe5\xb9\xb4\xe7\xa7\x8bTV\xe3\x82\xa2\xe3\x83\x8b\xe3\x83\xa1\xe6\x94\xbe\xe9\x80\x81\xe9\x96\x8b\xe5\xa7\x8b\xef\xbc\x81  \xef\xbd\x9e\xe3\x83\xaa\xe3\x83\xa0\xe3\x83\xab\xe6\xa7\x98\xe3\x81\xae\xe8\x8f\xaf\xe9\xba\x97\xe3\x81\xaa\xe3\x82\x8b\xe5\xa4\x89\xe8\xba\xab\xe3\x82\x92\xe3\x81\x94\xe8\xa6\xa7\xe3\x81\x8f\xe3\x81\xa0\xe3\x81\x95\xe3\x81\x84\xef\xbd\x9e  \xe3\x82\xb9\xe3\x83\xa9\xe3\x82\xa4\xe3\x83\xa0\xe2\x87\x94\xe4\xba\xba\xe5\x9e\x8b  \xe5\x85\xac\xe5\xbc\x8f\xe3\x82\xb5\xe3\x82\xa4\xe3\x83\x88\xef\xbc\x9ahttps -_t.co_O5x8HRa0At  \xe5\xae\xa3\xe4\xbc\x9dT #\xe8\xbb\xa2\xe3\x82\xb9\xe3\x83\xa9-1004997002927616000.mp4.part'
@ytdl-org ytdl-org deleted a comment from freett Aug 26, 2019
@temporaryrespite
Copy link

@temporaryrespite temporaryrespite commented Apr 27, 2020

Perhaps --restrict-filenames could be changed to also handle the case when filename is too long?

$ youtube-dl --restrict-filenames https://twitter.com/OlgaKay/status/1253444538166738944
[twitter] 1253444538166738944: Downloading guest token
[twitter] 1253444538166738944: Downloading JSON metadata
[twitter] 1253444538166738944: Downloading m3u8 information
ERROR: unable to open for writing: [Errno 36] File name too long: 'Olga_Kay_-_Dear_Internet_Let_s_color_together._19_days_of_quarantine_Get_a_set_for_yourself_and_gift_one_to_a_friend_to_join_you._Tag_us_so_we_can_reshape_MooshWalksJourney_Share_it_with_other_parents_KidActivities_ColoringBook-1253444538166738944.mp4.part'

workaround is to use --id:

$ youtube-dl --id --restrict-filenames https://twitter.com/OlgaKay/status/1253444538166738944
[twitter] 1253444538166738944: Downloading guest token
[twitter] 1253444538166738944: Downloading JSON metadata
[twitter] 1253444538166738944: Downloading m3u8 information
[download] Destination: 1253444538166738944.mp4
[download] 100% of 9.61MiB in 00:00
@TheStranjer TheStranjer mentioned this issue May 31, 2020
5 of 9 tasks complete
@daniells
Copy link

@daniells daniells commented Jun 1, 2020

This issue affects a large number of twitter videos as youtube-dl attempts to use the full tweet as the filename. EXT4, NTFS, and HFS support only 255 characters per filename, but the current max-tweet is 280 characters.

Truncating filenames to 255 characters (including extension) should fix "File name too long" in all conceivable use cases.

@ytdl-org ytdl-org locked and limited conversation to collaborators Jun 1, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
8 participants
@nicolas-raoul @Zefling @daniells @agicquel @UnveilTech @temporaryrespite and others
You can’t perform that action at this time.