Johannes Kerger

Results 6 comments of Johannes Kerger

@agronholm Why isn't this merged yet? Is there a problem/conflict/etc. with this PR?

Ok, I just wanted to know if there is any work to do to make this PR acceptable. Apparently not at this moment, thanks for the reply.

@jolaf Can you give an example when this would be useful? My understanding is that inside `TYPE_CHECKING` should only be imports that can't happen at runtime because of circular imports...

Can you give an code example for such a case?

@agronholm Yes, that works (currently), but it only works because of `from __future__ import annotations` and violates the condition that "annotations need to be syntactically valid Python expressions [...] [and]...

Yes, you're right. I misinterpreted the PEP because I was taught that you should use `TYPE_CHECKING` blocks only if you have to (import cycles). In that case the object would...