Skip to content
This repository has been archived by the owner on Sep 7, 2023. It is now read-only.

[fix] wikidata: fix crash when the item has no description at all and… #2353

Merged
merged 1 commit into from Dec 4, 2020

Conversation

dalf
Copy link
Contributor

@dalf dalf commented Dec 4, 2020

What does this PR do?

Fix a crash when a wikidata item has:

  • no description at all (whatever the language)
  • at least one URL

In this case and without this PR, infobox_content is None function, later len(infobox_content) raises an exception.

Why is this change important?

Bug fix.

How to test this PR locally?

I can't a wikidata item that match these criteria, but reading the code the len(None) makes sense (spotted with /stats/errors ).

Author's checklist

Related issues

@dalf dalf merged commit d949428 into searx:master Dec 4, 2020
@dalf dalf deleted the fix-wikidata branch February 21, 2021 20:13
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant