I have encountered several circumstances where I was wishing I was able to run arcade expressions directly in a python script.
Since attribute rules only support arcade a lot of time has been spent building expressions and logic in the form of arcade expressions.
Then later on when building an automation workflow I have had to incorporate some of the same logic and had to completely rebuild the script using Python commands instead.
My thought is this, similar to how you can run SQL scripts inside of a Python script, create a way to pass arcade expressions inside of a python script to perform logic/analysis on the data and pass the output of the arcade expression back to the python script.
Would love to see this!
Hi @ckeener217,
Can you give a code example of the Arcade and converted Python scripts you mentioned? Since you mentioned attribute rules, my mind goes to arcpy.management.AddAttributeRule(in_table, name, type, script_expression <arcade>) where I believe the output to Python is a result object and the function side effect modifies the db Table View in place. I'm trying to get a better understanding what you want output back to you to help solve the issue. Thx.
Tyler
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.