startup error: 'NoneType' object has no attribute 'PrintErr

Found a bug in EventGhost? Report it here.
Post Reply
skribb
Experienced User
Posts: 228
Joined: Thu Feb 12, 2015 7:22 pm
Location: Win7 64bit

startup error: 'NoneType' object has no attribute 'PrintErr

Post by skribb » Thu Jul 20, 2017 11:32 pm

01:28:14 Error compiling script.
01:28:14 Traceback (most recent call last) (1722):
01:28:14 File "C:\Program Files (x86)\EventGhost\eg\Classes\ActionItem.py", line 121, in SetArguments
01:28:14 self.compiled = self.executable.Compile(*args)
01:28:14 File "C:\Program Files (x86)\EventGhost\plugins\EventGhost\PythonScript.py", line 71, in __init__
01:28:14 self.PrintTraceback()
01:28:14 File "C:\Program Files (x86)\EventGhost\plugins\EventGhost\PythonScript.py", line 97, in PrintTraceback
01:28:14 treeItem.PrintError("Traceback (most recent call last):")
01:28:14 AttributeError: 'NoneType' object has no attribute 'PrintError'



Is this an error traced to a print? I have a few "print XXX" in my startup but they all work when I test the commands.
Automation is life.

Win7 64bit
EG: v0.5.0-rc4

User avatar
kgschlosser
Site Admin
Posts: 5144
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: startup error: 'NoneType' object has no attribute 'Print

Post by kgschlosser » Fri Jul 21, 2017 12:24 am

this is because of a python script error. well it's an error trying to print an error.

that's why it comes out like that.

you are going to have to go through each and every single one of your python scripts looking for it. it's going to be a syntax error. the easiest way to find out what script is doing it is to open your scripts one at a time and add an empty line and click on apply. if the script has an error in it you will see the error come up.

or if you upgrade to eg 0.5 when you open EG it will select the specific item in the tree that is having the issue.
If you like the work I have been doing then feel free to Image

skribb
Experienced User
Posts: 228
Joined: Thu Feb 12, 2015 7:22 pm
Location: Win7 64bit

Re: startup error: 'NoneType' object has no attribute 'Print

Post by skribb » Fri Jul 21, 2017 1:15 pm

kgschlosser wrote:this is because of a python script error. well it's an error trying to print an error.

that's why it comes out like that.

you are going to have to go through each and every single one of your python scripts looking for it. it's going to be a syntax error. the easiest way to find out what script is doing it is to open your scripts one at a time and add an empty line and click on apply. if the script has an error in it you will see the error come up.

or if you upgrade to eg 0.5 when you open EG it will select the specific item in the tree that is having the issue.
thanks!

Wow. Found a script with messed up indentations on every line that I wasn't even aware of. why does it feel like EG lives its own life when I'm not looking? :shock:
Automation is life.

Win7 64bit
EG: v0.5.0-rc4

User avatar
kgschlosser
Site Admin
Posts: 5144
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: startup error: 'NoneType' object has no attribute 'Print

Post by kgschlosser » Fri Jul 21, 2017 1:39 pm

it probably happened when you copied and pasted something when you were 1/2 awake and didn't notice it.

Do you know how long it took me to figure out what was causing that error when i first stumbled across it?. OMG it took me a week to figure it out.
If you like the work I have been doing then feel free to Image

Post Reply