Skip to content
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

Make changes to try to prevent memory bugs in parcel resolver #9885

Merged
merged 33 commits into from
Aug 1, 2024
Merged
Show file tree
Hide file tree
Changes from 20 commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
7f1cbb6
Start moving towards memory-safe resolver
pyamada-atlassian Jul 29, 2024
974f4b1
Remove all unsafe from resolver
pyamada-atlassian Jul 29, 2024
0fcee25
Fix a few broken bits
pyamada-atlassian Jul 29, 2024
22d684d
Remove arenas entirely to avoid dead-locks
pyamada-atlassian Jul 29, 2024
df460ea
Fix only test
pyamada-atlassian Jul 29, 2024
ab3dfc4
Safe resolver
pyamada-atlassian Jul 30, 2024
fdc5a98
Fix warnings
pyamada-atlassian Jul 31, 2024
3e4921e
Update with optimisation on tsconfig loading
yamadapc Jul 31, 2024
a884630
Update with more optimisation
yamadapc Jul 31, 2024
b426ddb
Update lockfile
pyamada-atlassian Jul 31, 2024
8cf4fe4
Remove copies
yamadapc Jul 31, 2024
2fa3604
Merge branch 'pyamada/safe-resolver-final' of github.com:parcel-bundl…
yamadapc Jul 31, 2024
a5fcf50
Update with more benchmarks
yamadapc Jul 31, 2024
31f5990
Fix compilation
yamadapc Jul 31, 2024
fde5ec4
Update benchmarks with nodes
yamadapc Jul 31, 2024
859d1ab
Update with slower / older serde_json5
yamadapc Jul 31, 2024
80c5bfe
Don't init tracing
yamadapc Aug 1, 2024
f380f1e
Prepare to feature-flag resolver change
pyamada-atlassian Aug 1, 2024
5de2d1d
Feature-flag resolver changes
pyamada-atlassian Aug 1, 2024
5ac79e2
Update with deprecation notice
pyamada-atlassian Aug 1, 2024
cbae027
Fix warnings
pyamada-atlassian Aug 1, 2024
9ffb9e1
Remove debug log
pyamada-atlassian Aug 1, 2024
5f9e9a7
Remove generated entries benchmark test
pyamada-atlassian Aug 1, 2024
ac5ce1d
Remove debug statement
pyamada-atlassian Aug 1, 2024
ce715be
Run tests with both resolvers
pyamada-atlassian Aug 1, 2024
858e12a
Remove unused dependency
pyamada-atlassian Aug 1, 2024
3bd1053
Fix flow error
pyamada-atlassian Aug 1, 2024
3c2fe22
Fix a few mistakes in JS wrapper
pyamada-atlassian Aug 1, 2024
40e64df
Fix feature-flag mistakes
pyamada-atlassian Aug 1, 2024
6c21293
Fix more flow issues
pyamada-atlassian Aug 1, 2024
c7afef4
Try to fix windows compilation
pyamada-atlassian Aug 1, 2024
680bd32
Fix wasm compilation
pyamada-atlassian Aug 1, 2024
ea53fd9
Add UTF-8 conversion to fix wasm
pyamada-atlassian Aug 1, 2024
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
219 changes: 217 additions & 2 deletions Cargo.lock

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

1 change: 1 addition & 0 deletions crates/json-comments-rs/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ fn strip_buf(
/// \n} ");
///
/// ```
#[deprecated]
pub fn strip_comments_in_place(
s: &mut str,
settings: CommentSettings,
Expand Down
2 changes: 2 additions & 0 deletions crates/node-bindings/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ parcel = { path = "../parcel" }
parcel_core = { path = "../parcel_core" }
parcel-js-swc-core = { path = "../../packages/transformers/js/core" }
parcel-resolver = { path = "../../packages/utils/node-resolver-rs" }
parcel-resolver-old = { path = "../../packages/utils/node-resolver-rs-old" }
parcel_package_manager = { path = "../parcel_package_manager" }
parcel_plugin_transformer_js = { path = "../parcel_plugin_transformer_js" }
parcel_napi_helpers = { path = "../parcel_napi_helpers" }
Expand All @@ -41,6 +42,7 @@ xxhash-rust = { version = "0.8.2", features = ["xxh3"] }
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
parcel = { path = "../parcel", features = ["nodejs"] }
parcel-dev-dep-resolver = { path = "../../packages/utils/dev-dep-resolver" }
parcel-dev-dep-resolver-old = { path = "../../packages/utils/dev-dep-resolver-old" }
parcel-macros = { path = "../macros", features = ["napi"] }

crossbeam-channel = "0.5.6"
Expand Down
1 change: 1 addition & 0 deletions crates/node-bindings/src/init_sentry/sentry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ fn init_sentry() -> Result<(), Status> {
return Ok(());
}

println!("INIT SENTRY");
yamadapc marked this conversation as resolved.
Show resolved Hide resolved
log::info!("Initialising Sentry in rust...");

if SENTRY_GUARD.lock().is_some() {
Expand Down
1 change: 1 addition & 0 deletions crates/node-bindings/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ mod image;
#[cfg(not(target_arch = "wasm32"))]
mod parcel;
mod resolver;
mod resolver_old;
mod transformer;

#[cfg(target_arch = "wasm32")]
Expand Down
Loading
Loading