TracecatHQ / tracecat

The open source Tines / Splunk SOAR alternative.
https://tracecat.com
GNU Affero General Public License v3.0
2.34k stars 159 forks source link

[TRACKER] More useful error messages #307

Open topher-lo opened 4 weeks ago

topher-lo commented 4 weeks ago

NOTE:

For users encountering poor UX related to Tracecat errors, please kindly add your error message to this issue. We aim to have a <24 hour turnover for every insufficiently useful error message.

Problem

We designed the parser from first principles that fits according to parser / complier / arithmetic theory. Therefore existing error messages e.g.

Failed to parse expression: Unexpected end-of-input. Expected one of: \n\t* IF\n\t* OPERATOR\n\t* RPAR\n\t* COMMA\n'

areoften cryptic and do no provide sufficient next steps / information to the user i.e. good for SWEs / development / unit tests but not great for the end user.

Solution

bjackson2001 commented 4 weeks ago

Committing Empty Workflows - Error message on UI reads "Error committing Workflow"

topher-lo commented 3 weeks ago
Screenshot 2024-08-21 at 3 31 53 PM

^Non-informative error when JSONPath KeyError. For example:

This errored: ${{ ACTIONS.analyze_url.result.data.last_analysis_stats }}
Correct usage: ${{ ACTIONS.analyze_url.result.data.attributes.last_analysis_stats }}

^ missing .attributes

daryllimyt commented 2 weeks ago
Screenshot 2024-08-21 at 3 31 53 PM

^Non-informative error when JSONPath KeyError. For example:

This errored: ${{ ACTIONS.analyze_url.result.data.last_analysis_stats }}
Correct usage: ${{ ACTIONS.analyze_url.result.data.attributes.last_analysis_stats }}

^ missing .attributes

This issue should be fixed in #353. It's actually a known issue with loguru.

daryllimyt commented 2 weeks ago

Committing Empty Workflows - Error message on UI reads "Error committing Workflow"

This has also been addressed in a previous PR. Will link if I find it.