Skip to content

mgr/dashboard: bump angular to 20.3.29 - #66724

Merged
nizamial09 merged 6 commits into
ceph:mainfrom
rhcs-dashboard:upgrade-angular-20
Sep 15, 2026
Merged

nizamial09 merged 6 commits into
ceph:mainfrom
rhcs-dashboard:upgrade-angular-20

Conversation

@nizamial09

@nizamial09 nizamial09 commented Dec 23, 2025 •

Copy link
Copy Markdown
Member

First of all, bumping node to 24.19.0

Migrating to new esbuild builder (we were using old webpack builder),
and this could improve the build times and modernize the application.
Also pretty restrictive on the angular practices so the build will make
sure we don't fall short on the best practices.

https://medium.com/@fahrigedik/angular-application-builder-transitioning-from-webpack-to-esbuild-82afa505a077

ISSUES I FACED

  1. xml2js is a library that relies on node core modules (timers, stream),
    which the old webpack builder auto-polyfilled but esbuild does not and
    that fails the build with
Could not resolve
  "timers" in node_modules/xml2js/lib/parser.js

So I removed the xml2js dep and parsed the S3 ACL XML with
browser-native DOMParser via a new XmlService (which is written with the
help of claude so I don't miss anything there). Also added tests

✘ [ERROR] Could not resolve "~@ibm/plex/IBM-Plex-Mono/fonts/split/woff2/IBMPlexMono-Light-Cyrillic.woff2" [plugin angular-css-resource]

    src/styles.scss:8398:11:
      8398 │   src: url("../node_modules/@carbon/styles/scss/fonts||file:~@ib...
           ╵            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

which is fixed by removing ~ for @ibm/plex in styles scss

  1. strict module resolution and deep import blockages
[ERROR] TS2307: Cannot find module 'carbon-components-angular/treeview/tree-node.types' or its corresponding type declarations. [plugin angular-compiler]

    src/app/ceph/block/iscsi-target-details/iscsi-target-details.component.ts:3:21:
      3 │ ...{ Node } from 'carbon-components-angular/treeview/tree-node.types';
        ╵                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

I created a new tree-node model in the repo itself and left a clear
explanation in its start. Also raised an issue to carbon-components
angular.

Similarly

✘ [ERROR] TS2307: Cannot find module 'chart.js/dist/types/utils' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/ng2-charts/lib/ng-charts.provider.d.ts:3:28:
      3 │ import { DeepPartial } from 'chart.js/dist/types/utils';
        ╵                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~

and added the path to tsconfig.json. The solution is to bump ng2-charts
to v9+ but not doing it for now..
valor-software/ng2-charts#1991 (comment)

✘ [ERROR] TS2613: Module '".../brace-expansion/dist/esm/index"' has no default export. Did you mean to use 'import { expand } from "..."' instead? [plugin angular-compiler]

    src/app/ceph/cluster/hosts/host-form/host-form.component.ts:4:7:
      4 │ import expand from 'brace-expansion';
        ╵        ~~~~~~

another similar issue

  1. had to bump ng-bootstrap to 19 which is what angular 20 supports
✘ [ERROR] No matching export in "node_modules/@angular/core/fesm2022/core.mjs" for import "AfterRenderPhase"

    node_modules/@ng-bootstrap/ng-bootstrap/fesm2022/ng-bootstrap.mjs:2:287:
      2 │ ...ector, afterNextRender, AfterRenderPhase, LOCALE_ID, ViewChild, ...
        ╵                            ~~~~~~~~~~~~~~~~

✘ [ERROR] No matching export in "node_modules/@angular/core/fesm2022/core.mjs" for import "afterRender"

    node_modules/@ng-bootstrap/ng-bootstrap/fesm2022/ng-bootstrap.mjs:2:339:
      2 │ ...ID, ViewChild, forwardRef, afterRender, ApplicationRef, Environm...
        ╵                               ~~~~~~~~~~~
  1. override cypress module to common, cypress is still older
TSError: ⨯ Unable to compile TypeScript:
error TS5095: Option 'bundler' can only be used when 'module' is set to 'preserve' or to 'es2015' or later.

Fixes: https://tracker.ceph.com/issues/79687

Contribution Guidelines

  • To sign and title your commits, please refer to Submitting Patches to Ceph.

  • If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.

  • When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an x between the brackets: [x]. Spaces and capitalization matter when checking off items this way.

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands

You must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.

@github-actions

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs for another 30 days.
If you are a maintainer or core committer, please follow-up on this pull request to identify what steps should be taken by the author to move this proposed change forward.
If you are the author of this pull request, thank you for your proposed contribution. If you believe this change is still appropriate, please ensure that any feedback has been addressed and ask for a code review.

@github-actions github-actions Bot added the stale label Feb 21, 2026
@github-actions

Copy link
Copy Markdown

This pull request has been automatically closed because there has been no activity for 90 days. Please feel free to reopen this pull request (or open a new one) if the proposed change is still appropriate. Thank you for your contribution!

@github-actions github-actions Bot closed this Mar 23, 2026
@github-project-automation github-project-automation Bot moved this from New to Done in Ceph-Dashboard Mar 23, 2026
@nizamial09 nizamial09 reopened this Aug 21, 2026
@github-actions

Copy link
Copy Markdown

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@github-actions github-actions Bot removed the stale label Aug 21, 2026
@nizamial09 nizamial09 changed the title Upgrade angular 20 mgr/dashboard: bump angular to 20.3.29 Aug 21, 2026
@nizamial09
nizamial09 marked this pull request as ready for review August 21, 2026 08:30
@nizamial09
nizamial09 requested review from a team as code owners August 21, 2026 08:30
Comment on lines +1 to +35
import { Injectable } from '@angular/core';

/**
* Browser-native XML parsing service.
*
* This replaces the Node-only `xml2js` library, which requires Node core
* modules (`timers`, `stream`, ...) that cannot be bundled for the browser by
* esbuild (the Angular `application` builder). It reproduces the object shape
* produced by `xml2js` when configured with `{ explicitArray: false, trim: true }`,
* which is all the dashboard relies on:
*
* - the root element name becomes the single top-level key,
* - an element with only text resolves to its trimmed text value,
* - an element with children resolves to an object keyed by child tag name,
* - a tag that appears once is a value; a tag that repeats becomes an array.
*/
@Injectable({
providedIn: 'root'
})
export class XmlService {
/**
* Parse an XML string into a plain object.
*
* @param xml the XML string to parse
* @returns the parsed object, or `null` when the input is empty or malformed
*/
parse(xml: string): any {
if (!xml) {
return null;
}

const doc = new DOMParser().parseFromString(xml, 'application/xml');
if (doc.querySelector('parsererror') || !doc.documentElement) {
return null;
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should have this from backend. Frontend parsing raw S3 ACL XML is a smell.

have the backend convert the ACL to structured JSON

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i don't remember if there was any specific reason we chose to parse it in front-end. @Pegonzal ?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this could be done in a single place from the backend, don't recall a reason not to do it right now.
Just a heads up, one of the places this is being used is for xml input validation in the rgw lifecycles, that could trigger many requests. And also being used to parser xml ACL responses from the backend.

But I suppose all of this could be properly handled from the backend

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @Pegonzal. I've tested the current implementation which is working fine. I had a look at the back-end implementation too but that will introduce more changes to both UI and back-end so I will probably won't mix it with the angular PR. I opened a different tracker https://tracker.ceph.com/issues/80306 and assigned to me. I'll take care of it separately. cc: @afreen23

@nizamial09

Copy link
Copy Markdown
Member Author

CYpress failure

DevTools listening on ws://127.0.0.1:43697/devtools/browser/013d7939-7fa9-4b1a-9d70-dd73749d4af8
[2687117:0821/090257.386455:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.
Your configFile is invalid: /home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/src/pybind/mgr/dashboard/frontend/cypress.config.ts

It threw an error when required, check the stack trace below:

TSError: ⨯ Unable to compile TypeScript:
error TS5095: Option 'bundler' can only be used when 'module' is set to 'preserve' or to 'es2015' or later.

    at createTSError (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/ts-node/dist/index.js:311:16)
    at reportTSError (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/ts-node/dist/index.js:314:23)
    at /home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/ts-node/dist/index.js:686:17
    at Object.compile (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/ts-node/dist/index.js:743:35)
    at Module.m._compile (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/ts-node/dist/index.js:856:36)
    at node:internal/modules/cjs/loader:2003:10
    at Object.require.extensions.<computed> [as .ts] (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/ts-node/dist/index.js:859:16)
    at Module.load (node:internal/modules/cjs/loader:1594:32)
    at Module._load (node:internal/modules/cjs/loader:1396:12)
    at wrapModuleLoad (node:internal/modules/cjs/loader:255:19)
    at Module.require (node:internal/modules/cjs/loader:1617:12)
    at require (node:internal/modules/helpers:153:16)
    at loadFile (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/@packages/server/lib/plugins/child/run_require_async_child.js:89:14)
    at EventEmitter.<anonymous> (/home/jenkins-build/build/workspace/ceph-dashboard-pull-requests/build/src/pybind/mgr/dashboard/cypress/12.17.4/Cypress/resources/app/node_modules/@packages/server/lib/plugins/child/run_require_async_child.js:116:38)
    at EventEmitter.emit (node:events:509:28)
    at EventEmitter.emit (node:domain:489:12)
pid=2677784

@nizamial09

Copy link
Copy Markdown
Member Author

CYpress failure

override cypress module to common, cypress is still older

TSError: ⨯ Unable to compile TypeScript:
error TS5095: Option 'bundler' can only be used when 'module' is set to 'preserve' or to 'es2015' or later.

@epuertat
epuertat requested a balanced review from Copilot August 24, 2026 11:08

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Upgrades the Dashboard frontend to Angular 20 and Node.js 24, adopting the esbuild application builder and replacing incompatible dependencies/imports.

Changes:

  • Upgrades Angular, ng-bootstrap, Node.js, and build configuration.
  • Replaces xml2js with a browser-native XML service.
  • Removes unsupported deep imports and updates affected tests.

Reviewed changes

Copilot reviewed 29 out of 30 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/pybind/mgr/dashboard/frontend/tsconfig.spec.json Enables ES modules for tests.
src/pybind/mgr/dashboard/frontend/tsconfig.json Configures bundler resolution.
src/pybind/mgr/dashboard/frontend/src/styles/_carbon-defaults.scss Fixes IBM font resolution.
src/pybind/mgr/dashboard/frontend/src/app/shared/services/xml.service.ts Adds browser XML parsing.
src/pybind/mgr/dashboard/frontend/src/app/shared/services/xml.service.spec.ts Tests XML parsing.
src/pybind/mgr/dashboard/frontend/src/app/shared/services/tree-view.service.ts Uses the local tree-node type.
src/pybind/mgr/dashboard/frontend/src/app/shared/services/tree-view.service.spec.ts Updates tree service tests.
src/pybind/mgr/dashboard/frontend/src/app/shared/services/favicon.service.ts Updates the DOCUMENT import.
src/pybind/mgr/dashboard/frontend/src/app/shared/models/carbon-tree-node.ts Adds a local Carbon node model.
src/pybind/mgr/dashboard/frontend/src/app/shared/components/setup-step-card/setup-step-card.component.spec.ts Avoids ng-reflect assertions.
src/pybind/mgr/dashboard/frontend/src/app/core/navigation/notification-panel/notification-area/notification-area.component.spec.ts Updates component input assertions.
src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-multisite-details/rgw-multisite-details.component.ts Uses the local node model.
src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-tags-table/rgw-bucket-tags-table.component.ts Migrates ACL parsing.
src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-tags-table/rgw-bucket-tags-table.component.spec.ts Updates component construction.
src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-resource-page/rgw-bucket-resource-page.component.ts Migrates ACL parsing.
src/pybind/mgr/dashboard/frontend/src/app/ceph/rgw/rgw-bucket-form/rgw-bucket-form.component.ts Migrates form ACL parsing.
src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/hosts/host-form/host-form.component.ts Uses the supported named export.
src/pybind/mgr/dashboard/frontend/src/app/ceph/cluster/crushmap/crushmap.component.ts Uses the local node model.
src/pybind/mgr/dashboard/frontend/src/app/ceph/cephfs/cephfs-directories/cephfs-directories.component.ts Uses the local node model.
src/pybind/mgr/dashboard/frontend/src/app/ceph/cephfs/cephfs-directories/cephfs-directories.component.spec.ts Updates the node import.
src/pybind/mgr/dashboard/frontend/src/app/ceph/block/iscsi-target-details/iscsi-target-details.component.ts Uses the local node model.
src/pybind/mgr/dashboard/frontend/src/app/ceph/block/iscsi-target-details/iscsi-target-details.component.spec.ts Updates the node import.
src/pybind/mgr/dashboard/frontend/package.json Upgrades Angular dependencies.
src/pybind/mgr/dashboard/frontend/cypress/tsconfig.json Retains CommonJS for Cypress.
src/pybind/mgr/dashboard/frontend/CMakeLists.txt Updates build-time Node.js.
src/pybind/mgr/dashboard/frontend/angular.json Migrates to the esbuild builder.
src/pybind/mgr/dashboard/frontend/.nvmrc Updates local Node.js.
make-dist Updates distribution Node.js.
doc/dev/developer_guide/dash-devel.rst Documents the Node.js requirement.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +46 to +50
"@angular/animations": "20.3.29",
"@angular/common": "20.3.29",
"@angular/compiler": "20.3.29",
"@angular/core": "20.3.29",
"@angular/forms": "20.3.29",

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've took care of couple of them like @carbon/charts-angular, ng-cookie-service, eslint. Jest will require even more refactoring which I can take separately. for now it works as is. we might need to bump it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess same thing for this warning, right?

▲ [WARNING] Deprecation [plugin angular-sass]

    src/styles.scss:26:8:
      26 │ @import './src/styles/ceph-custom/basics';
         ╵         ^


  Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.
  
  More info and automated migrator: https://sass-lang.com/d/import

  The plugin "angular-sass" was triggered by this import

    angular:styles/global:styles:2:8:
      2 │ @import 'src/styles.scss';
        ╵         ~~~~~~~~~~~~~~~~~


▲ [WARNING] Deprecation [plugin angular-sass]

    src/styles.scss:80:16:
      80 │     background: darken($success, 15%);
         ╵                 ^


  Global built-in functions are deprecated and will be removed in Dart Sass 3.0.0.
  Use color.adjust instead.
  
  More info and automated migrator: https://sass-lang.com/d/import

  The plugin "angular-sass" was triggered by this import

    angular:styles/global:styles:2:8:
      2 │ @import 'src/styles.scss';
        ╵         ~~~~~~~~~~~~~~~~~


...

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yup, they are actually not because of this PR but from an older bump of angular. I will fix this once I finish with the angular upgrades. I am guessing I'll see some more error in the angular 21 bump.

@nizamial09
nizamial09 force-pushed the upgrade-angular-20 branch 2 times, most recently from 4337c6a to e416d9e Compare August 25, 2026 04:24
@nizamial09

Copy link
Copy Markdown
Member Author

couple of more important changes.

  1. default angular dist location is now dist/browser/* so updated the python code accordingly
  2. npm now needs to explicitly allow running post-install scripts from packages as part of the installation for security reasons. so manually allowing and denying some packages to run the post-install scripts

These are the approved ones

Approved cypress:
  added [email protected]
Approved esbuild:
  added [email protected]
Approved lmdb:
  added [email protected]
Approved msgpackr-extract:
  added [email protected]
Approved @parcel/watcher:
  added @parcel/[email protected]

These are denied. The carbon packages are simply running the telemetry
as part of the postinstall which is fine to be disallowed.

Denied @scarf/scarf:
  added @scarf/scarf
Denied @carbon/charts:
  added @carbon/charts
Denied @carbon/colors:
  added @carbon/colors
Denied @carbon/feature-flags:
  added @carbon/feature-flags
Denied @carbon/grid:
  added @carbon/grid
Denied @carbon/icons:
  added @carbon/icons
Denied @carbon/layout:
  added @carbon/layout
Denied @carbon/motion:
  added @carbon/motion
Denied @carbon/styles:
  added @carbon/styles
Denied @carbon/themes:
  added @carbon/themes
Denied @carbon/type:
  added @carbon/type
Denied @carbon/utils-position:
  added @carbon/utils-position
Denied carbon-components-angular:
  added carbon-components-angular
Denied core-js:
  added core-js
Denied cucumber-expressions:
  added cucumber-expressions
Denied es5-ext:
  added es5-ext

@github-actions

Copy link
Copy Markdown

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

Migrating to new esbuild builder (we were using old webpack builder),
and this could improve the build times and modernize the application.
Also pretty restrictive on the angular practices so the build will make
sure we don't fall short on the best practices.

https://medium.com/@fahrigedik/angular-application-builder-transitioning-from-webpack-to-esbuild-82afa505a077

**ISSUES I FACED**

1. xml2js is a library that relies on node core modules (timers, stream),
which the old webpack builder auto-polyfilled but esbuild does not and
that fails the build with

```
Could not resolve
  "timers" in node_modules/xml2js/lib/parser.js
```

So I removed the xml2js dep and parsed the S3 ACL XML with
browser-native DOMParser via a new XmlService (which is written with the
help of claude so I don't miss anything there). Also added tests

2.
```
✘ [ERROR] Could not resolve "~@ibm/plex/IBM-Plex-Mono/fonts/split/woff2/IBMPlexMono-Light-Cyrillic.woff2" [plugin angular-css-resource]

    src/styles.scss:8398:11:
      8398 │   src: url("../node_modules/@carbon/styles/scss/fonts||file:~@ib...
           ╵            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```

which is fixed by removing `~` for `@ibm/plex` in styles scss

3. strict module resolution and deep import blockages

```
[ERROR] TS2307: Cannot find module 'carbon-components-angular/treeview/tree-node.types' or its corresponding type declarations. [plugin angular-compiler]

    src/app/ceph/block/iscsi-target-details/iscsi-target-details.component.ts:3:21:
      3 │ ...{ Node } from 'carbon-components-angular/treeview/tree-node.types';
        ╵                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```

I created a new tree-node model in the repo itself and left a clear
explanation in its start. Also raised an issue to carbon-components
angular.

Similarly
```
✘ [ERROR] TS2307: Cannot find module 'chart.js/dist/types/utils' or its corresponding type declarations. [plugin angular-compiler]

    node_modules/ng2-charts/lib/ng-charts.provider.d.ts:3:28:
      3 │ import { DeepPartial } from 'chart.js/dist/types/utils';
        ╵                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~
```

and added the path to tsconfig.json. The solution is to bump ng2-charts
to v9+ but not doing it for now..
valor-software/ng2-charts#1991 (comment)

```
✘ [ERROR] TS2613: Module '".../brace-expansion/dist/esm/index"' has no default export. Did you mean to use 'import { expand } from "..."' instead? [plugin angular-compiler]

    src/app/ceph/cluster/hosts/host-form/host-form.component.ts:4:7:
      4 │ import expand from 'brace-expansion';
        ╵        ~~~~~~
```

another similar issue

4. had to bump `ng-bootstrap` to 19 which is what angular 20 supports

```
✘ [ERROR] No matching export in "node_modules/@angular/core/fesm2022/core.mjs" for import "AfterRenderPhase"

    node_modules/@ng-bootstrap/ng-bootstrap/fesm2022/ng-bootstrap.mjs:2:287:
      2 │ ...ector, afterNextRender, AfterRenderPhase, LOCALE_ID, ViewChild, ...
        ╵                            ~~~~~~~~~~~~~~~~

✘ [ERROR] No matching export in "node_modules/@angular/core/fesm2022/core.mjs" for import "afterRender"

    node_modules/@ng-bootstrap/ng-bootstrap/fesm2022/ng-bootstrap.mjs:2:339:
      2 │ ...ID, ViewChild, forwardRef, afterRender, ApplicationRef, Environm...
        ╵                               ~~~~~~~~~~~
```

5. override cypress module to common, cypress is still older
```
TSError: ⨯ Unable to compile TypeScript:
error TS5095: Option 'bundler' can only be used when 'module' is set to 'preserve' or to 'es2015' or later.
```

Fixes: https://tracker.ceph.com/issues/79687
Signed-off-by: Nizamudeen A <[email protected]>
relying on `ng-reflex-*` is wrong since its an angular debugging attr
which may/maynot exist during the testing. best way to guarantee success
here is by checkng the properties of componentInstance directly.

Fixes: https://tracker.ceph.com/issues/79687
Signed-off-by: Nizamudeen A <[email protected]>
this is the default angular location during the build. I can override
this in angular.json through `browser: ""` which I did initially but I
learned that when you run it through cli like `ng build --output-path
dist/` it will override the angular config and sent the build to
`dist/browser` which is what currently happens in the CI or CMakefile.
So instead of fighting with angular's default, accepting that here

Fixes: https://tracker.ceph.com/issues/79687
Signed-off-by: Nizamudeen A <[email protected]>
part of https://github.com/orgs/community/discussions/198547

the npm now needs to explicitly allow running post-install scripts as
part of the installation for security reasons. so manually allowing and
denying some packages to run the post-install scripts

These are the approved ones
```
Approved cypress:
  added [email protected]
Approved esbuild:
  added [email protected]
Approved lmdb:
  added [email protected]
Approved msgpackr-extract:
  added [email protected]
Approved @parcel/watcher:
  added @parcel/[email protected]
```

These are denied. The carbon packages are simply running the telemetry
as part of the postinstall which is fine to be disallowed.

```
Denied @scarf/scarf:
  added @scarf/scarf
Denied @carbon/charts:
  added @carbon/charts
Denied @carbon/colors:
  added @carbon/colors
Denied @carbon/feature-flags:
  added @carbon/feature-flags
Denied @carbon/grid:
  added @carbon/grid
Denied @carbon/icons:
  added @carbon/icons
Denied @carbon/layout:
  added @carbon/layout
Denied @carbon/motion:
  added @carbon/motion
Denied @carbon/styles:
  added @carbon/styles
Denied @carbon/themes:
  added @carbon/themes
Denied @carbon/type:
  added @carbon/type
Denied @carbon/utils-position:
  added @carbon/utils-position
Denied carbon-components-angular:
  added carbon-components-angular
Denied core-js:
  added core-js
Denied cucumber-expressions:
  added cucumber-expressions
Denied es5-ext:
  added es5-ext
```

Fixes: https://tracker.ceph.com/issues/79687
Signed-off-by: Nizamudeen A <[email protected]>
@nizamial09

Copy link
Copy Markdown
Member Author

unrelated make check

Tests (1 failure / ±0)
projectroot.run_rbd_unit_tests_N.sh

@nizamial09

Copy link
Copy Markdown
Member Author

jenkins test make check

@Pegonzal Pegonzal left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested it, working fine.

screen-capture.6.webm

NIT on my side:

Should this docs be updated to dist/browser?

Comment on lines +46 to +50
"@angular/animations": "20.3.29",
"@angular/common": "20.3.29",
"@angular/compiler": "20.3.29",
"@angular/core": "20.3.29",
"@angular/forms": "20.3.29",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess same thing for this warning, right?

▲ [WARNING] Deprecation [plugin angular-sass]

    src/styles.scss:26:8:
      26 │ @import './src/styles/ceph-custom/basics';
         ╵         ^


  Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.
  
  More info and automated migrator: https://sass-lang.com/d/import

  The plugin "angular-sass" was triggered by this import

    angular:styles/global:styles:2:8:
      2 │ @import 'src/styles.scss';
        ╵         ~~~~~~~~~~~~~~~~~


▲ [WARNING] Deprecation [plugin angular-sass]

    src/styles.scss:80:16:
      80 │     background: darken($success, 15%);
         ╵                 ^


  Global built-in functions are deprecated and will be removed in Dart Sass 3.0.0.
  Use color.adjust instead.
  
  More info and automated migrator: https://sass-lang.com/d/import

  The plugin "angular-sass" was triggered by this import

    angular:styles/global:styles:2:8:
      2 │ @import 'src/styles.scss';
        ╵         ~~~~~~~~~~~~~~~~~


...

@github-project-automation github-project-automation Bot moved this from Done to Reviewer approved in Ceph-Dashboard Sep 8, 2026
bumping eslint to a supported version, ngx-cook-eservice to 21.3.1 which
is what works for angular <22 and @carbon/charts-angular to 1.27.18

Fixes: https://tracker.ceph.com/issues/79687
Signed-off-by: Nizamudeen A <[email protected]>
@nizamial09

Copy link
Copy Markdown
Member Author

Should this docs be updated to dist/browser?

good point, updated that. while i was at it I made a small modification to say the production build is built by --configuration=production flag instead of the older --prod flag

@nizamial09
nizamial09 merged commit 7854296 into ceph:main Sep 15, 2026
15 of 16 checks passed
@nizamial09
nizamial09 deleted the upgrade-angular-20 branch September 15, 2026 08:38
@github-project-automation github-project-automation Bot moved this from Reviewer approved to Done in Ceph-Dashboard Sep 15, 2026
@batrick

batrick commented Sep 15, 2026

Copy link
Copy Markdown
Member

This is an automated message by src/script/redmine-upkeep.py.

I have resolved the following tracker ticket due to the merge of this PR:

No backports are pending for the ticket. If this is incorrect, please update the tracker
ticket and reset to Pending Backport state.

aainscow pushed a commit to aainscow/ceph that referenced this pull request Sep 18, 2026
mgr/dashboard: bump angular to 20.3.29

Reviewed-by: Afreen Misbah <[email protected]>
Reviewed-by: Pedro Gonzalez Gomez <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants