Skip to main content
Users
CloudPortalLogin
  • Powered byPowered by
Introduction to Sitecore CDP
Data availability
Managing your account
Managing system settings
Managing guests
Batch segmentation
Data browser
Audience export
Dashboards
Developer center
AI in CDP
Glossary
  • Sitecore CDP
  • Developer center
  • Session traits
  • Troubleshooting session traits

Troubleshooting session traits

This topic describes the most common issues you may encounter with session traits and provides solutions for resolving them.

Viewing a session trait's error report

When a session trait fails, you can access an error report to view an active session trait's execution data and logs in a table format. This report can help you identify the cause of the failure.

To view a session trait's error report:

  1. From the Session Traits page, open the active session trait for which you want to view the report.

    On the Activity tab, you'll see statistics for the total number of executions, including successful and failed attempts.

  2. Access the error report using these methods:

    • To access the report for the most recent failed execution, click View error report in the banner.

    • To access the report for a specific failed execution, click the number in the Failed executions tile on the Activity tab.

  3. The Error Report page lists all session trait executions with errors. Click View Log to see details of a specific failed execution, including the failure message and additional information.

  4. To resolve the issue, pause the session trait and edit the JavaScript code of your session trait.

    Important

    Always test the session trait thoroughly before reactivating it.

Handling calculation errors for one or more customers

If a calculation error occurs in an active session trait but only affects certain customers, you can pause the session trait. This pause allows you to make necessary corrections without losing the existing progress. Any successful calculations for other customers will remain intact during this pause, ensuring that you do not restart the process from the beginning. This also gives you the opportunity to address the issues causing the calculation errors for certain customers.

After you pause the session trait:

  1. Review and adjust the JavaScript code. Focus on handling all potential input data types to prevent future errors.

  2. Test the modified code against a customer that previously encountered an error, and make sure the adjustments resolve calculation errors for that customer.

  3. Reactivate the session trait if you want to resume calculations.

Addressing high failure rates

When a session trait exhibits a high failure rate, specifically, if it has 50 failed executions and zero successful executions in the past hour, Sitecore CDP automatically pauses its execution to prevent additional errors. The system continuously monitors failure rates and intervenes when they exceed the set threshold.

After Sitecore CDP automatically pauses your session trait:

  1. You'll receive a notification that details the encountered error.

  2. Review and adjust the JavaScript code. Identify the root cause of the high failure rate.

  3. Test the modified code to ensure the the problems are resolved.

  4. Reactivate the session trait once you're confident of the code changes.

Do you have some feedback for us?

If you have suggestions for improving this article,

Privacy policySitecore Trust CenterCopyright © 1999-2026 Sitecore