Code Monkey home page Code Monkey logo

Comments (58)

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024 1

Yeah, great
Looks like the error has gone away

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Hey, I've almost solved this...there will not be any timeout issue...But the problem is heroku free dyno contains limited storage . Since the "download_single_video()" function first download the video and then send the file, so if video size is larger than free dyno storage, new error occurs. @ashutoshkrris

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Could you share some code?

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Okay....please tell on file yt_downloader.py , line 20 , what does this code do :
# If 1080p vid = video.download() os.rename(vid, "video.mp4") audio = url.streams.get_audio_only() aud = audio.download() os.rename(aud, "audio.mp4") os.system("ffmpeg -y -i video.mp4 -i audio.mp4 -c:v copy -c:a aac out.mp4 -loglevel quiet -stats") os.remove("audio.mp4") os.remove("video.mp4") @ashutoshkrris

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

See, sometimes, if we download high quality videos, the audio won't be there.
So, we are downloading the video in 1080p and the audio separately. Afterward, we are merging them using ffmpeg.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Oh...so you have uploaded "ffmpeg" file with codes on heroku?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Yeah, that's working.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Okay, then i can fix #35....but there is high chances of getting error if video size becomes larger than heroku free plan storage......So i think there is no way to get rid of this on heroku except increasing your budget for hosting!

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Haha
You can start working on it. For the time being, we can limit the video size to 150-200MBs. If any day we get enough support, we'll be hosting the application on AWS.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Sure, please share any idea, resources if you have for " how to continuously check if data is available to load and display on web page". I think this can be done using javascript or Ajax script on frontend part but don't know how to do!

This function will be used to show alert on user interface when file will be available to download

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

That's where I was stuck too. The video was getting downloaded in the background, but unable to send it to the user.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Inkedout_LI

I've able to send the file to client after downloading process get completed in background but there involves continuous checking process whether data is available or not since I don't know javascript. So, to do this one should have good experience of javascript , Ajax etc. But i would find a way later to achieve this.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Hey @ashutoshkrris , you can assign me this issue.....I've solved it......everything working working file .........but one minor problem I'm facing >> Thread is not running in heroku due to not knowing how to write Procfile for that.....could u help me in this?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Go ahead! Assigning it to you.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

i tried both in Procfile :
`web: gunicorn --worker-class eventlet -w 1 main:app

web: gunicorn -w 1 --threads 100 main:app`

but still not running the thread in heroku......could u help me in this case? In local environment everything working perfectly.

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

I'm looking for some references too.

For now, can you try these:

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

In my case , thread should be executed only, when user click on download button .....not in before first request

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

I've created a development branch, whenever you push your code, push it to the development branch
I'll deploy the development branch, and we'll be able to make changes and test without hampering the production server

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

I've fixed this bug today completely .....now how do i have to push it in the new branch and if i send pull request and if get merged then will it be counted today by hacktoberfest community? @ashutoshkrris

on production Video finding is not working , showing this "Unable to fetch the video from YouTube " error

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

When you are making the Pull request, you will see an option to select the branch. Choose the development branch

And yes, it will be counted towards Hacktoberfest
You make the PR, let's debug it down completely

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Okay, Please keep checking github frequently tonight up to 11.59 pm. I will try to send PR as soon as possible......now assembling all parts.

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Yep sure.
Go ahead!

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Hey @ashutoshkrris , please check its working perfectly https://bbb-task.herokuapp.com ....now no issue of request time out....but if video size is larger than heroku free storage , only then it will show error.........otherwise it works well

Your current production fails to load video from youtube....after merging it might show error so i think you need to fix it first.

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Can you find out the bug in the code?
If you find it, create an issue and work on it.

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Did you check it? https://bbb-task.herokuapp.com

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Yeahhh!!
Works perfectly!!

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

issue

See, you are trying to download large size video than the existing storage size ....that's why it's not working!....

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Yeah
I tried it..
So, we can set a limit of around 200 MBs

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Yeah, Sure

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

And when you are testing in on localhost .....don't forget to set 'https' to 'http' and vice-versa for prod.....in download.html file of youtube

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Alright

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Hey , where should do PR : on main or development?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Main branch

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Now showing this....."This branch has conflicts that must be resolved"

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Did you make the PR?
I suppose you did it in your own repo

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Omg.....how to do this correctly?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Go to your repo.
You will find an option to create pull request.
In the next page, make sure you are making the Pull request to my repo

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

okay

Are u taking about to select like this?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Yes

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Please resolve the conflict

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Yes, I'll do it and merge the PR

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Thank you so much brother 👍

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

In my Hactoberfest profile , it is showing "project not participating". Why?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Can you show a screenshot?

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

hac

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Haha
That's not my Repository
That's yours.. it's showing there bcz you made a PR on your repo too

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Ohh..i didn't notice the username...how silly i am!

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Will u merge it by today?

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

I'll merge it today
That won't affect your Hacktoberfest Contribution anyway..
It will still be valid

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

@ThisIsBBBGithubAc there's a bug
The bug for which I had to use ffmpeg

If we download a 1080p video, there's no audio.
That's why we need to download audio and video separately and merge them using ffmpeg

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Ahh, okay!
I'll do it

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Hey @ashutoshkrris , what's this coming again and again in my email......could you please help me in stopping this?
Screenshot 2021-11-15 114937

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

This is due to the slash-assign bot action.
You can delete the .github directory

from eazyloader.

ashutoshkrris avatar ashutoshkrris commented on September 24, 2024

Hey @ThisIsBBBGithubAc
Pinging you for a help
I have created a Slideshare downloader.
The problem is related to websockets. Can the same websocket handle two background processes, like one for downloading youtube video and other for downloading slideshare project?
Please check the slideshare branch

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

from eazyloader.

BidyutBikashBharali avatar BidyutBikashBharali commented on September 24, 2024

Yes, Of course it can ...we just need to launch another thread.

from eazyloader.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.