-
Notifications
You must be signed in to change notification settings - Fork 75
Description
Expected Behavior
When I define a. custom bundle with option numberOfParts > 1, all defined sections of the custom bundle should be present in the result, including any section of mode bundleInfo.
Current Behavior
The AutoSplitter helper which splits an already resolved bundle into the configured number of parts, "ignores" sections of mode bundleInfo. The bundle infos are missing in the generated bundle parts.
Steps to Reproduce the Issue
Note: the following description only works for SAP employees
- fetch change 6561900 for the ushell library
- build the project for sap.ushell using Maven
- Check the content of the created sap/ushell/bootstrap/core-min-[0-3].js bundles. None of them contains a bundle info configuration.
Context
- UI5 Module Version (output of
ui5 --versionwhen using the CLI):4.0.16 - Node.js Version:
22.13.1 - npm Version:
10.9.2 - OS/Platform:
unknown
Log Output / Stack Trace
Log output while initial bundle definition is resolved (here, the bundleInfo section is still known and processed)
...
verb lbt:bundle:Resolver Resolving section 'sap/ushell/preload-bundles/flex-plugins.js' of type bundleInfo
verb lbt:resources:ResourceFilterList Filetypes: .js,.control.xml,.fragment.html,.fragment.json,.fragment.xml,.view.html,.view.json,.view.xml
verb lbt:resources:ResourceFilterList sap/ushell/plugins/BaseRTAPlugin.js --> include: "sap/ushell/plugins/BaseRTAPlugin.js"
verb lbt:resources:ResourceFilterList sap/ushell/appRuntime/ui5/plugins/baseRta/ --> include: /^sap\/ushell\/appRuntime\/ui5\/plugins\/baseRta\/(?:[^/]+\/)*[^/]*(?:\.js|\.control\.xml|\.fragment\.html|\.fragment\.json|\.fragment\.xml|\.view\.html|\.view\.json|\.view\.xml)$/
verb lbt:bundle:Resolver Resolving section of type require
...
Later, when the already split bundle definitions for the parts are processed:
verb lbt:bundle:Resolver Resolving bundle definition sap/ushell/bootstrap/core-min-3.js
verb lbt:bundle:Resolver Resolving section 'sap/ushell/core-lib-preload' of type preload
verb lbt:resources:ResourceFilterList Filetypes: .js,.control.xml,.fragment.html,.fragment.json,.fragment.xml,.view.html,.view.json,.view.xml
verb lbt:resources:ResourceFilterList sap/ushell/URLTemplateProcessor/Functions.js --> include: "sap/ushell/URLTemplateProcessor/Functions.js"
verb lbt:resources:ResourceFilterList sap/ushell/URLTemplateProcessor/Resolvers.js --> include: "sap/ushell/URLTemplateProcessor/Resolvers.js"
...
verb lbt:resources:ResourceFilterList sap/ushell/utils/workpage/WorkPageService.js --> include: "sap/ushell/utils/workpage/WorkPageService.js"
>>>> at this point, I would expect some log output that indicates the processing of the bundleInfo section <<<<
verb lbt:bundle:Resolver Resolving section of type require
verb lbt:resources:ResourceFilterList Filetypes: .js,.control.xml,.fragment.html,.fragment.json,.fragment.xml,.view.html,.view.json,.view.xml
verb lbt:resources:ResourceFilterList sap/ui/core/Core.js --> include: "sap/ui/core/Core.js"
verb lbt:bundle:Resolver Resolving bundle done
It's a bit hard to prove that something is missing in the log. But before the require section is processed for part 3, the bundleInfo should be processed. The log does not report anything for that section. Checking the source of the AutoSplitter here and here shows that it completely ignores sections of mode bundleInfo.