https://bugzilla.wikimedia.org/show_bug.cgi?id=68705

--- Comment #5 from Fabian <[email protected]> ---
Okay my mistake that 'bool(cat.articles)' return true if it's not None. But you
could then do something like:

empty = True
for page in cat.articles:
    empty = False
if empty:
    # complain

Now I'm sure if this is slower (but it doesn't appear so). And maybe there is a
more pythonic way. The for-else does not differ between an empty list and a non
empty.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to