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

Script breaks if result has an empty percentage #16

Open
OuterNeptunium opened this issue Jul 18, 2021 · 2 comments
Open

Script breaks if result has an empty percentage #16

OuterNeptunium opened this issue Jul 18, 2021 · 2 comments

Comments

@OuterNeptunium
Copy link

If a result for a SauceNao search has an empty percent-similarity value (meaning if a result doesn't have a number for the similarity), the script errors out with the message of ValueError: could not convert string to float: ''

Possible solutions:

  • Search using the actual file instead of the thumbnail if this occurs, as those tend to work where the thumbnail fails in this way
  • Tag the result with an identifier (such as [namespace]:error), but otherwise skip over it.

This issue has come up time and again in my use. Ideally this could be solved on SauceNao's end, but allowing this script to handle this case would make things much easier if it's not able to be solved there.

@GoAwayNow
Copy link
Owner

GoAwayNow commented Jul 19, 2021 via email

@OuterNeptunium
Copy link
Author

OuterNeptunium commented Jul 23, 2021

Sorry for the delay in the response, I could've sworn I checked more recently.

I sent the image to one of your accounts. Would prefer not to say which one, but it's sent via a link to the source I got it from, so there's no difference between the one I used with SauceNao and the one you'll be using to troubleshoot.

EDIT: Forgot an important detail, sent it shortly after.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants