Skip to content

Conversation

@sondermanish
Copy link
Contributor

@sondermanish sondermanish commented Dec 30, 2025

Description

Tip

Add a TL;DR when the description is longer than 500 words or extremely technical (helps the content, marketing, and DevRel team).

Please also include relevant motivation and context. List any dependencies that are required for this change. Add links to Notion, Figma or any other documents that might be relevant to the PR.

Fixes #Issue Number
or
Fixes Issue URL

Warning

If no issue exists, please create an issue first, and check with the maintainers if the issue is valid.

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/20603821286
Commit: 8bec483
Cypress dashboard.
Tags: @tag.Sanity
Spec:


Tue, 30 Dec 2025 19:41:56 UTC

Communication

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

  • Yes
  • No

Summary by CodeRabbit

  • Bug Fixes
    • Improved git branch URL parameter handling to properly synchronize branch metadata across the application.

✏️ Tip: You can customize this high-level summary in your review settings.

@sondermanish sondermanish self-assigned this Dec 30, 2025
@github-actions github-actions bot added the skip-changelog Adding this label to a PR prevents it from being listed in the changelog label Dec 30, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 30, 2025

Walkthrough

The loadGit() method in AppViewerEngine was converted from a no-op to a functional generator that creates a tracing span, retrieves git branch metadata from Redux state, conditionally updates the URL branch parameter, and closes the span.

Changes

Cohort / File(s) Summary
Git branch initialization
app/client/src/entities/Engine/AppViewerEngine.ts
Implemented loadGit(applicationId: string, rootSpan: Span) generator to initialize git branch tracking. Now creates nested span, reads current app's branch metadata from Redux store via inline selector, conditionally applies updateBranchParam() to update URL state, and completes span lifecycle. Added imports for updateBranchParam and DefaultRootState.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🌿 A no-op becomes a spark,
Git branches now emerge from the dark,
Redux whispers branch names with grace,
URLs dance to their proper place,
Spans trace the journey true! 📍

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description check ⚠️ Warning The PR description follows the template structure but lacks critical implementation details, issue reference, and context about the changes. Fill in the issue reference (Fixes #XXX), provide motivation and context for the loadGit() method changes, and describe why branch updates are needed after consolidated API load.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change—the loadGit method now executes after consolidated API loading to update the branch parameter.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@sondermanish sondermanish added the ok-to-test Required label for CI label Dec 30, 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 (1)
app/client/src/entities/Engine/AppViewerEngine.ts (1)

50-50: Remove or justify the unused applicationId parameter.

The applicationId parameter is declared but never used in the method body. If it's not needed, remove it; if it's for future use or interface consistency, prefix it with an underscore (_applicationId) to indicate it's intentionally unused.

🔎 Proposed fix if parameter is not needed
-  *loadGit(applicationId: string, rootSpan: Span) {
+  *loadGit(rootSpan: Span) {
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 977f437 and 8bec483.

📒 Files selected for processing (1)
  • app/client/src/entities/Engine/AppViewerEngine.ts
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: Aishwarya-U-R
Repo: appsmithorg/appsmith PR: 29405
File: app/client/cypress/e2e/Regression/ClientSide/Binding/TableV2_Widget_API_Pagination_spec.js:37-41
Timestamp: 2024-07-26T21:12:57.228Z
Learning: The pull request titled "test: Cypress | Replace static with Dynamic waits - Part 1" is part of a phased approach where only certain test specifications are targeted for static wait removal in the initial phase. Future phases will address additional specs.
Learnt from: Aishwarya-U-R
Repo: appsmithorg/appsmith PR: 29405
File: app/client/cypress/e2e/Regression/ClientSide/Binding/TableV2_Widget_API_Pagination_spec.js:37-41
Timestamp: 2024-10-08T15:32:39.374Z
Learning: The pull request titled "test: Cypress | Replace static with Dynamic waits - Part 1" is part of a phased approach where only certain test specifications are targeted for static wait removal in the initial phase. Future phases will address additional specs.
Learnt from: brayn003
Repo: appsmithorg/appsmith PR: 37830
File: app/client/packages/git/src/actions/checkoutBranchActions.ts:11-18
Timestamp: 2024-11-29T05:38:54.262Z
Learning: In the Git Redux actions (`app/client/packages/git/src/actions`), the `createSingleArtifactAction` function already handles loading state and error management, so additional checks in action creators are unnecessary.
📚 Learning: 2024-10-11T09:28:32.636Z
Learnt from: brayn003
Repo: appsmithorg/appsmith PR: 36622
File: app/client/src/entities/Engine/AppEditorEngine.ts:0-0
Timestamp: 2024-10-11T09:28:32.636Z
Learning: In the file `app/client/src/entities/Engine/AppEditorEngine.ts`, the IDs (`currentApplication.baseId`) and branches (`currentBranch`) are obfuscated, so it's acceptable to log them for debugging purposes.

Applied to files:

  • app/client/src/entities/Engine/AppViewerEngine.ts
📚 Learning: 2024-12-15T17:45:48.303Z
Learnt from: brayn003
Repo: appsmithorg/appsmith PR: 38171
File: app/client/src/git/components/DefaultBranch/DefaultBranchCE.tsx:1-14
Timestamp: 2024-12-15T17:45:48.303Z
Learning: In `app/client/src/git/components/DefaultBranch/DefaultBranchCE.tsx`, the feature flag check is performed at a higher level, so it's acceptable to have `isGitProtectedFeatureLicensed={false}` in this component.

Applied to files:

  • app/client/src/entities/Engine/AppViewerEngine.ts
📚 Learning: 2024-12-11T08:25:39.197Z
Learnt from: brayn003
Repo: appsmithorg/appsmith PR: 38088
File: app/client/src/git/components/GitContextProvider/hooks/useGitBranches.ts:40-43
Timestamp: 2024-12-11T08:25:39.197Z
Learning: In `app/client/src/git/components/GitContextProvider/hooks/useGitBranches.ts`, the `useMemo` hook includes dependencies `artifactType` and `baseArtifactId` in its dependency array.

Applied to files:

  • app/client/src/entities/Engine/AppViewerEngine.ts
🧬 Code graph analysis (1)
app/client/src/entities/Engine/AppViewerEngine.ts (3)
app/client/src/instrumentation/types.ts (1)
  • Span (15-15)
app/client/src/instrumentation/generateTraces.ts (2)
  • startNestedSpan (42-63)
  • endSpan (65-67)
app/client/src/git/helpers/updateBranchParam.ts (1)
  • updateBranchParam (4-12)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
  • GitHub Check: client-lint / client-lint
  • GitHub Check: client-prettier / prettier-check
  • GitHub Check: client-unit-tests / client-unit-tests
  • GitHub Check: client-build / client-build
  • GitHub Check: client-check-cyclic-deps / check-cyclic-dependencies
🔇 Additional comments (3)
app/client/src/entities/Engine/AppViewerEngine.ts (3)

36-37: LGTM: Imports are appropriate.

Both imports are correctly used in the loadGit method below.


51-51: LGTM: Tracing span management is correct.

The span creation and cleanup follows the established pattern used in other methods of this class.

Also applies to: 66-66


55-64: The state path state.ui.applications.currentApplication?.gitApplicationMetadata?.branchName is correct and properly populated from the consolidated API response. No changes needed—the current implementation follows established codebase patterns where synchronous side effects like history.replace() are called directly without wrapping in call() effects (57 direct calls vs. 0 wrapped in sagas).

Likely an incorrect or invalid review comment.

@sondermanish sondermanish enabled auto-merge (squash) December 30, 2025 19:11
@sondermanish sondermanish merged commit 8f25927 into release Dec 31, 2025
50 checks passed
@sondermanish sondermanish deleted the chore/view-mode-branch-update branch December 31, 2025 07:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ok-to-test Required label for CI skip-changelog Adding this label to a PR prevents it from being listed in the changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants