Closed nelfin closed 5 years ago
@Kami, is this the case that you were seeing? I tried to reverse-engineer the behaviour that might cause the stack trace that you posted in #17
Yep, I belive that's indeed the root cause (we import module multiple times under a different alias and location).
Thanks for such a quick turn around and a fix. I will look into testing it shortly.
Thanks, I just confirmed the fix is working :+1:
There do appear to be some other issues related to struct field types and referenced fields, but I will open a separate issue for that.
Importing a module from a package multiple times with different aliases can cause an
AssertionError
by due to the assumption that importing a module can only increase the amount of names in the global namespace. To the best of my knowledge this is still true, but handling of imported names with aliases is improperly tracked.This can be reproduced by the following case: