-
Notifications
You must be signed in to change notification settings - Fork 2.5k
chore(nx-dev): use continuous tasks in nx-dev #31127
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
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
View your CI Pipeline Execution ↗ for commit 98d94ec.
☁️ Nx Cloud last updated this comment at |
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.
Cool, was just running the docs locally and thought we should def update it to the new continuous tasks! Thanks
"dependsOn": ["sitemap"], | ||
"command": "ts-node -P ./scripts/tsconfig.scripts.json ./scripts/documentation/internal-link-checker.ts", |
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.
The change introduces a circular dependency in the task execution flow. Currently:
build
depends onsitemap
sitemap
depends onbuild-base
This creates a cycle that differs from the original execution order where build
depended on build-base
first, then ran the sitemap command.
To maintain the original execution order while using the new continuous task format, consider changing the dependency to:
"dependsOn": ["build-base"]
Then have the sitemap
task run before the link checker command, or include both commands in sequence.
"dependsOn": ["sitemap"], | |
"command": "ts-node -P ./scripts/tsconfig.scripts.json ./scripts/documentation/internal-link-checker.ts", | |
"dependsOn": ["build-base"], | |
"command": "ts-node -P ./scripts/tsconfig.scripts.json ./scripts/documentation/internal-link-checker.ts", |
Spotted by Diamond
Is this helpful? React 👍 or 👎 to let us know.
"serve": { | ||
"executor": "@nx/next:server", | ||
"dependsOn": ["copy-docs", "copy-tutorial"], | ||
"dependsOn": ["copy-docs", "copy-tutorial", "watch-docs"], |
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.
The serve
target depends on the continuous task watch-docs
, which by design never completes. This dependency structure may prevent the serve
target from executing properly, as it will wait for watch-docs
to complete before proceeding.
Consider one of these alternatives:
- Remove
watch-docs
from the dependency list and start both tasks in parallel using a parent task - Use the
"parallel": true
option in the dependency configuration - Restructure the workflow so that
watch-docs
runs independently
This ensures both tasks can run simultaneously without blocking each other.
"dependsOn": ["copy-docs", "copy-tutorial", "watch-docs"], | |
"dependsOn": [{"projects": ["copy-docs", "copy-tutorial", "watch-docs"], "parallel": true}], |
Spotted by Diamond
Is this helpful? React 👍 or 👎 to let us know.
Update nx-dev and tutorial tasks to use continuous tasks