You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2010-04-22.13:30:30.650>created_at=<Date2010-04-22.00:47:51.754>labels= ['type-bug', 'library']
title='mailcap.lookup() returns filter iterator rather than list if key is given'updated_at=<Date2010-04-22.13:30:30.649>user='https://bugs.python.org/gnofi'
The lookup method in the Python 3.2 mailcap module still uses filter as if it will return a list, like it did in Python 2. If a value for the "key" argument is passed to the method, the method will return a filter iterator rather than a list.
I discovered this while running a test I created for mailcap. It's not checked in yet. See bpo-6484.
This is probably low priority because mailcap.lookup() is an internal method. It is used by mailcap.findmatch(), which actually handles the filter iterator gracefully. Nevertheless, I don't think it should return a different type based on whether the key argument is passed. The fix is simple enough.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: