-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[bootstrap] No longer build TS refs automatically #91781
Conversation
f71961a
to
32afd23
Compare
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.
LGTM
src/dev/ci_setup/setup.sh
Outdated
@@ -25,7 +25,7 @@ echo "build --remote_header=x-buildbuddy-api-key=$KIBANA_BUILDBUDDY_CI_API_KEY" | |||
### install dependencies | |||
### | |||
echo " -- installing node.js dependencies" | |||
yarn kbn bootstrap --verbose | |||
BUILD_TS_REFS_ON_BOOTSTRAP=true yarn kbn bootstrap --verbose |
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.
@brianseeders, there are issues with running scripts/build_ts_refs
with symlinked node modules, which was attempted here. What would be the best way to go about running that not the main workspace and not through tasks, but not block anything downstream?
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.
@tylersmalley You could try creating a new task in tasks.groovy
that does something like
// this could go directly in the tasks array in tasks.check() like this, or you could put it in a separate function
{
dir("${env.WORKSPACE}/kibana") {
kibanaPipeline.scriptTask('Build TS Refs', 'test/scripts/jenkins_build_ts_refs.sh')()
}
}
This should let a task process switch back to the original workspace to run the script. Not super great, we have to be careful we don't have multiple things running out of that workspace that could conflict with each other. Other than that, it should get the job done I think.
c6e5159
to
4435a31
Compare
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
20c12bf
to
2eb0bb4
Compare
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
@elasticmachine merge upstream |
💔 Build Failed
Failed CI StepsMetrics [docs]
History
To update your PR or re-run it, just comment with: |
Holding off on attempting to fix this for CI to see how #92513 does. |
The building of TS references is to address Typescript being otherwise unusable in an IDE. The time this task has taken has increased greatly over the past couple of weeks as teams have migrated to project references. Quite a few folks have reached out asking how to disable this, and after discussing with @kobelb we feel that we should make it opt-in for now.
Some options which have been discussed:
node scripts/build_ts_refs
when they feel it's necessary.BUILD_TS_REFS_CACHE_ENABLE=true
)rm -rf src/core/target && ./node_modules/.bin/tsc -b src/core/tsconfig.json --extendedDiagnostics --generateTrace trace_output
chrome://tracing/
in Chrometrace.1.json
pos
references a line intypes.1.json
More information on project references: https://github.com/elastic/kibana/blob/master/docs/developer/best-practices/typescript.asciidoc#project-references