Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details

If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.

Startup problems with r1669

Found a bug in EventGhost? Report it here.
Post Reply
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Startup problems with r1669

Post by krambriw »

In my 'production system', I use an old laptop. It is not very fast and it runs XP SP3 because it can not be upgraded to any newer versions of Windows (1,13 GHz CPU, 512 MB RAM, 32GB SSD Drive).

It performs well and does exactly what is needed to run my house automation. However, when I upgraded to r1669, EG is not starting correctly anymore.

I do receive a Windows message dialog that EG needs to be terminated. If I do NOT click on the error message dialog ok button, I get the following errors in the log file and EG continues to run

Code: Select all

21:33:06   ---> Welcome to EventGhost <---
21:33:15   Traceback (most recent call last) (1669):
21:33:15     File "C:\Program\EventGhost\plugins\System\__init__.py", line 388, in StartHookCode
21:33:15       self.UnIdleCallback,
21:33:15   SystemError: WAIT_TIMEOUT for HookThread
To overcome this problem temporarily (this is likely not the correct way to do it) I did the following change in the \System\__init__.py file staring at line 265:

Code: Select all

        #self.StartHookCode()
        #eg.Bind("System.SessionLock", self.StopHookCode)
        #eg.Bind("System.SessionUnlock", self.StartHookCode)

After another few minutes, I do receive another error message:

Code: Select all

21:35:09   WTSRegisterSessionNotification timeout

The errors does not happen in any of my faster PC:s (one also running XP SP3, the other Win7 64 bit)

Best regards, Walter
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: Startup problems with r1669

Post by Pako »

Dear Walter,
You will understand that I can very difficult to find the cause - because I can not invoke the same problem in my computer.
So I can only note how I would proceed, if I had the chance:
1.) to simplify system (remove all plugins except for core), use a simple configuration as much as possible (perhaps even empty).
2.) to look into the repository http://sourceforge.net/p/eventghost/code/HEAD/tree/ and find what was changed
3.) gradually trying to use the old files in the new version.

Note: Possible is the reverse procedure too.
  • Return to the old version of 1640
  • Point 1.) to implement the same
  • Point 3.) perform the opposite - trying new files
So it should be possible to find which file is causing the problem.
Finally, it would be necessary to compare the old and the new file ...

Best regards,
Pako
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: Startup problems with r1669

Post by krambriw »

Dear Pako, thanks, yes, I understand, I will investigate further.

Bets regards, Walter
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: Startup problems with r1669

Post by krambriw »

Dear Pako, results so far: after installing previous versions starting from r1669 and downwards, the latest working version where the startup is working fine is r1610. Next is to make some file comparison....

Best regards, Walter
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: Startup problems with r1669

Post by krambriw »

Dear Pako,
I was wrong regarding one statement earlier, one of my other PC:s also running XP SP3, also had the version r1610 installed.

Version r1610 is the last working version in my XP SP3 machines. After I also upgraded this machine, I got the error message as below. I used only the default configuration, nothing else.

It behaves strange, the error message came two minutes after start. After another 18 minutes, it suddenly continued the start.

Also strange is that if I do the following it starts up ok:

1) Install r1669
2) Rename manually 'Program Files\EventGhost' to 'Program Files\EventGhost_r1669'
3) Install r1610
4) Rename manually 'Program Files\EventGhost' to 'Program Files\EventGhost_r1610'
5) Rename manually 'Program Files\EventGhost_r1669' to 'Program Files\EventGhost'

Kind regards, Walter

Code: Select all

08:12:34   ---> Welcome to EventGhost <---
08:14:34   Stack trace (most recent call last) (1610):
08:14:34     File "threading.pyc", line 504, in __bootstrap
08:14:34     File "threading.pyc", line 532, in __bootstrap_inner
08:14:34     File "threading.pyc", line 484, in run
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 354, in __MainLoop
08:14:34       self.__DoOneEvent()
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 326, in __DoOneEvent
08:14:34       self.HandleAction(action)
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 289, in HandleAction
08:14:34       action()
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 62, in __call__
08:14:34       self.returnValue = self.func(*self.args, **self.kwargs)
08:14:34     File "C:\Program\EventGhost\eg\Classes\EventThread.py", line 142, in StartSession
08:14:34       actionThread.Func(actionThread.StartSession, 120)(filename)
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 213, in Wrapper
08:14:34       eg.PrintStack()
08:14:34   Unhandled exception in WorkerThread <EventThread>:
08:14:34   Callers stack:
08:14:34     File "wx\_core.pyc", line 8010, in MainLoop
08:14:34     File "wx\_core.pyc", line 7306, in MainLoop
08:14:34     File "wx\_core.pyc", line 14660, in <lambda>
08:14:34   Traceback (most recent call last) (1610):
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 326, in __DoOneEvent
08:14:34       self.HandleAction(action)
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 289, in HandleAction
08:14:34       action()
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 62, in __call__
08:14:34       self.returnValue = self.func(*self.args, **self.kwargs)
08:14:34     File "C:\Program\EventGhost\eg\Classes\EventThread.py", line 142, in StartSession
08:14:34       actionThread.Func(actionThread.StartSession, 120)(filename)
08:14:34     File "C:\Program\EventGhost\eg\Classes\ThreadWorker.py", line 214, in Wrapper
08:14:34       raise Exception("Timeout while calling %s" % func.__name__)
08:14:34   Exception: Timeout while calling StartSession
08:32:34   Plugin: Tornado
08:32:34   Persistent values: {}
08:32:34   Plugin: Log redirector
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: Startup problems with r1669

Post by Pako »

I do not know what to say. I do not know what to do at the moment.
However, I probably understand why exactly 2 minutes:

Code: Select all

08:14:34       actionThread.Func(actionThread.StartSession, 120)(filename)
Pako
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: Startup problems with r1669

Post by krambriw »

I agree with you and understand, I just realize and present the facts. When I install a later version than r1610 in XP, this happens. Immediately when installing r1610, everything works as normal.

Could be something in my machines, but currently I leave it as is, the work-around as described above works acceptable.

Unfortunately, none of my XP machines passes the Win7 upgrade compatibility check...and Microsoft has decided to drop XP...

I will have to consider new machines in the future,

Best regards and thanks for the help and discussion,

Walter
TRIROG1
Posts: 45
Joined: Fri Aug 08, 2014 10:07 pm

Re: Startup problems with r1669

Post by TRIROG1 »

Hi!

Sorry for hijacking this thread but since i'm also experiencing some funny problems with startup of EG on the 1669 it seemed logicaly to put it here.

What happens is the EG always starts with the example.xml script and all the default settings (config-1st run.py).

I change the settings and close the EG and i can see settings written to config.py file(config-2nd run.py). - everything OK up to here

However when i quit the EG the 2nd time it rewrites the config.py with default settings(config-3rd run.py).

this doesn't happen in version 1640.

I'm also attaching my configs for each run if they help.

Running EG on Windows 7 -64bit no SP
Attachments
config-3rd run.py
(1.46 KiB) Downloaded 209 times
config-2nd run.py
(1.92 KiB) Downloaded 201 times
config-1st run.py
(1.46 KiB) Downloaded 193 times
TRIROG1
Posts: 45
Joined: Fri Aug 08, 2014 10:07 pm

Re: Startup problems with r1669

Post by TRIROG1 »

Pako wrote:
TRIROG1 wrote:I'd love to use the last version of EG but i can't seem to figure out the problem with loading the config.py - as described here
I've read it before, but I'm not sure that I understand this correctly.
This behavior is reproducible?
This behavior is the same on every computer?

Pako
to continue here so we won't hijack the other topic.

The behavior is reproducible. i tried uninstalling EG and reinstalling it and the result was the same.
I don't know if this is happening on every computer since i only have EG installed on one. ;(
It almost seems like the EG is unable to load the config.py and so it loads the default one (or perhaps its a write permission problem-how ever i don't think write permission is a problem since it overwrites the correct config.py with the default one) ?
But if that were true why does it load the correct config.py the first time it starts after an update to 1669?

Do you have any suggestions ?
Perhaps it has to do with permi
TRIROG1
Posts: 45
Joined: Fri Aug 08, 2014 10:07 pm

Re: Startup problems with r1669

Post by TRIROG1 »

I don't know how or why this happened but...

... i just tried upgrading to 1669 from 1640 and now it just works ...

I guess its just one of those behaviors that should be attributed to Microsoft :P
Post Reply