Skip to content

Commit 3e29854

Browse files
harshilp24jnikhila
andauthored
fix: Cyclic Dependency in Table Column Validation (#2307)
## Description Provide a concise summary of the changes made in this pull request - ## Pull request type Check the appropriate box: - [ ] Review Fixes - [ ] Documentation Overhaul - [ ] Feature/Story - Link one or more Engineering Tickets * - [ ] A-Force - [ ] Error in documentation - [ ] Maintenance ## Documentation tickets Link to one or more documentation tickets: - ## Checklist From the below options, select the ones that are applicable: - [ ] Checked for Grammarly suggestions. - [ ] Adhered to the writing checklist. - [ ] Adhered to the media checklist. - [ ] Verified and updated cross-references or added redirect rules. - [ ] Tested the redirect rules on deploy preview. - [ ] Validated the modifications made to the content on the deploy preview. - [ ] Validated the CSS modifications on different screen sizes. --------- Co-authored-by: Nikhila Jain <[email protected]>
1 parent 92bce51 commit 3e29854

File tree

3 files changed

+38
-1
lines changed

3 files changed

+38
-1
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# Cyclic Dependency Errors
2+
3+
A cyclic dependency occurs when two or more components depend on each other, either directly or indirectly, creating a loop. This page provides information on cyclic dependencies, and how to identify and resolve them.
4+
5+
6+
#### Using Table properties in column validation
7+
8+
<Message
9+
messageContainerClassName="error"
10+
messageContent="Cyclic dependency found while evaluating. Node was: Table1.primaryColumns.created_at.validation"></Message>
11+
12+
#### Cause
13+
14+
This error occurs when you try to use a Table widget's property inside the Table column validation. For example, using `Table1.updatedRow` inside the column validation property creates a cyclic dependency. This means that the validation logic relies on a property that is itself dependent on the result of the validation, causing an infinite loop of dependencies.
15+
16+
```js
17+
//Cyclic Dependency:
18+
{{Table1.updatedRow.created_at}}
19+
```
20+
21+
#### Solution
22+
23+
To resolve this issue, use `{{currentRow.name}}` in the Table column validation property instead of `Table1.updatedRow` or `Table1.newRow`.
24+
25+
<dd>
26+
27+
*Example:*
28+
29+
```js
30+
//No Cyclic Dependency:
31+
{{currentRow.created_at}}
32+
```
33+
34+
</dd>

website/docs/help-and-support/troubleshooting-guide/widget-errors.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,4 +121,6 @@ This error occurs when there are duplicate values in the options property of the
121121

122122
#### Solution
123123

124-
To resolve this error, ensure that each value in the options property of the Select widget is unique. You can do this by checking the values and making sure that there are no duplicates.
124+
To resolve this error, ensure that each value in the options property of the Select widget is unique. You can do this by checking the values and making sure that there are no duplicates.
125+
126+

website/sidebars.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -851,6 +851,7 @@ const sidebars = {
851851
'help-and-support/troubleshooting-guide/action-errors/README',
852852
'help-and-support/troubleshooting-guide/git-errors',
853853
'help-and-support/troubleshooting-guide/gac-errors',
854+
'help-and-support/troubleshooting-guide/cyclic-dependency',
854855
],
855856
},
856857
// 'help-and-support/troubleshooting-guide/js-errors',

0 commit comments

Comments
 (0)