
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2019-03-11 21:43 byPhillip.M.Feldman@gmail.com, last changed2022-04-11 14:59 byadmin. This issue is nowclosed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 15180 | merged | shireenrao,2019-08-08 18:01 | |
| PR 15324 | merged | miss-islington,2019-08-17 20:50 | |
| Messages (12) | |||
|---|---|---|---|
| msg337698 -(view) | Author: Phillip M. Feldman (Phillip.M.Feldman@gmail.com) | Date: 2019-03-11 21:43 | |
I have a module that contains an import statement that imports a large number of items. This import was failing with the following error message:ImportError: DLL load failed: The specified module could not be found.The message would be so much more helpful if it named the offending DLL and module. | |||
| msg337757 -(view) | Author: Steve Dower (steve.dower)*![]() | Date: 2019-03-12 15:42 | |
I agree. Unfortunately, the operating system does not provide this information.The best I can offer is to run Process Monitor [1] and watch its logs. It should show the paths it attempts to access.[1]:http://technet.microsoft.com/en-us/sysinternals/bb896645 | |||
| msg337861 -(view) | Author: Phillip M. Feldman (Phillip.M.Feldman@gmail.com) | Date: 2019-03-13 16:40 | |
Hello Steve,I'm buying only 50 percent of this. The Python interpreter must know whatmodule it was trying to import, and can at least be able to report that.PhillipOn Tue, Mar 12, 2019 at 8:42 AM Steve Dower <report@bugs.python.org> wrote:>> Steve Dower <steve.dower@python.org> added the comment:>> I agree. Unfortunately, the operating system does not provide this> information.>> The best I can offer is to run Process Monitor [1] and watch its logs. It> should show the paths it attempts to access.>> [1]:http://technet.microsoft.com/en-us/sysinternals/bb896645>> ----------> resolution: -> third party> stage: -> resolved> status: open -> closed>> _______________________________________> Python tracker <report@bugs.python.org>> <https://bugs.python.org/issue36266>> _______________________________________> | |||
| msg337870 -(view) | Author: Steve Dower (steve.dower)*![]() | Date: 2019-03-13 19:28 | |
You mean like this:>>> import _sslTraceback (most recent call last): File "<stdin>", line 1, in <module>ImportError: DLL load failed: The specified module could not be found.Should include "_ssl" somewhere in the message? That's easy enough, but it's never been what anyone else has meant when they've asked for this, so I assumed you wanted the more helpful message (where it tells you exactly which DLL is missing - libcrypto-1_1-x64.dll in this case - and *that's* the one we can't do). | |||
| msg337898 -(view) | Author: Phillip M. Feldman (Phillip.M.Feldman@gmail.com) | Date: 2019-03-14 06:47 | |
'Should include "_ssl" somewhere in the message?' Exactly so. If a givenimport statement imports 30 items, it would be helpful to know which onecaused the hickup. Thanks!On Wed, Mar 13, 2019 at 12:28 PM Steve Dower <report@bugs.python.org> wrote:>> Steve Dower <steve.dower@python.org> added the comment:>> You mean like this:>> >>> import _ssl> Traceback (most recent call last):> File "<stdin>", line 1, in <module>> ImportError: DLL load failed: The specified module could not be found.>> Should include "_ssl" somewhere in the message? That's easy enough, but> it's never been what anyone else has meant when they've asked for this, so> I assumed you wanted the more helpful message (where it tells you exactly> which DLL is missing - libcrypto-1_1-x64.dll in this case - and *that's*> the one we can't do).>> ---------->> _______________________________________> Python tracker <report@bugs.python.org>> <https://bugs.python.org/issue36266>> _______________________________________> | |||
| msg337918 -(view) | Author: Steve Dower (steve.dower)*![]() | Date: 2019-03-14 14:27 | |
Okay, in that case we're just adding `shortname` into the formatted `message` in _PyImport_FindSharedFuncptrWindows inPython/dynload_win.cI've marked this as "easy (C)" as it seems like a good first contribution for someone. | |||
| msg338013 -(view) | Author: Terry J. Reedy (terry.reedy)*![]() | Date: 2019-03-15 18:34 | |
Phillip, when responding by email, please removed the quoted email (except possible for a line or 2) as it becomes noise when your email is placed on the web page. You can see the effect onhttps://bugs.python.org/issue36266 | |||
| msg349244 -(view) | Author: Srinivas Nyayapati (shireenrao)* | Date: 2019-08-08 18:07 | |
I just submitted a PR for this issue. | |||
| msg349573 -(view) | Author: Srinivas Nyayapati (shireenrao)* | Date: 2019-08-13 15:43 | |
can a reviewer please take a look to my PR? | |||
| msg349906 -(view) | Author: Steve Dower (steve.dower)*![]() | Date: 2019-08-17 20:50 | |
New changeset24fe46081be3d1c01b3d21cb39bc3492ab4485a3 by Steve Dower (shireenrao) in branch 'master':bpo-36266: Add module name in ImportError when DLL not found on Windows (GH-15180)https://github.com/python/cpython/commit/24fe46081be3d1c01b3d21cb39bc3492ab4485a3 | |||
| msg349907 -(view) | Author: Steve Dower (steve.dower)*![]() | Date: 2019-08-17 20:53 | |
Thanks for the contribution! | |||
| msg349908 -(view) | Author: miss-islington (miss-islington) | Date: 2019-08-17 21:11 | |
New changeset786a4e1cef3eda8f434613d3801a5c7565fb5cd8 by Miss Islington (bot) in branch '3.8':bpo-36266: Add module name in ImportError when DLL not found on Windows (GH-15180)https://github.com/python/cpython/commit/786a4e1cef3eda8f434613d3801a5c7565fb5cd8 | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:59:12 | admin | set | github: 80447 |
| 2019-08-17 21:11:31 | miss-islington | set | nosy: +miss-islington messages: +msg349908 |
| 2019-08-17 20:53:46 | steve.dower | set | status: open -> closed resolution: fixed messages: +msg349907 stage: patch review -> resolved |
| 2019-08-17 20:50:53 | miss-islington | set | pull_requests: +pull_request15041 |
| 2019-08-17 20:50:42 | steve.dower | set | messages: +msg349906 |
| 2019-08-13 15:43:18 | shireenrao | set | messages: +msg349573 |
| 2019-08-08 18:07:11 | shireenrao | set | nosy: +shireenrao messages: +msg349244 |
| 2019-08-08 18:01:14 | shireenrao | set | keywords: +patch stage: test needed -> patch review pull_requests: +pull_request14912 |
| 2019-03-15 18:34:17 | terry.reedy | set | nosy: +terry.reedy messages: +msg338013 |
| 2019-03-14 14:27:27 | steve.dower | set | status: closed -> open versions: + Python 3.8, - Python 3.6 keywords: +easy (C) messages: +msg337918 type: enhancement resolution: third party -> (no value) stage: resolved -> test needed |
| 2019-03-14 06:47:34 | Phillip.M.Feldman@gmail.com | set | messages: +msg337898 |
| 2019-03-13 19:28:32 | steve.dower | set | messages: +msg337870 |
| 2019-03-13 16:40:10 | Phillip.M.Feldman@gmail.com | set | messages: +msg337861 |
| 2019-03-12 15:42:15 | steve.dower | set | status: open -> closed resolution: third party messages: +msg337757 stage: resolved |
| 2019-03-12 10:50:37 | xtreak | set | nosy: +paul.moore,tim.golden,zach.ware,steve.dower components: + Windows |
| 2019-03-11 21:43:32 | Phillip.M.Feldman@gmail.com | create | |