Note:This post is just for educational purpose to show the use of Webscraping.
Have you ever been in a situation like, you are having you final e...
For further actions, you may consider blocking this person and/or reporting abuse
Cool post! If you're on a mac, you can easily copy the link of a youtube video or a playlist and use
youtube-dl
, a command line tool to download videos on youtube.Very cool exercise! Have you heard of the venerable youtube-dl project? It already supports playlists and many others. It’s written with python to boot!
ytdl-org.github.io/youtube-dl/inde...
Yep, that's a great-one. But pytube helps in understanding Webscraping better,so tried this approach.
Is downloading YouTube videos Legal ?
Although the post is for educational purpose, just to show Webscraping use,in the copyright infringement that surrounds certain YouTube videos, it is the uploader who is technically the copyright violator because he/she is publishing. So if you try to own a video that's illegal. Works fine till you keep things to yourself and that's too illegal. But YouTube hasn't taken any actions till date about it.
Cool alternative to youtube-dl. Thanks for creating this, will have to explore this down the road.
:) Thank you. Surely this could be improved in so many better ways.
Thanks for this tutorial Trideep! Any reason why you used BeautifuSoup instead of Scrapy?
Just because this post was for beginners just to make them acquainted with Webscraping and also that Beautiful Soup does the work in few lines and easier to understand.
Just so you know, it's actually spelled "web scraping," not "web scrapping."
So sorry about that and Thanks a lot.
No big deal. I'm just trying to help you out. You wrote a great article, so thank you for writing it.
You can also use a program called YouTube-DLG
That's a good choice. But I wanted to show the use of Webscraping in a project for beginners so I preffered pytube.
Really good post, thanks Trideep. Will definitely try it.
~Akshat
Thank you :)
Hey. Is this still working? I don't know how you are using beautifulsoup to a playlist which depends upon javascript to form its page. I tried your code upto part-2 and it doesn't work.
Works for me. Javascript generates playlist but in the end every website is built with HTML files. You can go for the repository mentioned in the end.
Well look at the image I attached then. Also pytube isn't properly functional either. Its not updated and have multiple issues. A beginner might get more frustrated trying to debug.
dev-to-uploads.s3.amazonaws.com/i/...
You can use this tool omkar.cloud/tools/youtube-playlist...
which does the same job
Really liked this tutorial, I was searching for something like this.
One question though, why are there duplicates in the "playlist" list?
You might have observed, that you can open a video by clicking the thumbnail or by clicking the title of the video. So there are two same links for each video. The scraper scraps both the links and thus that has a duplicate link in the "playlist". Later that can be corrected by just converting list to set. :)
Oh! Thanks for clearing that up.
There is difference between, Browser downloading and You downloading manually using some software or code. :)
Never knew that. Thanks for the information.