Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix: Reduce cycle deps by removing wrong exports #39268

Merged
merged 2 commits into from
Feb 14, 2025

Conversation

hetunandu
Copy link
Member

@hetunandu hetunandu commented Feb 14, 2025

Description

Remove specific cycle dependencies created because a file was both importing and exporting items it does not modify.

By reducing cycle dependencies here, I am buying credits that allow adding cycle dependencies in another PR but very hard to avoid

This PR reduces the deps by 4

EE PR: https://github.com/appsmithorg/appsmith-ee/pull/6214

PR which adds the cycle deps: #39100

Automation

/ok-to-test tags="@tag.Sanity"

🔍 Cypress test results

Tip

🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
Workflow run: https://github.com/appsmithorg/appsmith/actions/runs/13324385763
Commit: 34a0f45
Cypress dashboard.
Tags: @tag.Sanity
Spec:


Fri, 14 Feb 2025 07:54:00 UTC

Communication

Should the DevRel and Marketing teams inform users about this change?

  • Yes
  • No

Summary by CodeRabbit

  • New Features

    • Introduced a “Show More” option in the code editor’s command palette for additional suggestions.
    • Enabled default expansion for table widget panels to improve content visibility.
  • Refactor

    • Consolidated entity and type management for a more consistent and maintainable platform.
  • Improvements

    • Enhanced widget behavior with dynamic updates in dropdowns, file pickers, and map styling for a smoother user experience.

Copy link
Contributor

coderabbitai bot commented Feb 14, 2025

Walkthrough

This pull request refactors multiple modules by updating import paths for constants and types—primarily ENTITY_TYPE and EvaluationSubstitutionType—to a new centralized location ("ee/entities/DataTree/types"). In addition, a few components and widgets have been enhanced with new methods or properties (for example, a new property in the select widget and lifecycle handling in the dropdown widget). Overall, the changes are cosmetic and organizational, ensuring consistency across the codebase without altering core functionality.

Changes

File(s) Change Summary
app/client/src/.../EmbeddedDatasourcePathField.tsx, .../Debugger/ErrorLogs/getLogIconForEntity.tsx, .../dataTreeAction.ts, .../dataTreeJSAction.ts, .../isDynamicEntity.ts Updated import for ENTITY_TYPE (and related types such as EvaluationSubstitutionType, EntityTypeValue) from "entities/DataTree/dataTreeFactory" to "ee/entities/DataTree/types".
app/client/src/ce/reducers/uiReducers/explorerReducer.ts, .../GlobalSearch/utils.tsx, .../dataTreeSelectors.ts, .../navigationSelectors.ts Modified import paths for entity types to use the new module, ensuring consistent type definitions across reducers and selectors.
app/client/src/components/editorComponents/CodeEditor/** (e.g., EvaluatedValuePopup.tsx, commandsHelper.ts, generateQuickCommands.tsx, index.tsx) Updated import paths for ENTITY_TYPE and EvaluationSubstitutionType; introduced new command option logic in quick commands.
app/client/src/entities/Action/**, .../dataTreeWidget.test.ts, .../dataTreeWidget.ts, .../FilterInternalProperties/getEntityPeekData.ts Centralized entity-related imports and, in one case, removed unused exports from dataTreeFactory.ts.
app/client/src/widgets/** (e.g., CategorySliderWidget, ChartWidget, CheckboxGroupWidget, DropdownWidget, FilePickerWidgetV2, FilepickerWidget, JSONFormWidget, ListWidget, MapWidget, MenuButtonWidget, MultiSelectTreeWidget, MultiSelectWidget, RadioGroupWidget, SelectWidget, SingleSelectTreeWidget, SwitchGroupWidget, TableWidget, TableWidgetV2) Across various widgets: updated import paths for EvaluationSubstitutionType and others; added new methods/properties such as a componentDidUpdate in DropdownWidget, static helper methods in FilepickerWidget and MapWidget, a static type property in SelectWidget, and new interfaces in MultiSelectWidgetV2.
app/client/src/utils/autocomplete/** and related test files Updated import for ENTITY_TYPE; added a new method updateRecentEntities(recentEntities: string[]) in CodemirrorTernService to manage recent entity lists in autocomplete scenarios.
Other utility and test files (e.g., files under NavigationSelector, helpers.test.ts, widgetRenderUtils.tsx) Standardized entity type imports to use the new centralized module.

Sequence Diagram(s)

sequenceDiagram
    participant D as DropdownWidget Component
    participant P as Props
    participant C as changeSelectedOption()
    
    D->>P: Receives new props update
    alt Props (defaultOptionValue/option) changed
        D->>C: Invoke changeSelectedOption()
    else No change detected
        D-->>D: Maintain current state
    end
Loading

Possibly related PRs

Suggested labels

Bug, Needs Triaging, DevOps Pod, ok-to-test

Suggested reviewers

  • dvj1988
  • ApekshaBhosale
  • NandanAnantharamu

Poem

In our code, paths realign so neat,
Old routes retire for a fresher beat.
Entities now dwell in a central space,
With widgets and tests sharing the same embrace.
A refactor dance 🎉— streamlined and sweet!
Cheers to clarity, where our logic does meet.

✨ Finishing Touches
  • 📝 Generate Docstrings (Beta)

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@github-actions github-actions bot added the Bug Something isn't working label Feb 14, 2025
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (6)
app/client/src/utils/NavigationSelector/JsChildren.ts (1)

24-38: Consider distinguishing between function and variable types.

Currently, both functions and variables use ENTITY_TYPE.JSACTION, only differentiated by the isfunction flag. Consider creating distinct entity types for better type safety and clarity.

- type: ENTITY_TYPE.JSACTION,
+ type: isfunction ? ENTITY_TYPE.JS_FUNCTION : ENTITY_TYPE.JS_VARIABLE,

Also applies to: 40-56

app/client/src/ce/entities/DataTree/dataTreeAction.ts (1)

15-17: Address the TODO comment about eslint disable.

The comment indicates technical debt that should be addressed. Would you like me to help create an issue to track this?

app/client/src/widgets/TableWidgetV2/widget/propertyConfig/contentConfig.ts (1)

144-150: Good addition of expandedByDefault property!

The property addition with clear comments helps control the default expansion state of the data section. Consider adding this property to other sections for consistency.

app/client/src/widgets/MapWidget/widget/index.tsx (1)

433-461: Well-structured static methods for widget configuration!

The new static methods provide clear configuration for:

  • Default properties mapping
  • Meta properties mapping
  • Derived properties mapping
  • Stylesheet configuration with theme variables

Consider adding JSDoc comments to document the purpose and return types of these methods.

+/**
+ * Returns the mapping of default properties for the widget
+ * @returns Record of property mappings
+ */
 static getDefaultPropertiesMap(): Record<string, any> {
   return {
     markers: "defaultMarkers",
     center: "mapCenter",
   };
 }
app/client/src/widgets/MultiSelectWidgetV2/widget/index.tsx (2)

772-774: Address TODO comments and eslint-disable directives.

There are two TODO comments with eslint-disable directives that should be addressed:

  1. Line 772: Generic eslint-disable for explicit any
  2. Line 789: Generic eslint-disable for explicit any

Consider using proper TypeScript types instead of any.

- // TODO: Fix this the next time the file is edited
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
- static getMetaPropertiesMap(): Record<string, any> {
+ static getMetaPropertiesMap(): Record<string, unknown> {

- // TODO: Fix this the next time the file is edited
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
- (value: any) => isString(value) || isFinite(value),
+ (value: string | number) => isString(value) || isFinite(value),

Also applies to: 789-791


360-371: Improve validation message clarity.

The validation message for defaultOptionValue could be more explicit about the supported formats. Consider separating the examples for better readability.

 validation: {
   type: ValidationTypes.FUNCTION,
   params: {
     fn: defaultOptionValueValidation,
     expected: {
       type: "Array of values",
-      example: ` "option1, option2" | ['option1', 'option2'] | [{ "label": "label1", "value": "value1" }]`,
+      example: `
+        Format 1: "option1, option2"
+        Format 2: ['option1', 'option2']
+        Format 3: [{ "label": "label1", "value": "value1" }]
+      `,
       autocompleteDataType: AutocompleteDataType.ARRAY,
     },
   },
 },
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1cf1750 and ec34a12.

📒 Files selected for processing (72)
  • app/client/src/PluginActionEditor/components/PluginActionForm/components/CommonEditorForm/components/EmbeddedDatasourcePathField.tsx (2 hunks)
  • app/client/src/ce/components/editorComponents/Debugger/ErrorLogs/getLogIconForEntity.tsx (1 hunks)
  • app/client/src/ce/entities/DataTree/dataTreeAction.ts (1 hunks)
  • app/client/src/ce/entities/DataTree/dataTreeJSAction.ts (1 hunks)
  • app/client/src/ce/entities/DataTree/isDynamicEntity.ts (1 hunks)
  • app/client/src/ce/reducers/uiReducers/explorerReducer.ts (1 hunks)
  • app/client/src/ce/utils/FilterInternalProperties/getEntityPeekData.ts (1 hunks)
  • app/client/src/components/editorComponents/CodeEditor/EvaluatedValuePopup.tsx (1 hunks)
  • app/client/src/components/editorComponents/CodeEditor/commandsHelper.ts (1 hunks)
  • app/client/src/components/editorComponents/CodeEditor/generateQuickCommands.tsx (1 hunks)
  • app/client/src/components/editorComponents/CodeEditor/index.tsx (1 hunks)
  • app/client/src/components/editorComponents/GlobalSearch/utils.tsx (1 hunks)
  • app/client/src/components/formControls/DynamicTextFieldControl.tsx (1 hunks)
  • app/client/src/constants/PropertyControlConstants.tsx (1 hunks)
  • app/client/src/entities/Action/actionProperties.test.ts (1 hunks)
  • app/client/src/entities/Action/actionProperties.ts (1 hunks)
  • app/client/src/entities/DataTree/dataTreeFactory.ts (0 hunks)
  • app/client/src/entities/DataTree/dataTreeWidget.test.ts (1 hunks)
  • app/client/src/entities/DataTree/dataTreeWidget.ts (2 hunks)
  • app/client/src/entities/Widget/utils.test.ts (1 hunks)
  • app/client/src/entities/Widget/utils.ts (1 hunks)
  • app/client/src/modules/ui-builder/ui/wds/WDSCheckboxGroupWidget/config/propertyPaneConfig/contentConfig.ts (1 hunks)
  • app/client/src/modules/ui-builder/ui/wds/WDSMenuButtonWidget/config/propertyPaneConfig/contentConfig.ts (1 hunks)
  • app/client/src/modules/ui-builder/ui/wds/WDSRadioGroupWidget/config/propertyPaneConfig/contentConfig.ts (1 hunks)
  • app/client/src/modules/ui-builder/ui/wds/WDSSelectWidget/config/propertyPaneConfig/contentConfig.tsx (1 hunks)
  • app/client/src/modules/ui-builder/ui/wds/WDSSwitchGroupWidget/config/propertyPaneConfig/contentConfig.ts (1 hunks)
  • app/client/src/modules/ui-builder/ui/wds/WDSTableWidget/config/propertyPaneConfig/contentConfig.ts (1 hunks)
  • app/client/src/pages/Editor/Explorer/Actions/ActionEntityContextMenu.tsx (2 hunks)
  • app/client/src/pages/Editor/Explorer/Entity/EntityProperties.tsx (1 hunks)
  • app/client/src/pages/Editor/Explorer/JSActions/JSActionContextMenu.tsx (2 hunks)
  • app/client/src/pages/Editor/Explorer/Widgets/WidgetContextMenu.tsx (1 hunks)
  • app/client/src/plugins/Linting/utils/getLintingErrors.ts (1 hunks)
  • app/client/src/selectors/dataTreeSelectors.ts (1 hunks)
  • app/client/src/selectors/navigationSelectors.ts (2 hunks)
  • app/client/src/utils/FilterInternalProperties/__tests__/index.test.ts (1 hunks)
  • app/client/src/utils/NavigationSelector/JsChildren.ts (1 hunks)
  • app/client/src/utils/NavigationSelector/WidgetChildren.ts (1 hunks)
  • app/client/src/utils/WidgetLoadingStateUtils.test.ts (1 hunks)
  • app/client/src/utils/autocomplete/AutocompleteSortRules.ts (1 hunks)
  • app/client/src/utils/autocomplete/CodemirrorTernService.ts (2 hunks)
  • app/client/src/utils/autocomplete/__tests__/AutocompleteSortRules.test.ts (1 hunks)
  • app/client/src/utils/autocomplete/__tests__/TernServer.test.ts (1 hunks)
  • app/client/src/utils/autocomplete/__tests__/dataTreeTypeDefCreator.test.ts (1 hunks)
  • app/client/src/utils/editor/EditorBindingPaths.ts (2 hunks)
  • app/client/src/utils/helpers.test.ts (1 hunks)
  • app/client/src/utils/widgetRenderUtils.tsx (2 hunks)
  • app/client/src/widgets/CategorySliderWidget/widget/propertyConfig/contentConfig.ts (1 hunks)
  • app/client/src/widgets/ChartWidget/widget/propertyConfig.ts (1 hunks)
  • app/client/src/widgets/CheckboxGroupWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/DropdownWidget/widget/index.tsx (2 hunks)
  • app/client/src/widgets/FilePickerWidgetV2/widget/index.tsx (1 hunks)
  • app/client/src/widgets/FilepickerWidget/widget/index.tsx (2 hunks)
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig.ts (1 hunks)
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/common.ts (1 hunks)
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/multiSelect.ts (1 hunks)
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/radioGroup.ts (1 hunks)
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/select.ts (1 hunks)
  • app/client/src/widgets/ListWidget/widget/propertyConfig.ts (1 hunks)
  • app/client/src/widgets/ListWidgetV2/widget/propertyConfig.ts (1 hunks)
  • app/client/src/widgets/MapChartWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/MapWidget/widget/index.tsx (3 hunks)
  • app/client/src/widgets/MenuButtonWidget/widget/propertyConfig/contentConfig.ts (1 hunks)
  • app/client/src/widgets/MultiSelectTreeWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/MultiSelectWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/MultiSelectWidgetV2/widget/index.tsx (2 hunks)
  • app/client/src/widgets/RadioGroupWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/SelectWidget/widget/index.tsx (2 hunks)
  • app/client/src/widgets/SingleSelectTreeWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/SwitchGroupWidget/widget/index.tsx (1 hunks)
  • app/client/src/widgets/TableWidget/widget/propertyConfig.ts (1 hunks)
  • app/client/src/widgets/TableWidgetV2/widget/propertyConfig/PanelConfig/Basic.ts (1 hunks)
  • app/client/src/widgets/TableWidgetV2/widget/propertyConfig/contentConfig.ts (1 hunks)
💤 Files with no reviewable changes (1)
  • app/client/src/entities/DataTree/dataTreeFactory.ts
✅ Files skipped from review due to trivial changes (51)
  • app/client/src/widgets/MenuButtonWidget/widget/propertyConfig/contentConfig.ts
  • app/client/src/widgets/MapChartWidget/widget/index.tsx
  • app/client/src/pages/Editor/Explorer/JSActions/JSActionContextMenu.tsx
  • app/client/src/modules/ui-builder/ui/wds/WDSRadioGroupWidget/config/propertyPaneConfig/contentConfig.ts
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/common.ts
  • app/client/src/pages/Editor/Explorer/Entity/EntityProperties.tsx
  • app/client/src/modules/ui-builder/ui/wds/WDSTableWidget/config/propertyPaneConfig/contentConfig.ts
  • app/client/src/widgets/CheckboxGroupWidget/widget/index.tsx
  • app/client/src/utils/autocomplete/AutocompleteSortRules.ts
  • app/client/src/pages/Editor/Explorer/Widgets/WidgetContextMenu.tsx
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/select.ts
  • app/client/src/constants/PropertyControlConstants.tsx
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig.ts
  • app/client/src/utils/editor/EditorBindingPaths.ts
  • app/client/src/utils/autocomplete/tests/AutocompleteSortRules.test.ts
  • app/client/src/widgets/SingleSelectTreeWidget/widget/index.tsx
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/multiSelect.ts
  • app/client/src/modules/ui-builder/ui/wds/WDSSelectWidget/config/propertyPaneConfig/contentConfig.tsx
  • app/client/src/ce/components/editorComponents/Debugger/ErrorLogs/getLogIconForEntity.tsx
  • app/client/src/entities/Widget/utils.test.ts
  • app/client/src/entities/Action/actionProperties.ts
  • app/client/src/modules/ui-builder/ui/wds/WDSMenuButtonWidget/config/propertyPaneConfig/contentConfig.ts
  • app/client/src/widgets/TableWidgetV2/widget/propertyConfig/PanelConfig/Basic.ts
  • app/client/src/utils/autocomplete/tests/dataTreeTypeDefCreator.test.ts
  • app/client/src/widgets/JSONFormWidget/widget/propertyConfig/properties/radioGroup.ts
  • app/client/src/widgets/CategorySliderWidget/widget/propertyConfig/contentConfig.ts
  • app/client/src/widgets/ChartWidget/widget/propertyConfig.ts
  • app/client/src/modules/ui-builder/ui/wds/WDSSwitchGroupWidget/config/propertyPaneConfig/contentConfig.ts
  • app/client/src/components/editorComponents/GlobalSearch/utils.tsx
  • app/client/src/ce/reducers/uiReducers/explorerReducer.ts
  • app/client/src/ce/utils/FilterInternalProperties/getEntityPeekData.ts
  • app/client/src/widgets/ListWidgetV2/widget/propertyConfig.ts
  • app/client/src/entities/DataTree/dataTreeWidget.test.ts
  • app/client/src/entities/Widget/utils.ts
  • app/client/src/utils/WidgetLoadingStateUtils.test.ts
  • app/client/src/modules/ui-builder/ui/wds/WDSCheckboxGroupWidget/config/propertyPaneConfig/contentConfig.ts
  • app/client/src/widgets/SwitchGroupWidget/widget/index.tsx
  • app/client/src/pages/Editor/Explorer/Actions/ActionEntityContextMenu.tsx
  • app/client/src/entities/Action/actionProperties.test.ts
  • app/client/src/components/editorComponents/CodeEditor/EvaluatedValuePopup.tsx
  • app/client/src/utils/autocomplete/tests/TernServer.test.ts
  • app/client/src/PluginActionEditor/components/PluginActionForm/components/CommonEditorForm/components/EmbeddedDatasourcePathField.tsx
  • app/client/src/widgets/ListWidget/widget/propertyConfig.ts
  • app/client/src/ce/entities/DataTree/dataTreeJSAction.ts
  • app/client/src/widgets/RadioGroupWidget/widget/index.tsx
  • app/client/src/utils/widgetRenderUtils.tsx
  • app/client/src/utils/helpers.test.ts
  • app/client/src/widgets/TableWidget/widget/propertyConfig.ts
  • app/client/src/entities/DataTree/dataTreeWidget.ts
  • app/client/src/widgets/FilePickerWidgetV2/widget/index.tsx
  • app/client/src/components/editorComponents/CodeEditor/index.tsx
🧰 Additional context used
🧠 Learnings (1)
app/client/src/utils/autocomplete/CodemirrorTernService.ts (1)
Learnt from: ashit-rath
PR: appsmithorg/appsmith#33726
File: app/client/src/utils/autocomplete/CodemirrorTernService.ts:199-199
Timestamp: 2024-11-12T08:11:36.416Z
Learning: The `entityDef` property in `CodeMirrorTernService` class within `CodemirrorTernService.ts` is intentionally initialized as an empty object.
⏰ Context from checks skipped due to timeout of 90000ms (5)
  • GitHub Check: client-unit-tests / client-unit-tests
  • GitHub Check: client-lint / client-lint
  • GitHub Check: client-prettier / prettier-check
  • GitHub Check: client-build / client-build
  • GitHub Check: client-check-cyclic-deps / check-cyclic-dependencies
🔇 Additional comments (28)
app/client/src/ce/entities/DataTree/isDynamicEntity.ts (1)

1-7: LGTM! Import path update aligns with PR objective.

The consolidation of type imports from ee/entities/DataTree/types helps reduce cyclic dependencies.

app/client/src/utils/NavigationSelector/WidgetChildren.ts (1)

1-3: LGTM! Import path update is consistent.

The change maintains functionality while consolidating type imports.

app/client/src/utils/NavigationSelector/JsChildren.ts (1)

1-3: LGTM! Import path update is consistent.

The change aligns with the PR's goal of reducing cyclic dependencies.

app/client/src/ce/entities/DataTree/dataTreeAction.ts (1)

1-2: LGTM! Import path update is consistent.

The change aligns with the PR's goal of reducing cyclic dependencies.

app/client/src/components/formControls/DynamicTextFieldControl.tsx (1)

21-21: LGTM! Import path update aligns with dependency cleanup.

The change correctly updates the import path for EvaluationSubstitutionType to the new centralized location.

app/client/src/utils/FilterInternalProperties/__tests__/index.test.ts (1)

2-10: LGTM! Import paths correctly updated.

The import paths have been properly updated to use the new centralized location for types, maintaining test functionality.

app/client/src/components/editorComponents/CodeEditor/commandsHelper.ts (1)

11-11: LGTM! Import path correctly updated.

The import path for ENTITY_TYPE has been properly updated to the new centralized location.

app/client/src/selectors/navigationSelectors.ts (2)

2-6: LGTM! Import paths correctly updated and organized.

The imports have been properly updated and grouped together for better organization.


56-56: LGTM! Type export enhances type safety.

The new EntityNavigationData type export provides better type safety for navigation data records.

app/client/src/selectors/dataTreeSelectors.ts (1)

20-21: Import path update looks good!

The import path change for ENTITY_TYPE aligns with the PR objective of reducing cyclic dependencies.

app/client/src/components/editorComponents/CodeEditor/generateQuickCommands.tsx (1)

8-8: Import path update looks good!

The import path change for ENTITY_TYPE aligns with the PR objective of reducing cyclic dependencies.

app/client/src/widgets/TableWidgetV2/widget/propertyConfig/contentConfig.ts (1)

7-7: Import path update looks good!

The import path change for EvaluationSubstitutionType aligns with the PR objective of reducing cyclic dependencies.

app/client/src/widgets/MapWidget/widget/index.tsx (1)

10-10: Import path update looks good!

The import path change for EvaluationSubstitutionType aligns with the PR objective of reducing cyclic dependencies.

app/client/src/widgets/FilepickerWidget/widget/index.tsx (3)

14-14: Import path updated to use enterprise edition types.

The import path for EvaluationSubstitutionType has been updated to use the enterprise edition types module.


302-304: LGTM! Default properties map implementation.

The static method returns an empty object as expected for this widget.


306-311: Verify the derived properties implementation.

The derived properties map defines two properties:

  1. isValid: Checks if the widget is required and has files selected
  2. files: Maps selected files with appropriate data format

Please ensure that:

  1. The file data mapping handles all possible file data types
  2. Error handling is in place for invalid file data
app/client/src/widgets/DropdownWidget/widget/index.tsx (2)

15-15: Import path updated to use enterprise edition types.

The import path for EvaluationSubstitutionType has been updated to use the enterprise edition types module.


491-499: Lifecycle method implementation looks good.

The componentDidUpdate method correctly handles:

  1. Changes to defaultOptionValue
  2. Changes to option prop
  3. Updates selected option accordingly
app/client/src/widgets/MultiSelectWidget/widget/index.tsx (1)

20-20: Import path updated to use enterprise edition types.

The import path for EvaluationSubstitutionType has been updated to use the enterprise edition types module.

app/client/src/plugins/Linting/utils/getLintingErrors.ts (1)

45-48: Import paths updated to use enterprise edition types.

The imports for ENTITY_TYPE and AppsmithEntity have been updated to use the enterprise edition types module.

app/client/src/widgets/MultiSelectTreeWidget/widget/index.tsx (1)

9-9: LGTM! Import path update aligns with dependency cleanup.

The change to import EvaluationSubstitutionType from ee/entities/DataTree/types helps reduce cyclic dependencies.

app/client/src/widgets/SelectWidget/widget/index.tsx (2)

6-6: LGTM! Import path update aligns with dependency cleanup.

The change to import EvaluationSubstitutionType from ee/entities/DataTree/types helps reduce cyclic dependencies.


65-65: LGTM! Widget type identifier added.

Adding the static type property helps with widget identification and categorization.

app/client/src/utils/autocomplete/CodemirrorTernService.ts (2)

11-11: LGTM! Import path update aligns with dependency cleanup.

The change to import ENTITY_TYPE from ee/entities/DataTree/types helps reduce cyclic dependencies.


1401-1403: LGTM! Simple and focused method for updating recent entities.

The method provides a clean way to update the recentEntities list used for autocomplete sorting.

app/client/src/widgets/MultiSelectWidgetV2/widget/index.tsx (3)

7-7: LGTM! Import path update aligns with dependency reduction.

The change in import path for EvaluationSubstitutionType helps reduce cyclic dependencies.


889-954: LGTM! Well-implemented event handlers.

The event handlers (onOptionChange, onFilterChange, onDropdownOpen, onDropdownClose) are properly implemented with:

  • Consistent error handling
  • Proper type safety
  • Clear execution patterns

957-994: LGTM! Clear and well-typed interfaces.

The interfaces (OptionValue, DropdownOption, MultiSelectWidgetProps) are properly defined with clear types and good documentation.

@hetunandu hetunandu added the ok-to-test Required label for CI label Feb 14, 2025
@hetunandu hetunandu merged commit 1a60eaa into release Feb 14, 2025
52 checks passed
@hetunandu hetunandu deleted the fix/data-tree-cycle-deps branch February 14, 2025 12:56
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Bug Something isn't working ok-to-test Required label for CI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants