diff options
author | Shantanu <12621235+hauntsaninja@users.noreply.github.com> | 2024-10-24 19:11:12 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-10-24 19:11:12 (GMT) |
commit | 500f5338a8fe13719478589333fcd296e8e8eb02 (patch) | |
tree | b44c7630f1d618e01647d1e8c01eeecde706586c /Misc/NEWS.d | |
parent | 3f24bde0b6689b8f05872a8118a97908b5a94659 (diff) | |
download | cpython-500f5338a8fe13719478589333fcd296e8e8eb02.zip cpython-500f5338a8fe13719478589333fcd296e8e8eb02.tar.gz cpython-500f5338a8fe13719478589333fcd296e8e8eb02.tar.bz2 |
gh-123930: Better error for "from imports" when script shadows module (#123929)
Diffstat (limited to 'Misc/NEWS.d')
-rw-r--r-- | Misc/NEWS.d/next/Core_and_Builtins/2024-09-11-01-32-07.gh-issue-123930.BkPfB6.rst | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Core_and_Builtins/2024-09-11-01-32-07.gh-issue-123930.BkPfB6.rst b/Misc/NEWS.d/next/Core_and_Builtins/2024-09-11-01-32-07.gh-issue-123930.BkPfB6.rst new file mode 100644 index 0000000..3c8eb02 --- /dev/null +++ b/Misc/NEWS.d/next/Core_and_Builtins/2024-09-11-01-32-07.gh-issue-123930.BkPfB6.rst @@ -0,0 +1,4 @@ +Improve the error message when a script shadowing a module from the standard
+library causes :exc:`ImportError` to be raised during a "from" import.
+Similarly, improve the error message when a script shadowing a third party module
+attempts to "from" import an attribute from that third party module while still initialising. |