win32all on win95: importv win32file fails

Marie-Claude Savoie marie-claude.savoie at sympatico.ca
Mon Feb 17 13:10:43 EST 2003


Hi All,

I have a similar problem but don't know if it is related.  I had some serial
IO code that was working under W95 and above and had created it with python
2.0 and pythonwin 135.  Using the same code now with python 2.2 and
pythonwin 146 I get a problem on W95 but not on W98 or later.

I have tracked the problem down to win32file.pyd using dependency walker.
The Winsock has been updated to 2.  The error message that I get is
ImportError: DLL load failed: A device attached to the system is not
functioning.

Are there any functions that I could avoid using to get around this problem?
Could I use the win32file.pyd from build 135 and use it instead of the
win32file.pyd from build 146?

Right now I am using

 from win32file import *

Can I get around this problem by only importing the functions that I need?

I need my code to work with W95 and above, and this is causing serious
problems.

Thanks

Gordon Williams

"Mark Hammond" <mhammond at skippinet.com.au> wrote in message
news:YTW3a.9482$863.28888 at news-server.bigpond.net.au...
> Tim Roberts wrote:
> > wouter at voti.nl (Wouter van Ooijen (www.voti.nl)) wrote:
> >
> >
> >>For product of mine that uses Python and win32all I get complaints
> >
> >>from users on win95 that win32file can not belowded:
> >
> >>>>    import win32file
> >>>>ImportError: DLL load failed: One of the library files needed
> >>>>to run this application cannot be found
> >>
> >>I don't have win95 to test this, and I don't get similar complaints
> >
> >>from users of other win versions. Is there anything special about
> >
> >>win32all on win95?
> >
> >
> > Looking over the list of DLL imports for win32file.pyd, I note that it
> > requires Winsock2 (WS2_32.DLL).  I don't think that is included with
Win95,
> > so I'll bet that's the problem.
> >
> > Check here: I believe you can download Winsock2 for Win95.
> > http://www.microsoft.com/windows95/downloads/
> >
> > BTW, here is the complete list of imports for win32file.pyd:
> >     KERNEL32.dll
> >     OLEAUT32.dll
> >     PyWinTypes22.dll
> >     python22.dll
> >     MSVCRT.dll
> >     MSWSOCK.dll
> >     WS2_32.dll
>
> Note sure if winsock2 is the problem, but I am fairly sure CancelIO
> doesn't exist on 95.  I'm afraid someone who cares enough will need to
> send me a patch.
>
> Mark.
>






More information about the Python-list mailing list