You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(pack): honor externals for virtual requests - #3428
Explicit externals for URI requests such as virtual:request/h5 were skipped by the module-name filter. With an alias, the target was bundled alongside the direct external import, splitting mutable state between two instances. Without an alias, the original URI was loaded instead of the configured external target.
Match complete, literal request names before alias resolution so these imports use the configured external instance. Add executable Node regressions for alias plus externals, externals only, unscoped package subpaths, and literal glob characters.
CI pins Ubuntu 24.04 and the tested ecosystem harness revision from utooland/utoo-ecosystem-ci#10. This restores the supported environment after ubuntu-latest moved to Ubuntu 26.04, which broke the wasm-bindgen installer and EVJS Playwright browser installation before the candidate tests ran.
Test Plan
cargo test --locked -p pack-tests --test snapshot externals
Shows when each build phase is active and how much CPU it consumes. Self-Time is the time spent exclusively in that phase (excluding children).
Phase
Spans
Inclusive (ms)
Self-Time (ms)
Wall Range (ms)
Resolve
37,765
5,515.7
1,451.7
2,727.4
Parse
8,148
1,174.5
871.4
4,963.5
Analyze
122,190
35,918.4
7,674.2
4,888.2
Chunk
4,773
4,615.0
763.4
1,964.9
Codegen
8,054
1,771.5
1,142.9
1,703.5
Emit
29
36.3
18.2
7.8
Other
2,125
7,416.3
4,544.3
5,849.7
Workload Distribution by Diagnostic Tier
Category
Spans
Inclusive (ms)
% Work
Self-Time (ms)
% Self
P0: Scheduling & Resolution
160,218
41,909.1
232.9%
9,329.8
51.9%
P1: I/O & Heavy Tasks
2,602
104.7
0.6%
86.6
0.5%
P2: Architecture (Locks/Memory)
0
0.0
0.0%
0.0
0.0%
P3: Asset Pipeline
19,436
7,565.3
42.0%
2,769.6
15.4%
P4: Bridge/Interop
0
0.0
0.0%
0.0
0.0%
Other
828
6,868.5
38.2%
4,280.1
23.8%
Top 20 Tasks by Self-Time
Self-time is the exclusive duration: time spent in the task itself, not in sub-tasks.
This is the most accurate indicator of where CPU cycles are actually spent.
Self (ms)
Inclusive (ms)
Count
Avg Self (us)
P95 Self (ms)
Max Self (ms)
% Work
Task Name
Top Caller
3,684.2
21,246.5
82,524
44.6
0.1
14.5
20.5%
module
module (60%)
3,252.0
3,400.7
18
180665.1
373.2
701.7
18.1%
save snapshot
persist (6%)
2,034.0
2,169.4
2,280
892.1
3.0
209.3
11.3%
analyze ecmascript module
module (76%)
1,306.7
11,661.9
29,718
44.0
0.1
11.1
7.3%
process module
process module (81%)
986.4
2,725.2
20,937
47.1
0.1
6.0
5.5%
internal resolving
internal resolving (71%)
814.4
1,117.5
5,975
136.3
0.5
58.7
4.5%
parse ecmascript
parse ecmascript (66%)
675.3
4,395.4
3,873
174.4
0.1
151.8
3.8%
chunking
chunking (46%)
618.9
679.9
5,985
103.4
0.4
7.0
3.4%
precompute code generation
generate merged code (54%)
565.1
671.9
5,630
100.4
0.3
99.5
3.1%
compute async module info
compute async module info (50%)
539.2
1,765.0
598
901.7
2.1
175.7
3.0%
generate merged code
chunking (76%)
453.9
2,779.1
16,428
27.6
0.0
5.1
2.5%
resolving
module (62%)
374.4
374.4
329
1138.0
0.7
225.1
2.1%
generate source map
code generation (83%)
314.8
678.3
129
2440.4
4.0
188.1
1.7%
emit code
generate merged code (41%)
247.1
449.9
974
253.7
0.1
137.7
1.4%
write all entrypoints to disk
write all entrypoints to disk (10%)
149.6
717.2
1,740
86.0
0.2
39.3
0.8%
code generation
code generation (83%)
149.5
149.5
8
18685.0
67.8
82.1
0.8%
blocking
save snapshot (75%)
85.7
216.6
868
98.7
0.2
9.2
0.5%
compute async chunks
compute async chunks (55%)
57.0
57.0
2,170
26.3
0.0
7.1
0.3%
read file
parse ecmascript (91%)
49.0
61.3
634
77.2
0.0
26.2
0.3%
compute binding usage info
compute binding usage info (56%)
24.3
48.0
1,387
17.5
0.0
9.3
0.1%
collect mergeable modules
collect mergeable modules (100%)
Critical Path Analysis
The longest sequential dependency chains that determine wall-clock time.
Focus on reducing the depth of these chains to improve parallelism.
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
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.
Summary
Explicit externals for URI requests such as
virtual:request/h5were skipped by the module-name filter. With an alias, the target was bundled alongside the direct external import, splitting mutable state between two instances. Without an alias, the original URI was loaded instead of the configured external target.Match complete, literal request names before alias resolution so these imports use the configured external instance. Add executable Node regressions for alias plus externals, externals only, unscoped package subpaths, and literal glob characters.
Closes #3427.
CI pins Ubuntu 24.04 and the tested ecosystem harness revision from utooland/utoo-ecosystem-ci#10. This restores the supported environment after
ubuntu-latestmoved to Ubuntu 26.04, which broke the wasm-bindgen installer and EVJS Playwright browser installation before the candidate tests ran.Test Plan
cargo test --locked -p pack-tests --test snapshot externalscargo fmt --checkcargo clippy --all-targets -- -D warnings --no-depsnpx tombi format --check,npx biome ci, andtypos