Select to view content in your preferred language

Arcade Error Text Confusion

394
1
01-24-2024 10:07 AM
ZachBodenner
MVP Regular Contributor

Hello, 

I'm wondering if anyone has information on how error text is determined when writing Arcade code. Here's an example of an error message I find misleading:

ZachBodenner_0-1706119485764.png   

ZachBodenner_1-1706119638591.png

 

 

The above code is incorrect because I actually need two equal signs on line 3, but the error message return is "close parenthesis expected." It's possible I'm not sure what the Arcade language is actually evaluating, but this is not the only case (or ESRI product) where Arcade error messages have been really difficult to interpret and find the root issue. Is this something ESRI has documentation on that I just haven't found? Possibly an area to submit an idea to improve the error messages?

1 Reply
jcarlson
MVP Esteemed Contributor

The Arcade editor in Pro is pretty bad. I try to write my expressions in the Arcade Playground and paste them in after. While not perfect, the error checking tools in the online Arcade editors tends to be a lot better and more helpful when you have errors.

jcarlson_0-1706127150921.png

Using a similar expression, we see that the error is correctly identified as being an issue with the expression in my condition, not the parentheses.

- Josh Carlson
Kendall County GIS