Setup
- Rancher version: reproduced with
2.13.2
- Rancher UI Extensions: Extension with shell
3.0.10 and a custom list view
- Browser type & version: n/a
Describe the bug
In Dashboard we introduced ExtensionPoint.TABLE = 'Table' in @rancher/shell 3.0.9, but the Rancher 2.13 dashboard's extension manager singleton was never rebuilt with that enum value.
Dashboard creates the singleton via createExtensionManager() in extension-manager-impl.js. At initialisation, it loops over ExtensionPoint and creates uiConfig keys — but the 2.13 Dashboard's ExtensionPoint enum doesn't include 'Table'.
The extension bundles @rancher/shell 3.0.10 which does have ExtensionPoint.TABLE. When Dashboard components call getApplicableExtensionEnhancements() from plugin-helpers.ts, it calls $extension.getUIConfig('Table', uiArea) on the singleton at extension-manager-impl.js
return uiConfig[type][uiArea] || [];
which throws the errror: uiConfig['Table'] is undefined
Biggest problem is that even though ExtensionPoint.TABLE exists in this new shell, the Dashboard uses its own bundled singleton, not the extension's/shell copy, so it doesn't recognise it and therefore throws the error.
This brings increased difficulty in resolving this matter Shell side
To Reproduce
- provision a Rancher 2.13 system
- build an extension with a custom list view with shell
3.0.10 locally
- do
yarn serve-pkgs and do a developer load
- go to the custom list view page of the extension and observe the browser console
Result
Throws a console error
Expected Result
Should not throw a console error
Screenshots
Additional context
Setup
2.13.23.0.10and a custom list viewDescribe the bug
In Dashboard we introduced ExtensionPoint.TABLE = 'Table' in @rancher/shell
3.0.9, but the Rancher2.13dashboard's extension manager singleton was never rebuilt with that enum value.Dashboard creates the singleton via
createExtensionManager()inextension-manager-impl.js. At initialisation, it loops overExtensionPointand createsuiConfigkeys — but the2.13Dashboard'sExtensionPointenum doesn't include 'Table'.The extension bundles @rancher/shell
3.0.10which does haveExtensionPoint.TABLE. When Dashboard components callgetApplicableExtensionEnhancements()fromplugin-helpers.ts, it calls$extension.getUIConfig('Table', uiArea)on the singleton atextension-manager-impl.jsBiggest problem is that even though
ExtensionPoint.TABLEexists in this new shell, the Dashboard uses its own bundled singleton, not the extension's/shell copy, so it doesn't recognise it and therefore throws the error.This brings increased difficulty in resolving this matter Shell side
To Reproduce
3.0.10locallyyarn serve-pkgsand do a developer loadResult
Throws a console error
Expected Result
Should not throw a console error
Screenshots
Additional context