I actually didn't know that there were use cases for importing itself — thanks for letting me know. The best way of implementing a better error message would probably be to change the message for when the user import itself, while it's still partially initialized. In the beginning of the programming journey, getting a message about circular imports when they were testing out tkinter in a file names "tkinter.py" would probably not be helpful. Getting a message that hints that you may have accidentally imported itself, however, will probably help significantly. Maybe an error like this would be better, even though the wording could be worked on: "AttributeError: partially initialized module 'tkinter' has no attribute 'Tk' (most likely due to trying to import the file that is being executed)"