Skip to content
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

feat(core): add spinners when graph compute takes long time #28966

Merged
merged 4 commits into from
Dec 16, 2024

Conversation

AgentEnder
Copy link
Member

Sometimes graph computation can take longer than may be expected. In these cases we can show a spinner, and if only one plugin is still running and the daemon is disabled also show the plugin names.

@AgentEnder AgentEnder requested a review from a team as a code owner November 15, 2024 19:52
Copy link

vercel bot commented Nov 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Updated (UTC)
nx-dev ⬜️ Ignored (Inspect) Visit Preview Dec 12, 2024 10:44pm

Copy link

nx-cloud bot commented Nov 15, 2024

Your CI Pipeline Execution ↗ for commit a5cd646 ⏳ is in progress.

Command Status Duration Result
nx affected --targets=lint,test,build,e2e,e2e-c... ✅ Succeeded 11m, 10s View ↗
nx run-many -t check-imports check-commit check... ✅ Succeeded 18s View ↗
nx-cloud record -- nx format:check --base=a8de7... ✅ Succeeded 1s View ↗
nx-cloud record -- nx-cloud conformance:check ✅ Succeeded 0s View ↗
nx-cloud record -- nx sync:check ✅ Succeeded 0s View ↗
nx documentation --no-dte ✅ Succeeded 0s View ↗

Last updated at 2024-12-13 03:24:12UTC

Sent with 💌 from NxCloud.

@AgentEnder AgentEnder force-pushed the chore/graph-spinners branch 3 times, most recently from bcbf720 to 4c8099c Compare December 5, 2024 22:14
Copy link
Collaborator

@FrozenPandaz FrozenPandaz left a comment

Choose a reason for hiding this comment

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

Spinner Text

Daemon Graph Spinner:
500ms
Calculating the project graph on the Nx Daemon

30s
Calculating the project graph on the Nx Daemon is taking longer than expected. Re-run with NX_DAEMON=false to see details

Nodes Spinner
Single: Creating project graph nodes with [pluginName]
Multiple: Creating project graph nodes with N plugins
Multiple (verbose): Creating project graph nodes with - plugin1\n- plugin2\n...

Dependencies Spinner
Single: Creating project graph dependencies with [pluginName]
Multiple: Creating project graph dependencies with N plugins
Multiple (verbose): Creating project graph dependencies with - plugin1\n- plugin2\n...

Metadata Spinner
Single: Creating project metadata with [pluginName]
Multiple: Creating project metadata with N plugins
Multiple (verbose): Creating project metadata with - plugin1\n- plugin2\n...

Comment on lines 331 to 333
let spinner: Ora,
timeout: NodeJS.Timeout,
spinnerUpdateInterval: NodeJS.Timeout;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Create a wrapper class for ora which handles this logic.

@AgentEnder AgentEnder force-pushed the chore/graph-spinners branch 6 times, most recently from 61b0965 to 7b567f4 Compare December 12, 2024 21:40
@FrozenPandaz FrozenPandaz changed the title chore(core): first draft of spinners when graph compute takes long time feat(core): add spinners when graph compute takes long time Dec 16, 2024
@FrozenPandaz FrozenPandaz merged commit 67d0e33 into master Dec 16, 2024
6 checks passed
@FrozenPandaz FrozenPandaz deleted the chore/graph-spinners branch December 16, 2024 19:01
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants