Platform<=>version conflict or what?

Robin Dunn kirjoitti:

I ran my TestGUI also on win98-environment with "Dependency Walker" and got similar warnings:

GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsAlloc") called from "MSVCR71.DLL" at address 0x7C341950 and returned NULL. Error: The specified procedure could not be found (127).
GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsGetValue") called from "MSVCR71.DLL" at address 0x7C34195D and returned NULL. Error: The specified procedure could not be found (127).
GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsSetValue") called from "MSVCR71.DLL" at address 0x7C34196A and returned NULL. Error: The specified procedure could not be found (127).
GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsFree") called from "MSVCR71.DLL" at address 0x7C341977 and returned NULL. Error: The specified procedure could not be found (127)
GetProcAddress(0x7C570000 [KERNEL32.DLL], "IsTNT") called from "OLEAUT32.DLL" at address 0x77A23F12 and returned NULL. Error: The specified procedure could not be found (127).

Also one missing file was claimed (as on Win2k): "APPHELP.DLL" (TestGui ran OK in despite of that!)

These are harmless. The GetProcAddress is how the MS DLL is dynamically testing at runtime if certain functionality is available on the system in other DLLs so it can work around it being missing if needed. Same thing with the missing DLL, they are loaded dynamically on demand at runtime, but if they are never needed (because the functions using them are never called) then they are never loaded and so there is no problem. All of this happens inside the MS DLLs and is completely hidden from us at the Python level.

Hi Robin,

So in other words the error messages above are somehow misleading, when these are merely only indications of features of running OS tested on.

I describe the whole trace of missing "APPHELP.dll" given:
- missing delay-loaded module
- time stamp: Error opening file. The system cannot find the file specified(2).

If I understood you correct this file became to the list due the actions generated by MS (Win2k or Win98)?
This sounds strange for me, because "APPHELP.dll" is not the part of the said OS´s (belongs to Xp). So how can the running OS know to check the availability of the module, which is not part of it ?

Third point - the missing checksum of modules:

WXBASE28H_NET_VC.DLL
WXBASE28H_VC.DLL
WXMSW28H_ADV_VC.DLL
WXMSW28H_HTML_VC.DLL

Link checksum of modules is 0x00000000 (Real checksums are calculated and given) and Actual Base(on red) is also different compared with Preferred Base ?
Is this also related to somehow to Win OS's ?

Regards,

Jorma

Jorma Paavola wrote:

Robin Dunn kirjoitti:

I ran my TestGUI also on win98-environment with "Dependency Walker" and got similar warnings:

GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsAlloc") called from "MSVCR71.DLL" at address 0x7C341950 and returned NULL. Error: The specified procedure could not be found (127).
GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsGetValue") called from "MSVCR71.DLL" at address 0x7C34195D and returned NULL. Error: The specified procedure could not be found (127).
GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsSetValue") called from "MSVCR71.DLL" at address 0x7C34196A and returned NULL. Error: The specified procedure could not be found (127).
GetProcAddress(0x7C570000 [KERNEL32.DLL], "FlsFree") called from "MSVCR71.DLL" at address 0x7C341977 and returned NULL. Error: The specified procedure could not be found (127)
GetProcAddress(0x7C570000 [KERNEL32.DLL], "IsTNT") called from "OLEAUT32.DLL" at address 0x77A23F12 and returned NULL. Error: The specified procedure could not be found (127).

Also one missing file was claimed (as on Win2k): "APPHELP.DLL" (TestGui ran OK in despite of that!)

These are harmless. The GetProcAddress is how the MS DLL is dynamically testing at runtime if certain functionality is available on the system in other DLLs so it can work around it being missing if needed. Same thing with the missing DLL, they are loaded dynamically on demand at runtime, but if they are never needed (because the functions using them are never called) then they are never loaded and so there is no problem. All of this happens inside the MS DLLs and is completely hidden from us at the Python level.

Hi Robin,

So in other words the error messages above are somehow misleading, when these are merely only indications of features of running OS tested on.

I describe the whole trace of missing "APPHELP.dll" given:
- missing delay-loaded module
- time stamp: Error opening file. The system cannot find the file specified(2).

If I understood you correct this file became to the list due the actions generated by MS (Win2k or Win98)?
This sounds strange for me, because "APPHELP.dll" is not the part of the said OS´s (belongs to Xp). So how can the running OS know to check the availability of the module, which is not part of it ?

When the DLL is compiled it is linked with APPHELP.dll using flags telling it to be delay-loaded, which means that it won't be loaded unless one of the functions located within it is called. If the functions are never called (and they won't be on win98) then there is no problem. If you've installed any other software that was made in the last several years then I bet that you've already got a few copies of MSVCRT.dll already on the system.

Third point - the missing checksum of modules:

WXBASE28H_NET_VC.DLL
WXBASE28H_VC.DLL
WXMSW28H_ADV_VC.DLL
WXMSW28H_HTML_VC.DLL

Link checksum of modules is 0x00000000 (Real checksums are calculated and given) and Actual Base(on red) is also different compared with Preferred Base ?
Is this also related to somehow to Win OS's ?

No, it's just build options that we aren't using.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Hi Robin,

When the DLL is compiled it is linked with APPHELP.dll using flags telling it to be delay-loaded, which means that it won't be loaded unless one of the functions located within it is called. If the functions are never called (and they won't be on win98) then there is no problem. If you've installed any other software that was made in the last several years then I bet that you've already got a few copies of MSVCRT.dll already on the system.

Thanks for your clear reply !
- so by this way you´ll get the sw to adapt different OS´s without extra compilation/linking procedure
- the warnings of "Dependency Walker" are really misleading, because they obviously don´t make any difference of markings with the missing files absolutely needed !!
- MSVCRT.dll is a part of py2exe dist module as well
- I tested my "original" TestGUI-sw (generated with bundle=1 option)on Win98 with "Dependency Walker" to see what really is going wrong, when the said Error Message will be generated: (> can´t create window wxWindowClassNR (error 0: the operation completed succesfully)
The significant differencies are:
- without bundle-option the sw-tree is only abt. 25% of that with bundle=1
- some of addresses of memory trace seem "irrelevant" just before ErrorMsg, therefore I believe that the code tends to crash just before the message above !
- this is obviously also the the case with other OS´s as described earlier(in despite that they generated Traceback´s instead of ErrorMsg)
- this means, that I will NOT USE bundle=1 any more !!

Third point - the missing checksum of modules:

WXBASE28H_NET_VC.DLL
WXBASE28H_VC.DLL
WXMSW28H_ADV_VC.DLL
WXMSW28H_HTML_VC.DLL

Link checksum of modules is 0x00000000 (Real checksums are calculated and given) and Actual Base(on red) is also different compared with Preferred Base ?
Is this also related to somehow to Win OS's ?

No, it's just build options that we aren't using.

- build options of what ?

Regards,

Jorma

Werner F. Bruhin kirjoitti:

Hi Jorma,

Can't help on this, this is too technical for me.

Hopefully someone else can you help with this.

Werner

Hi Werner,

Robin Dunn explained well the issue of the warnings generated by "Dependency Walker" more as interpretation errors due the poor reporting tools on it !
- "DW" don´t separate the real-necessary files and "sometimes"-necessary at all !

I had some time to study Boa more and I went through the Tutorial on Capital 2.
This is obviously concerning older version of BOA exampling on Xp!?
My BOA is v.0.5.2 and therefore I guess everything did not fit with the Tutorial described:
- Dialogs pane is missing
- Dialog (2.7) failed to show the Title field 'About Notebook' when running even it was showing on Designer !??
- Dialog Window with sizers (2.8)won´t let to change the Sizers from 'None' (as default) at all ==> therefore the layout stucked on the left side of panel !!?

Do you know if the combination of Python 2.5, wxPython 2.8.3.0 and BOA v.0.5.2 on Win2k don´t fit well together or is there something else on the Tutorial ?

I like the straightforward, comprehensive and easy concept of Boa !

Best regards,

Jorma

Hi Jorma,

Jorma Paavola wrote:

...
I had some time to study Boa more and I went through the Tutorial on Capital 2.

Boa related issues are more often covered on the Boa list:
boa-constructor-users@lists.sourceforge.net

you can also follow on the game news server:
gmane.comp.ide.boa-constructor.user

This is obviously concerning older version of BOA exampling on Xp!?
My BOA is v.0.5.2 and therefore I guess everything did not fit with the Tutorial described:
- Dialogs pane is missing

The tutorial was done for 0.5.0 and this has been changed after. All these dialogs (File, Dir etc) can now be acceccess via code templates.

Place your cursor at the place in your source code were you want it and press Alt-t.

- Dialog (2.7) failed to show the Title field 'About Notebook' when running even it was showing on Designer !??

Works for me, just checked it with the code in boa/examples/guide/dialog2.py (note that you might need to change the image file path)

- Dialog Window with sizers (2.8)won´t let to change the Sizers from 'None' (as default) at all ==> therefore the layout stucked on the left side of panel !!?

Yes, this sample will have to be reworked, it is on my todo list.

Do you know if the combination of Python 2.5, wxPython 2.8.3.0 and BOA v.0.5.2 on Win2k don´t fit well together or is there something else on the Tutorial ?

I use Boa 0.5.2 for a long time and use it with Python 2.5, wxPython 2.8.4 (now, before 2.8.1 and even with 2.6.x and 2.7.x), was on Win XP and I am now on Vista but do also check my applications on Win2k (py2exe'd only).

Werner

Oleg Deribas kirjoitti:

Hello,

Jorma Paavola said the following on 17.05.2007 17:34:

My intension is to "pack" everything necessary on one single executive whenever possible without using extra wrapping-sw´s !

You could try something like this:
SingleFileExecutable - py2exe.org

Therefore I now suspect, that "packing" of files with py2exe
obviously don´t fit for use on Win98 !!? - So Summa Summarum: There is possible a version conflict between py2xe and win98 !??

Yes, I can confirm this.

Hi Oleg,

I had recently some time to check the method of "single file executable" as described, which worked perfectly on my development PC on Win2k , but when tried to run it (.exe file) on Win98 I got the following Traceback:

Traceback (most recent call last):
  File "Moro.py", line 1, in <module>
  File "wx\__init__.pyo", line 45, in <module>
  File "wx\_core.pyo", line 4, in <module>
  File "wx\_core_.pyo", line 12, in <module>
  File "wx\_core_.pyo", line 10, in __load
ImportError: DLL load failed: One of the library files needed to run this application cannot be found.

Could you possible advice about the possible missing file ?

Regards,

Jorma

PS. NOTE: when running the "py2exed"-file(without bundle-option) from it's 'dist'- folder on Win98 it works perfectly !!

Hi Jorma,

I have found this (or a similar problem) to be caused by
a missing gdiplus.dll. It is normally found here:

C:\Python25\Lib\site-packages\wx-2.8-msw-ansi\wx

Friday, June 1, 2007, 3:57:30 PM, you wrote:

···

ImportError: DLL load failed: One of the library files needed to run this application cannot be found.

Could you possible advice about the possible missing file ?

Regards,

Jorma

PS. NOTE: when running the "py2exed"-file(without bundle-option) from
it's 'dist'- folder on Win98 it works perfectly !!

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org

Phillip Stevens kirjoitti:

Hi Jorma,

I have found this (or a similar problem) to be caused by
a missing gdiplus.dll. It is normally found here:

C:\Python25\Lib\site-packages\wx-2.8-msw-ansi\wx

Friday, June 1, 2007, 3:57:30 PM, you wrote:

ImportError: DLL load failed: One of the library files needed to run this application cannot be found.

Could you possible advice about the possible missing file ?

Regards,

Jorma

PS. NOTE: when running the "py2exed"-file(without bundle-option) from it's 'dist'- folder on Win98 it works perfectly !!

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org

Hi Phillip,

Unfortunately this was not the case on my Win98, where the said gdiplus.dll - file is on system folder and also in some other folders !

Other ideas ?

regds,

Jorma

Hi Jorma,

I just renamed gdiplus.dll here so it wouldn't be found, and MY App (also) says:
  File "wx\__init__.pyc", line 45, in <module>
  File "wx\_core.pyc", line 4, in <module>
  File "wx\_core_.pyc", line 12, in <module>
  File "wx\_core_.pyc", line 10, in __load
ImportError: DLL load failed: One of the library files needed to run this application cannot be found.

So I will be very surprised if it isn't this.

Try moving the .dll directly into the same directory as you are running the exe
from.

If that doesn't work make sure you don't have different versions of
the .dll floating around on the system, and try different ones in the
directory the exe is being run from. Or mis-matched versions, or
something. You could be in ".dll h*ll"

If it still doesn't run, go to www.sysinternals.com (now part of Microsoft),
and get some of the cool tools they have there like filemon so you can see what
it is, that your app is trying to load. A lot of very useful things there like
Process Explorer, so stock up. :stuck_out_tongue:

---Phil

···

Hi Phillip,

Unfortunately this was not the case on my Win98, where the said
gdiplus.dll - file is on system folder and also in some other folders !

Other ideas ?

regds,

Jorma

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org

Phillip Stevens kirjoitti:

Hi Jorma,

I just renamed gdiplus.dll here so it wouldn't be found, and MY App (also) says:
  File "wx\__init__.pyc", line 45, in <module>
  File "wx\_core.pyc", line 4, in <module>
  File "wx\_core_.pyc", line 12, in <module>
  File "wx\_core_.pyc", line 10, in __load
ImportError: DLL load failed: One of the library files needed to run this application cannot be found.

So I will be very surprised if it isn't this.

Try moving the .dll directly into the same directory as you are running the exe
from.

If that doesn't work make sure you don't have different versions of
the .dll floating around on the system, and try different ones in the
directory the exe is being run from. Or mis-matched versions, or
something. You could be in ".dll h*ll"

If it still doesn't run, go to www.sysinternals.com (now part of Microsoft),
and get some of the cool tools they have there like filemon so you can see what
it is, that your app is trying to load. A lot of very useful things there like
Process Explorer, so stock up. :stuck_out_tongue:

Hi Phil,

First I would like to explain, that my TestApp(.exe) is first py2eded (without bundle) totalling 16 files on dist-folder. When I try it, it runs perfectly on all WinOS's !
My goal is this make 'single-exe' (to work also on all WinOS's), where I used NSIS proposed by Oleg.
This works fine on my Win2k ! - It'll create Runtime-Temp, where the TestApp is running from, when started and erases Temp-file automatically when exited - this feature I like !!

1) gdiplus.dll
- according to my knowledge gdiplus.dll is needed also, when running py2exed TestApp - this works fine (also on Win98)
- the problem starts when trying to run NSISed TestApp on Win98 !!
- due the dynamic generation of Runbase on Temp-file gdiplus.dll cannot be placed on it, but never mind the first priority is the version on windows/system-folder
- even that I have six different gdiplus.dll located in different places they are same versions exept one, which is not in use

2) Tools from sysintervals
- I tested Process Explorer, which shows the situation on Runtime-basis
  - this is however not so nice to track failures happening only once!
- Also I used "Dependency Walker", which principally should show the whole story, this however 'failed' partly as it became unfortunately refresched and a part of data became lost

3) Process Explorer gave an detailled list of running state on my TestApp on Win2k (Moron.exe.txt).
There are two files, which I would like to remark:
- nsexec.dll (NSIS-module ~ OK !)
- TrtseShl.dll (TortoiseShell) ?? WHY ?

On Win98 could be seen 'a strange module' flashing just before exit to traceback:
- WINO386.mod Non Windows based module ???

What is WINO386.mod ???

4)Filemon
- Can you collect the whole trace with it ?

rgds,

Jorma

Moron.exe.txt (4.78 KB)

Hi Jorma,

...

This works fine on my Win2k ! - It'll create Runtime-Temp, where the
TestApp is running from, when started and erases Temp-file automatically
when exited - this feature I like !!

OK, I see better what you are trying to do now, building a single
executable file. I haven't tried this, but the questions I'd have
about it would be:

- Have you verified that the files have been properly extracted
from the single executable into the temporary directory? Do they
have the same MD5SUM's as they did before they were placed into the
single file executable?

- Does it make any difference if compression is turned off?

- Maybe it's an order of events thing? (maybe the .dlls have to
already be present before the .exe starts running?? I ask this not
knowing if it extracts them all, or if they are extracted "on demand"
as requested, or the order in which they are extracted...)

What is WINO386.mod ???

I'm not sure but this may be something called "WinOldApp" that I
sometimes see running in the task manager list.

4)Filemon
- Can you collect the whole trace with it ?

I've never run into a case where I could not see what I wanted to see
with Filemon. I usually let things run to the point where the event
has happened, then stop the capture in Filemon, and look back at what
happened.

···

rgds,

Jorma

Hi Phil,

This works fine on my Win2k ! - It'll create Runtime-Temp, where the TestApp is running from, when started and erases Temp-file automatically
when exited - this feature I like !!

OK, I see better what you are trying to do now, building a single
executable file. I haven't tried this, but the questions I'd have
about it would be:

- Have you verified that the files have been properly extracted
from the single executable into the temporary directory? Do they
have the same MD5SUM's as they did before they were placed into the
single file executable?

Unfortunately extracted files cannot be seen from Temp-folder, because it will be automatically erased when exited (or ErrorMsg given) !

- Does it make any difference if compression is turned off?

- Maybe it's an order of events thing? (maybe the .dlls have to
already be present before the .exe starts running?? I ask this not
knowing if it extracts them all, or if they are extracted "on demand"
as requested, or the order in which they are extracted...)

Principally NSIS should take care of prompt order of events !

What is WINO386.mod ???

I'm not sure but this may be something called "WinOldApp" that I
sometimes see running in the task manager list.

You are right: that was related to WinOldApp !

4)Filemon
- Can you collect the whole trace with it ?

I've never run into a case where I could not see what I wanted to see
with Filemon. I usually let things run to the point where the event
has happened, then stop the capture in Filemon, and look back at what
happened.

I tested MyApp on Win98 with "FileMon" to see what happens - this tool really traces everything !
- it found two 'unsuccesful' (missing?) modules: DOSAPP.INI and CONAGENT.PIF
- are these important ?
(- also sometimes the order/function was strange: f.ex. trials to CREATE already existing files like C:/WINDOWS, C:/WINDOWS/TEMP etc.)
(- also sometimes attributes were tested first before the file was created ; thereafter everething worked fluently again ...)
- it looks quite difficult to localize the event(trigging/failure point)from long list totalling abt. 6.000 events (from start to Errormsg) !
Any ideas for that ?

Rgds,

Jorma

Hi Phil,

Thanks for your good tips !

See the following thread:
http://www.annoyances.org/exec/forum/win98/1010169708

I ran D.W. on one of my Apps here (not packaged with NSIS byw...),
and I get the two "errors" on APPHELP.DLL and USERENV.DLL, however
my program continues past this point on Win98, and runs fine.

These according to my knowledge are partly due the "unupdated versions of Win98" of those days !

In my case the module APPHELP.DLL is reported by DW (when running) as missing one but only on "delay-loaded"-basis ! According to Robin Dunn this under Win98 will however never be called and therefore that´s no problem ! (as stated before !)
APPHELP.DLL itselves is a module, which belongs to Xp and above only and is therefore obsolete on Win98 (and Me,Win2k as well)and will cause problems if added !!
The reason of existency is probably due the compilation phase of wx-python on from C++ on Xp, but is principally OK when marked with flags as delay-loaded !
The related correct module for Win9x and Win2k Os´s is SHLWAPI.DLL !

USERENV.DLL is a necessary module on win9x-OS´s and is not missing on my case on Win98 ( due the all updates done!)

See point #5 here: http://www.annoyances.org/exec/forum/win98/1010414182

I wonder if *maybe* this could be at the root of the problem, ie when the DLL
is not found, no one (the NSIS unpackager?) checks for an extended error code,
and knows to ignore the dll load error and attempt to continue the execution.??
Just a guess...

---Phil

Good guess !
This however is not exactly the explation on Win98 - not on my case only - but generally as well !
because:

- (because of load-mechanism of Win98) on load-phase of original pyexed sw from dist-folder (16 separate modules) DW (Windows) is not forced to check the code until the start point of application (and reports no Errors!) as the case is with NSISed version see rel. encl. image file Morol.dwi of DW versus Moron.dwi sent before !

- when running the original sw DW (Windows) is forced to continue loading of required modules to the starting point (and further) of application _CORE_.PYD and reports the same errors of child-modules under USERENV.DLL (obviously because these required functions of the modules don´t exist under Win98 ?).These functions however seem not to be on running-phase absolute necessary, because my sw is able to start and run normally ! Could be seen on DW´s image file Moro.dwi (sized 2.5 MB too big for NEWS), which tells everything what happens when sw is running succesfully under Win98

- when running the NSISed version (or py2-bundled ) of sw DW (Windows) (because of load-mechanism of Win98) is forced to check already at loading phase all the necessary modules until startpoint of application and finds then the said "lacks" of child-modules under USERENV.DLL. These lacks are then finally prohitibing the application to run (under Windows).

My guess of final conclusion now is:
- This is a general incombitibilty problem of wx-Python-sw´s on Win98 ! (when sw´s developed on other OS´s )!
- this possible would require some changes (specially made for Win98) to wx-python source code or compilation flags ?
- the use of totally failing child-module of USERENV.DLL is NTTDL.DLL which (on my Win98 is original one and dated 1998 !) possible should be reconsidered (substituted or delay-loaded or?)or updated with a newer version (as the case is on Win2k !)

Any comments ?

Jorma

Morol.dwi (101 KB)