screenshot-to-code icon indicating copy to clipboard operation
screenshot-to-code copied to clipboard

error generate error

Open OfficialTooFastHub opened this issue 1 year ago • 12 comments

Describe the bug everything work well and looks well but it came out error generating code while i drop a screenshot

To Reproduce Steps to reproduce the behavior:

  1. Go to 'local host '
  2. Drag the screenshot
  3. Start Generating
  4. See error

Screenshots of backend AND frontend terminal logs If applicable, add screenshots to help explain your problem. Screenshot 2024-09-26 234546 Screenshot 2024-09-26 235009 Screenshot 2024-09-26 235052

OfficialTooFastHub avatar Sep 26 '24 15:09 OfficialTooFastHub

Thanks for the screenshots. Have you added a Anthropic API key?

Screenshot 2024-09-30 at 11 59 23 AM

But maybe your logs include multiple attempts. Looks like maybe even just screenshot without video is not working?

Can you let me know which keys you have set up? It's a little weird that we're not seeing any exception stack traces in your logs.

abi avatar Sep 30 '24 10:09 abi

I just added chat gpt API key, didn't add Anthropic API key,does it require two keys to work?

OfficialTooFastHub avatar Sep 30 '24 12:09 OfficialTooFastHub

No, for screenshots, just OpenAI API key should be okay. Per your logs, it looks like you have the Anthropic key set though.

Screenshot 2024-09-30 at 2 56 24 PM

Can you make sure to clear out any keys in the Anthropic section and only keep OpenAI keys?

abi avatar Sep 30 '24 12:09 abi

Screenshot 2024-10-03 164619 still same,i clear out anthropic and kepp openai keys,but it still not working

OfficialTooFastHub avatar Oct 03 '24 08:10 OfficialTooFastHub

Hi, can you share your backend logs after you did this?

abi avatar Oct 05 '24 08:10 abi

Screenshot 2024-10-06 002627 Screenshot 2024-10-06 002615 here is it,i think there is some error

OfficialTooFastHub avatar Oct 05 '24 16:10 OfficialTooFastHub

Hi @OfficialTooFastHub this looks to be a different error.

Try downgrading your Python to python:3.12.3 or lower. The new version of Pydantic has some issues with the later Python versions.

Let me know if that works.

abi avatar Oct 08 '24 12:10 abi

@abi yo i download python 3.12.3,but the error still coming out Screenshot 2024-10-08 211303 Screenshot 2024-10-08 211253

OfficialTooFastHub avatar Oct 08 '24 13:10 OfficialTooFastHub

If you look at the second error, you can see that your API key is wrong.

abi avatar Oct 08 '24 13:10 abi

ill try again

OfficialTooFastHub avatar Oct 08 '24 13:10 OfficialTooFastHub

should i keep the "" in the key section

OfficialTooFastHub avatar Oct 08 '24 13:10 OfficialTooFastHub

@OfficialTooFastHub Nope, but I'm not sure that's the problem. It seems to be reading it without the quotes.

Screenshot 2024-10-08 at 10 03 04 AM

abi avatar Oct 08 '24 14:10 abi