Skip to content

docs(en): merge rollup/master into rollup-docs-cn/master @ 5a7f9e21 #180

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

Merged
merged 4 commits into from
Jun 27, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# rollup changelog

## 4.44.1

_2025-06-26_

### Bug Fixes

- Reinstate maxParallelFileOps limit of 1000 to resolve the issue for some (#5992)

### Pull Requests

- [#5988](https://github.com/rollup/rollup/pull/5988): fix(deps): lock file maintenance minor/patch updates (@renovate[bot], @lukastaegert)
- [#5992](https://github.com/rollup/rollup/pull/5992): Set maxParallelFileOps to 1000 (@lukastaegert)

## 4.44.0

_2025-06-19_
Expand Down
2 changes: 1 addition & 1 deletion browser/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@rollup/browser",
"version": "4.44.0",
"version": "4.44.1",
"description": "Next-generation ES module bundler browser build",
"main": "dist/rollup.browser.js",
"module": "dist/es/rollup.browser.js",
Expand Down
2 changes: 1 addition & 1 deletion docs/configuration-options/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -637,7 +637,7 @@ buildWithCache()
| -----: | :------------------------------ |
| 类型: | `number` |
| CLI: | `--maxParallelFileOps <number>` |
| 默认: | `Infinity` |
| 默认: | 1000 |

该选项限制 rollup 在读取模块或写入 chunk 时,同时能打开的文件数量。如果没有限制或者数值足够高,构建可能会失败,显示“EMFILE: Too many open files”(EMFILE:打开的文件数过多)。这取决于操作系统限制的句柄数(open file handles)大小。如果将限制设置得过低,并且使用了依赖 [`this.load`](../plugin-development/index.md#this-load) 上下文函数的插件(例如 `commonjs` 插件),那么可能会出现构建停滞且没有错误消息的情况,因为它限制了并行 `load` 调用的数量。

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rollup",
"version": "4.44.0",
"version": "4.44.1",
"description": "Next-generation ES module bundler",
"main": "dist/rollup.js",
"module": "dist/es/rollup.js",
Expand Down
7 changes: 5 additions & 2 deletions src/utils/options/normalizeInputOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,11 @@ const getMaxParallelFileOps = (
config: InputOptions
): NormalizedInputOptions['maxParallelFileOps'] => {
const maxParallelFileOps = config.maxParallelFileOps;
if (typeof maxParallelFileOps !== 'number' || maxParallelFileOps <= 0) return Infinity;
return maxParallelFileOps;
if (typeof maxParallelFileOps === 'number') {
if (maxParallelFileOps <= 0) return Infinity;
return maxParallelFileOps;
}
return 1000;
};

const getModuleContext = (
Expand Down
4 changes: 2 additions & 2 deletions test/function/samples/options-hook/_config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,8 @@ module.exports = defineTest({
name: 'test-plugin',
buildStart(options) {
// The fs option is not json stringifiable
const { fs, maxParallelFileOps, ...restOptions } = options;
const { fs, ...restOptions } = options;
assert.ok(fs);
assert.strictEqual(maxParallelFileOps, Infinity);
assert.deepStrictEqual(JSON.parse(JSON.stringify(restOptions)), {
context: 'undefined',
experimentalCacheExpiry: 10,
Expand All @@ -22,6 +21,7 @@ module.exports = defineTest({
jsx: false,
logLevel: 'info',
makeAbsoluteExternalsRelative: 'ifRelativeSource',
maxParallelFileOps: 1000,
perf: false,
plugins: [
{
Expand Down
Loading