AnsweredAssumed Answered

startup.py special script not working

Question asked by mdekys_bagira on Oct 10, 2017
Latest reply on Oct 10, 2017 by TFuchs-esristaff

Hello,

 

would like to execute a script during CE startup . In manual it says to put a script named startup.py into current CityEngine workspace. So I made a simple script that prints something in CE's console to check if it is working:

 

startup.py:

from scripting import *

ce = CE()


if __name__ == '__main__':

   print ("hello world from startup")

 

but when I startup CE it doesn't print anything to console. However, when I execute it, it works perfectly so it shouldn't contain any errors. but it doesn't get executed automatically during startup. Am I missing something?

 

also where exactly should this script be located by meaning "current CityEngine workspace" ? 

 

is it 

<workspace_root>/scripting.py

<workspace_root>/<project>/scripting.py

<workspace_root>/<project>/<scripts>/scripting.py

 

I placed it on all loactions and it doesn't work.

 

Any help appreciated.

 

Mark

Attachments

Outcomes