Hi Team,
I have lot of rules which are configured in Adobe Launch which has lot of JavaScript custom codes written, some of them are throwing errors in console, where they haven't used try catch method also. I just want to know does we can be able to capture the error as event also error message, error code in eVar.
Kindly any inputs on this.
Thanks & Regards,
Rahul
Views
Replies
Total Likes
It might or might not be possible to track the errors. It depends on whether those errors result in the tracking beacon failing to be sent at all. If the tracking beacon can't be sent, then tracking the error in an eVar would be useless since it would never reach AA.
Since you're able to see that these errors are occurring, you should go into the relevant Custom Code in your Launch rules and fix them. And while you're there, make sure you test for as many scenarios as possible. Also, use JSLint as a first-check to validate your code.
Views
Replies
Total Likes
What you should do is set up proper release process:
Also you mentioned "where they haven't used try catch method also.", when writing custom code you should never forget the try/catch and the catch should not be silent otherwise you will never know it fails:
use something meaningful in error like: `_satellite.logger.error('Failed in rule X in function X to set bla', e)`
Finally have a look at these for tagging, coding and release standards:
https://dev.to/alcazes/adobe-launch-release-standards-2c9m
https://dev.to/alcazes/adobe-launch-tagging-standards-3aak
https://dev.to/alcazes/adobe-launch-coding-standards-e22
Views
Replies
Total Likes
Views
Like
Replies