[9.3] Remove --no-experimental-require-module from node.options (#256379)#260158
Merged
patrykkopycinski merged 3 commits intoelastic:9.3from Apr 6, 2026
Merged
Conversation
…6379) ## Summary Removes the `--no-experimental-require-module` flag from `config/node.options`. The `require(esm)` feature has been **enabled by default since Node.js v22.12.0** (December 2024) and has been the default behavior across 10+ LTS patch releases. On Node 22.22.0 (our current version per `.nvmrc`), this opt-out flag is no longer necessary. ### Background - The flag was added when `require(esm)` was still behind `--experimental-require-module` and considered unstable. - Since v22.12.0, the feature is enabled by default — `--no-experimental-require-module` actively **disables** it. - ~95% of ESM-only npm packages work with `require(esm)`. The only limitation is modules with top-level `await` (which throw `ERR_REQUIRE_ASYNC_MODULE`). ### Risk Low — this restores the Node.js default behavior that has been shipping for over a year in LTS releases. Any ESM-related issues would have been surfaced across the broader Node ecosystem by now. ## Test plan - [ ] CI passes without the flag (validates no Kibana code depends on the old `ERR_REQUIRE_ESM` behavior) Made with [Cursor](https://cursor.com) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Updated build and development scripts to remove an experimental Node.js configuration flag across all npm scripts, including build, start, lint, and test commands. This simplifies the development and build process while maintaining all existing functionality. <!-- end of auto-generated comment: release notes by coderabbit.ai --> (cherry picked from commit 2c390fb) # Conflicts: # package.json # src/platform/packages/shared/kbn-mcp-dev-server/src/tools/run_ci_checks.test.ts
1 task
…ks test The test file was missing imports for execa, parseToolResultJsonContent, jest.mock() calls, and the mockedExeca variable, causing 25 type errors in CI. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
Author
|
/ci |
Contributor
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]
History
|
szwarckonrad
approved these changes
Apr 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport
This will backport the following commits from
mainto9.3:Questions ?
Please refer to the Backport tool documentation