Merge pull request #11308 from reaganjlee/iter-reporting

Improve reporting from __iter__ exceptions
This commit is contained in:
Zac Hatfield-Dodds
2023-08-21 16:27:42 -07:00
committed by GitHub
3 changed files with 21 additions and 1 deletions

View File

@@ -132,7 +132,7 @@ def isiterable(obj: Any) -> bool:
try:
iter(obj)
return not istext(obj)
except TypeError:
except Exception:
return False