-
Type:
Bug
-
Status: Closed
-
Resolution: Duplicate
-
Affects Version/s: 6.1.1 CE GA2, 6.1.20 EE GA2
-
Fix Version/s: 6.1.30 EE GA3, 6.2.0 CE M4
-
Component/s: Frontend Infrastructure
-
Labels:None
On the response, modules were being loaded in dependency order.
Preparation:
Since we need to test that module dependency is preserved via comboURL, we are attempting to load the 'autocomplete-plugin' module, and beforehand load it's two immediate dependency modules: 'node-pluginhost' & 'autocomplete-list'.
Go ahead and open these three files, and put a unique alert or console log at the top of their files.
autocomplete-list.js
node-pluginhost.js
autocomplete-plugin.js
1. Start Portal
2. Create a New Page named Test
3. Navigate to Test
4. open browser console
5. execute the following statement: AUI({}).Get.script('http://localhost:8080/combo/?p=/html/js/aui&m=/autocomplete-list/autocomplete-list.js&m=/node-pluginhost/node-pluginhost.js&m=/autocomplete-plugin/autocomplete-plugin.js');
Notes:
autocomplete-plugin requires the 'node-pluginhost' & 'autocomplete-list' modules.
If you need to run this step multiple times, refresh the page first.
An alternative way to reproduce this is just to paste that url into a new tab and inspect the order of files that appear.
Result:
these three modules will load in reverse-sorted dependency order. that is:
The order before these commits (reverse abc):
1. node-pluginhost
2. autocomplete-plugin
3. autocomplete-list
The order after my initial fix (reverse dependency):
1. autocomplete-plugin
2. node-pluginhost
3. autocomplete-list
The expected behavior order (correct dependency order):
1. autocomplete-list
2. node-pluginhost
3. autocomplete-plugin
If autocomplete-list and node-pluginhost don't come before auto-completeplugin, the dependency chain is broken.
Note about the previous fix:
previously, modules were returned in reverse alphabetical order. Now, that we are no longer abc-sorting the list, they still appear in reverse order will still break dependency chain in some scenarios like this test.
- duplicates
-
LPS-33723 CLONE - Sorting paths for javascript modules disrupts the execution state if there are dependencies in a comboURL
- Closed