Coder Social home page Coder Social logo

Error: 'videos' about moneyprinter HOT 11 CLOSED

fujiwarachoki avatar fujiwarachoki commented on July 18, 2024
Error: 'videos'

from moneyprinter.

Comments (11)

Salty-Coder avatar Salty-Coder commented on July 18, 2024 1

I believe the problem lies here
image

from moneyprinter.

FujiwaraChoki avatar FujiwaraChoki commented on July 18, 2024

I am aware that people have been experiencing this problem, could you show me your .env file? You can censor out the sensitive parts.

from moneyprinter.

FujiwaraChoki avatar FujiwaraChoki commented on July 18, 2024

I added some error handling, can you pull, and see if the error still resides? If yes, what is the output?

# Get first video url
    try:
        video_urls = response["videos"][0]["video_files"]
    except:
        print(colored("[-] No Videos found.", "red"))
        print(colored(response, "red"))
    video_url = ""

from moneyprinter.

Salty-Coder avatar Salty-Coder commented on July 18, 2024

Now getting this error:
image

Possibly an issue with my API key?

from moneyprinter.

Salty-Coder avatar Salty-Coder commented on July 18, 2024

I am aware that people have been experiencing this problem, could you show me your .env file? You can censor out the sensitive parts.

image

from moneyprinter.

Salty-Coder avatar Salty-Coder commented on July 18, 2024

image
The program doesn't pass any auth key to search.py.

os.getenv("PEXELS_API_KEY") returns None

from moneyprinter.

FujiwaraChoki avatar FujiwaraChoki commented on July 18, 2024

image

What is the name of your env file? It should be exactly: .env

Also, your IMAGEMAGICK_BINARY variable should point to either convert.exe or magick.exe, hence binary.

I'm not familiar how this works with the portable version, so I recommend going through the installer and setting everything up.

from moneyprinter.

Salty-Coder avatar Salty-Coder commented on July 18, 2024

image

What is the name of your env file? It should be exactly: .env

Also, your IMAGEMAGICK_BINARY variable should point to either convert.exe or magick.exe, hence binary.

I'm not familiar how this works with the portable version, so I recommend going through the installer and setting everything up.

My env file is named .env.
I found that the program failed to locate Imagemagick unless I specified the folder path rather than the executable path.

I got it working by just hardcoding my API key into the program.
I then ran into errors with light_cyan so just replaced light_cyan terminal coloring to cyan.

I'm closer, but still not there yet.
image

from moneyprinter.

FujiwaraChoki avatar FujiwaraChoki commented on July 18, 2024

It failed to locate your ImageMagick executable because you didn't use double backslash, so you need to use \\ instead of \.
light_cyan unfortunately doesn't work in the Windows Command-line, which is kind of bizarre. I have changed it to cyan.

You should read the instructions carefully again, as it seems like something is wrong in the folder structure, one possible issue is that your .env file is located in the backend directory.

It's likely this is where your process fails:

        # Put everything together
        final_video_path = generate_video(combined_video_path, tts_path, subtitles_path) # One of the provided parameters is probably None

There's nothing wrong with the code itself, so can I ask you to run the tree command and show me it's output?

from moneyprinter.

Salty-Coder avatar Salty-Coder commented on July 18, 2024

Double backslash fixed that issue.
I fixed the folder structure issue by running the program directly from /Backend. I had previously run py Backend\main.py from the root directory to try to debug the previous env issue, which caused that problem.

Thank you for your help

from moneyprinter.

FujiwaraChoki avatar FujiwaraChoki commented on July 18, 2024

Oh well, at least you found the solution. No problem, always!

from moneyprinter.

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.