Can't reference system.perspective in script console?

I was trying to develop and test some functions I built for a perspective module in the Script Console. I tried running them and got ImportError: No module named perspective. To recreate this, open Script Console and try import system.perspective. I understand perspective’s operations aren’t really integrated with the rest of the libraries but I am not using it for anything other than the print function in use case, but I still can’t develop with with the script console because of this. Is this a known issue?

The script console cannot run gateway-only function. Perspective scripts run on the gateway. Perspective scripting functions can only run in the gateway, where the information they need is present.

I recommend creating a test page in Perspective with some test buttons you can click to run your scripts. Use system.perspective.print() to get the console output.

2 Likes