- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
‎01-06-2022 05:02 PM
Hi,
I'm creating some workflows in XMC and I would like to run them on my PC first just for testing.
Is there a class or functions that I can import just to simulate the script and check for errors, even if it is just syntax error, before running it on the XMC?
Regards,
José Chaves
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
‎01-07-2022 03:35 AM
I have this code at the beginning of my code:
########################################################## try: emc_vars execution = 'xmc' except: # If not running on XMC Jython... # These lines only needed to run XMC Python script locally (on my laptop) # They can also be pasted to XMC, but will not execute import sys import json import java.util import emc_cli # Own local replica import emc_nbi # Own local replica import emc_results # Own local replica execution = 'dev' if len(sys.argv) > 1: # Json file as 1st argv emc_vars = json.load(open(sys.argv[1])) else: emc_vars = json.load(open('emc_vars.json')) ##########################################################
And I use the attached bogus classes which simply read the emc_vars or CLI command output directly from a json file I edit.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
‎01-07-2022 03:35 AM
I have this code at the beginning of my code:
########################################################## try: emc_vars execution = 'xmc' except: # If not running on XMC Jython... # These lines only needed to run XMC Python script locally (on my laptop) # They can also be pasted to XMC, but will not execute import sys import json import java.util import emc_cli # Own local replica import emc_nbi # Own local replica import emc_results # Own local replica execution = 'dev' if len(sys.argv) > 1: # Json file as 1st argv emc_vars = json.load(open(sys.argv[1])) else: emc_vars = json.load(open('emc_vars.json')) ##########################################################
And I use the attached bogus classes which simply read the emc_vars or CLI command output directly from a json file I edit.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
‎01-07-2022 05:04 AM
The file is password protected.
Regards,
José Chaves
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
‎01-07-2022 05:12 AM
Need to set that when emailing it, else it gets clobbered by email virus checking!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
‎01-07-2022 06:25 AM
Thanks, Ludovico
That is exactly what I was looking for.
Regards,
José Chaves
