Ignore any exception via isinstance on Python 3.
(obj: object)
| 332 | |
| 333 | |
| 334 | def safe_isclass(obj: object) -> bool: |
| 335 | """Ignore any exception via isinstance on Python 3.""" |
| 336 | try: |
| 337 | return inspect.isclass(obj) |
| 338 | except Exception: |
| 339 | return False |
| 340 | |
| 341 | |
| 342 | if TYPE_CHECKING: |
no outgoing calls