Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 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
6 changes: 6 additions & 0 deletions crates/rspack_core/src/compilation/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1292,6 +1292,7 @@ impl Compilation {
));
chunks
} else {
self.chunk_render_artifact.clear();
self.chunk_by_ukey.keys().copied().collect()
};
let results = rspack_futures::scope::<_, Result<_>>(|token| {
Expand Down Expand Up @@ -1850,6 +1851,7 @@ impl Compilation {

modules
} else {
self.cgm_hash_artifact.clear();
Comment thread
jerrykingxyz marked this conversation as resolved.
self.get_module_graph().modules().keys().copied().collect()
};
self
Expand Down Expand Up @@ -1889,6 +1891,7 @@ impl Compilation {
));
modules
} else {
self.code_generation_results = Default::default();
self.get_module_graph().modules().keys().copied().collect()
};
self.code_generation(code_generation_modules).await?;
Expand Down Expand Up @@ -1931,6 +1934,7 @@ impl Compilation {
));
modules
} else {
self.cgm_runtime_requirements_artifact = Default::default();
self.get_module_graph().modules().keys().copied().collect()
};
self
Expand Down Expand Up @@ -1972,6 +1976,7 @@ impl Compilation {
));
affected_chunks
} else {
self.cgc_runtime_requirements_artifact.clear();
self.chunk_by_ukey.keys().copied().collect()
};
self
Expand Down Expand Up @@ -2372,6 +2377,7 @@ impl Compilation {
));
chunks
} else {
self.chunk_hashes_artifact.clear();
self.chunk_by_ukey.keys().copied().collect()
};

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = 'ok';
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
it('should recover when recreate file', function () {
switch (WATCH_STEP) {
case '0':
expect(require('./file')).toBe('ok');
break;
case '1':
expect(function () {
require('./file');
}).toThrow();
break;
case '2':
expect(require('./file')).toBe('ok');
break;
}
});
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = [/Module not found: Can't resolve/];
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DELETE
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = [/FlagDependencyUsagePlugin/];
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = 'ok';
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = [/FlagDependencyUsagePlugin/];
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/** @type {import("@rspack/core").Configuration} */
module.exports = {
optimization: {
usedExports: true,
},
};
Loading