3 ms·
Any of those find calls can return None. None does not have a find method.
by natrius 16y ago
Any of those find calls can return None. None does not have a find method.
- jey 16y agoThis sounds more like a design flaw in BeautifulSoup than anything else. The OP is wrong in directing his anger towards NULL/None/nil. (BeautifulSoup should be returning an empty collection, not None.)
- njharman 16y agoBingo! This api fail drives me crazy when using BS. Esp since it's otherwise pretty slick.
- rglullis 16y agoOh, you're absolutely right. I thought that BeautifulSoup's find would be lazily evaluated, like Django's Queryset.