Suppose A0 and A1 define "a.foo". Suppose B0 imports A0 and B1 imports A1 and use "a.foo". Suppose C imports B0 and B1.
I can solve that B0 and B1 bind correctly to "a.foo" during typechecking. But then I just shifted the problem to the linking phase where it'll turn out "a.foo" gets imported from two different files.
I can also solve that by fully qualifying "a.foo" with the file in which it is defined. But then what if A0 and A1 are also named the same but live in two different paths? I would also need to fully qualify each identifier with both the filename as well as the path.
So. I am not going to solve this. Programmers will need to make sure all identifiers for a project live in different namespaces/don't overlap. Everything is solvable but this simply isn't worth it.
It's a feature, not a bug.