In this article:
1. How to Identify Different Types of Issues in Business Rules?
2. How to Troubleshoot Business Rules?
2.1 Configuration issues
2.2 Execution issues
2.3 Warning messages
3. Troubleshooting Business Rules using Segment Isolation
To get started with business rules and how to use them, please refer to our dedicated article.
1. How to Identify Different Types of Issues in Business Rules?
In some cases, modifications made to a board or workflow might cause certain business rules to stop working as intended. Below are the types of issues you may encounter:
Configuration issues
There are a couple of ways to notice a configuration error in a Business Rule:
- From the board — If there is a problem with one or more business rules, the information icon on the affected column(s) will turn red. Clicking on it will open the Board Policies window where you can see more information about the rule.
- From the administration panel — when looking at the list of Business Rules, you may notice a rule that is highlighted in red. When you hover over the rule's name, you will see an information message that explains the issue.
In both of the above cases, the red color indicates that this rule may not work correctly because some of the columns, lanes, cells, workflows, or boards referenced in it might have been deleted.
Execution issues
If a rule fails to execute, Businessmap will send an email to the author and the user that triggered it. In most cases, this would mean that the rule was triggered, but the action could not be executed. A common example of this is a rule trying to move a card that is blocked - the blocker prevents the card from being moved so the rule execution fails and sends an email to the author about this event.
Warning messages
If an element has been disabled or deleted from the account (e.g. types, tags, stickers, blockers, custom fields, and user-related fields: owner, co-owner, watcher, contributor's value), the author of the business rule, as well as any user that triggers it, will receive a warning message via email. These warning messages serve as notifications only, they will not stop the execution of a rule.
A warning message will also be sent if the set deadline is before 1970-01-01 or after 2038-01-01.
2. How to Troubleshoot Business Rules?
If you want to check whether a particular rule has been executed on a card, the first place to check would be the card's History tab.
Tip: you can filter the historical events by keywords (e.g. “rule” - to list all rule executions).
There are 5 types of actions triggered by Business rules: create, update, link, move, copy.
Each action can be performed either on the card that triggers the business rule (trigger card) or on another card (target card).
Depending on the executed action, business rules will leave a history log as follows:
- The trigger card will get a “Rule Execution” log (1) with information about the rule.
- The target card will get a “Rule Executed” log (2) with information about the changes that were made.
In actions where the trigger and target cards are the same card (e.g. update, move, create subtask), the system logs the ‘Rule Execution’ event only.
In addition, history events will be logged every time an action is successful, even if no changes have been performed (e.g. update the color to red on a card that is already red; move a card to location and the card is already in that location; etc.).
These logs can help you distinguish if the problem is within the trigger part of the rule (WHEN/AND parts) or the execution event of the rule (THEN part).
Note: If you want to investigate multiple triggers of the same rule, you can do that from the Business Rule Audit Logs. You can access them by going to the gear icon in the top right corner, selecting “Security and Audit”, scrolling down to the blue “View Logs” button, pressing it, and selecting the Business Rules tab. From this tab, you can filter the ID of the rule you want to investigate.
3. Troubleshooting Business Rules Using Segment Isolation
In order to isolate the problem, follow the steps below to find in which section of the rule it is coming from and review if the section's configuration is the intended one.
- Check if the WHEN configuration (the trigger of the business rule) is working as intended.
- Start by copying the business rule that produces errors.
- Leave the trigger the same, but change the AND and THEN clauses to something simple. For example, the AND clause can be "title" contains "test" and the THEN clause can be to change the color of the cards to purple.
- Run a test by using the same trigger and seeing if the rule runs correctly. If the problem persists - the problem is within the trigger configuration.
- Check if the AND configuration of the rule gives the correct parameters
- Start by copying the business rule that produces the errors.
- Create a simpler trigger for the rule. For example, WHEN the color of the card is changed to blue.
- Create a simpler THEN action, for example, add a sticker to the card.
- Run a test by using this new simpler rule to test if the AND configuration parameters are the ones intended.
- Check if the THEN configuration of the rule gives the correct outcome
- Start by copying the business rule that produces the errors.
- Create a simpler trigger for the rule. For example, WHEN the color of the card is changed to blue.
- Create a simpler AND parameter, for example, the board is “Test Board”.
- Run a test by using this new simpler rule to test if the THEN actions are the ones that are intended.
Important: We have a separate article for troubleshooting business rule errors related to copying properties between linked cards.