-
Notifications
You must be signed in to change notification settings - Fork 47.1k
fix: Assistant side panel open without blocking calls (no-changelog) #20714
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
BundleMonFiles added (2)
Total files change +255.73KB Groups added (2)
Final result: ✅ View report in BundleMon website ➡️ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 issue found across 9 files
Prompt for AI agents (all 1 issues)
Understand the root cause of the following 1 issues and fix them.
<file name="packages/frontend/editor-ui/src/api/ai.ts">
<violation number="1" location="packages/frontend/editor-ui/src/api/ai.ts:122">
Rule violated: **Prefer Typeguards over Type casting**
Replace the new `as IDataObject` assertion on the request payload with a type annotation or `satisfies`-based check to comply with the "Prefer Typeguards over Type casting" guideline.</violation>
</file>
React with 👍 or 👎 to teach cubic. Mention @cubic-dev-ai
to give feedback, ask questions, or re-run the review.
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
Summary
With the addition of the empty state to the builder side panel the opening of the panel had to be blocking. Since we load the messages when the panel opens we needed to know if there were messages to decide whether or not to show the empty state. This did however mean that the opening of the panel was blocking and could lead to some lag, it felt somewhat unpleasant.
To solve this, we now have a call to check if there are any messages currently for a workflow (endpoint POST
/sessions/metadata
) that occurs when the canvas/workflow loads. This means that we can open the panel immediately as we know whether or not we need to open the empty state already - messages can load in once they are available.Ticket: https://linear.app/n8n/issue/AI-1525/t2w-add-loading-state-to-builder-side-panel
Review / Merge checklist
release/backport
(if the PR is an urgent fix that needs to be backported)