19202 Commits

Author SHA1 Message Date
Patrik Oldsberg adf228cb16 Merge pull request #33720 from backstage/rugvip/add-to-error-utility
errors: add `toError` utility and migrate usages
2026-04-07 12:00:01 +02:00
deepthi-28 aa47a370eb Add CheckboxGroup story and initial implementation (#33051)
* Add CheckboxGroup story and initial implementation

Signed-off-by: Deepthi Ajith <deepthi.ajith@infosys.com>

* Add CheckboxGroup implementation and docs coverage

Signed-off-by: Deepthi Ajith <deepthi.ajith@infosys.com>

* update api-reports

Signed-off-by: Deepthi Ajith <deepthi.ajith@infosys.com>

* fix: add more story variations, docs page, and fix JSDoc comments

Signed-off-by: Deepthi Ajith <deepthi.ajith@infosys.com>

* fix: address review feedback for CheckboxGroup component

Signed-off-by: Deepthi Ajith <deepthi.ajith@infosys.com>

---------

Signed-off-by: Deepthi Ajith <deepthi.ajith@infosys.com>
2026-04-07 10:58:29 +02:00
Jack Palmer 3595c974f6 feat(backend): add extensionPointFactoryMiddleware to createBackend
Allow the backend to reimplement extension point outputs at creation
time via a new extensionPointFactoryMiddleware option on createBackend().
Each middleware entry declaratively targets a specific extension point
by reference and the framework handles matching and pass-through
automatically.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-07 09:44:02 +01:00
Aramis Sennyey 9bca597026 fix: prevent backend server from hanging during e2e test (#32494)
* fix: prevent backend server from hanging during e2e test

Signed-off-by: aramissennyeydd <aramis.sennyey@doordash.com>

* add changeset

Signed-off-by: aramissennyeydd <aramis.sennyey@doordash.com>

* delete changeset

Signed-off-by: aramissennyeydd <aramis.sennyey@doordash.com>

---------

Signed-off-by: aramissennyeydd <aramis.sennyey@doordash.com>
2026-04-06 14:09:52 -04:00
Adam Letizia 85c5a4643b fix(backend-defaults): fixes actions registry http middleware conflicts
Signed-off-by: Adam Letizia <LetiziaAdam@JohnDeere.com>
2026-04-06 10:52:29 -05:00
Charles de Dreuille d10fbd3e29 Merge pull request #33744 from backstage/bui-badge 2026-04-03 20:40:08 +01:00
Patrik Oldsberg 205c8c8dc1 Merge pull request #33714 from backstage/rugvip/dev-db
cli: experimental embedded-postgres support for local dev
2026-04-03 21:07:15 +02:00
Patrik Oldsberg a4b9c45277 Merge pull request #33054 from StateFarmIns/theme-fix-mui-5-class-name-prefix
fix: MUI 5 v5- class name prefix reliability
2026-04-03 19:15:45 +02:00
Charles de Dreuille 4032ad7fc4 feat(ui): add Badge component
Adds a new `Badge` component to the Backstage UI library. Badge shares the same visual appearance as `Tag` (size tokens, colors, border radius, icon slot) but renders as a plain non-interactive `<span>` with no React Aria plumbing.

Key characteristics:
- Plain DOM element — accessible text content exposed to screen readers without any role override
- Background consumer — participates in the bg context system and steps up neutral background levels (`neutral-2` → `neutral-3` → `neutral-4`) when placed inside colored containers
- Supports `icon`, `size` (`small` | `medium`, defaults to `small`), `children`, and `className` props
- Fully themeable via `BadgeDefinition`

Also includes Storybook stories and full docs-ui documentation (props table, examples, theming section, changelog).

Signed-off-by: Charles de Dreuille <charles.dedreuille@gmail.com>
Made-with: Cursor
2026-04-03 17:19:02 +01:00
Fredrik Adelöw 75db4afdec Merge pull request #33742 from backstage/freben/host-discovery-baseurl-warnings
feat(backend-defaults): warn on localhost or invalid backend.baseUrl in HostDiscovery
2026-04-03 15:34:27 +02:00
Rajib Quayum 2c541a782b fix: prevent occasional duplication of the MUI v5 prefix
Signed-off-by: Rajib Quayum <rajibq@users.noreply.github.com>
2026-04-03 09:29:06 -04:00
Fredrik Adelöw 57543abb7c Update packages/backend-defaults/src/entrypoints/discovery/HostDiscovery.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Fredrik Adelöw <freben@gmail.com>
Signed-off-by: Fredrik Adelöw <freben@spotify.com>
Made-with: Cursor
Signed-off-by: Fredrik Adelöw <freben@spotify.com>
Made-with: Cursor
2026-04-03 15:01:45 +02:00
Fredrik Adelöw 308c672680 feat(backend-defaults): warn on localhost or invalid backend.baseUrl in HostDiscovery
Adds startup warnings to HostDiscovery.fromConfig when backend.baseUrl
is set to a localhost address in a production environment, or when the
value is not a valid URL at all.

Signed-off-by: Fredrik Adelöw <freben@spotify.com>
Made-with: Cursor
2026-04-03 14:48:26 +02:00
Patrik Oldsberg 482ceed6d2 Address review feedback: simplify toError and add changeset
- Remove JSON.stringify fallback from toError, use the same unknown
  error messaging as stringifyError for all non-string/non-error values
- Add try/catch to protect against values that throw on string
  conversion (e.g. null-prototype objects, symbols)
- Fix no-op `void toError(err)` in DeleteEntityConfirmationDialog
- Fix `${err}` producing [object Object] in UrlReaderProcessor
- Fix double toError call in openStackSwift
- Update JSDoc to accurately describe the behavior
- Add tests for throwing toString and circular objects
- Add changeset for all refactored packages

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-03 11:25:58 +02:00
Patrik Oldsberg b2319ffe45 errors: add toError utility and migrate assertError usages
Add a `toError` utility function to `@backstage/errors` that converts
unknown values to `ErrorLike` objects. If the value is already error-like
it is returned as-is. Strings are used directly as the error message, and
other values are stringified with a fallback to JSON.stringify to avoid
unhelpful `[object Object]` messages.

Non-error causes passed to `CustomErrorBase` are now converted and stored
using `toError` rather than discarded. Existing `assertError` call sites
across the codebase are migrated to `toError`.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-03 10:16:23 +02:00
Patrik Oldsberg 15660cfbf9 Merge pull request #33682 from backstage/github-support-app-no-org
Fix GitHub app credentials for bare host URLs
2026-04-03 00:58:55 +02:00
Roland Fuszenecker 21e7ec5d74 feat(backend-defaults): improve AWS RDS IAM auth error handling and token expiry
Signed-off-by: Roland Fuszenecker <roland.fuszenecker@seon.io>
2026-04-02 15:34:09 +02:00
Roland Fuszenecker c69e03ce3d feat(backend-defaults): add AWS RDS IAM authentication support for PostgreSQL
Signed-off-by: Roland Fuszenecker <roland.fuszenecker@seon.io>
2026-04-02 15:34:02 +02:00
Patrik Oldsberg c0908fe5b5 cli: add error handling for config close and startup failure cleanup
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-02 00:38:35 +02:00
Patrik Oldsberg 13c5f97337 cli: clean up stale embedded-postgres temp directories on startup
Uses a PID file to track which process owns each temp directory, so
concurrent instances from different projects are not affected.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-02 00:34:49 +02:00
Patrik Oldsberg 77d17a5110 cli: add experimental warning for embedded-postgres
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-02 00:34:48 +02:00
Patrik Oldsberg 7e7e763163 cli: add tests for embedded-postgres config detection
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-02 00:34:48 +02:00
Patrik Oldsberg 1f88d2624b cli: address review feedback for embedded-postgres
- Close embedded DB on shutdown to avoid leaking the Postgres process
  and temp directory
- Use fs.remove instead of deprecated fs.rmdir with recursive option
- Guard against absolute config paths in readDatabaseClient
- Forward embedded-postgres error logs to console.error

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-02 00:34:48 +02:00
Patrik Oldsberg ae1cdd9e9f cli: remove custom embedded-postgres type declarations
The 18.x version ships its own .d.ts files that TypeScript resolves
correctly, so the custom module declaration is no longer needed.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 21:30:27 +02:00
Patrik Oldsberg d80e59ce9e cli: bump embedded-postgres to 18.3.0-beta.16
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 21:26:28 +02:00
Patrik Oldsberg 7bf4814173 cli: make embedded-postgres an optional peer dependency
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 21:22:14 +02:00
Patrik Oldsberg 45075dddcd cli: use ForwardedError for embedded-postgres import failure
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 21:20:10 +02:00
Patrik Oldsberg a922b3b921 cli: fix error message for missing embedded-postgres dependency
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 21:19:28 +02:00
Patrik Oldsberg b43c1f1bcb cli: simplify config loading using ConfigSources.toConfig
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 19:55:11 +02:00
Patrik Oldsberg 6537e5f8c1 cli: fix type errors and test for embedded-postgres
Fix implicit any types in startEmbeddedDb callbacks, replace the
re-export type declaration with an inline type definition for the
embedded-postgres module, and update runBackend tests to mock the
config loading and use async timer advancement.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 15:40:31 +02:00
Patrik Oldsberg 7bc057e8b6 Merge pull request #33703 from backstage/feat/auth0-federated-logout
feat(auth): support provider logout redirects, implement Auth0 federated logout
2026-04-01 15:27:27 +02:00
Jack Palmer 208cf5f922 fix(auth): add security hardening and federated config for Auth0 logout
Add server-side URL validation for logoutUrl (HTTPS + localhost only),
origin validation on the logout endpoint, and a configurable `federated`
option (default false) for Auth0 provider logout. Includes comprehensive
test coverage for all security controls.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-01 13:06:43 +01:00
Jack Palmer 3532be4763 fix(auth): harden logout redirect with origin validation and protocol check
Add origin allowlist validation in the OAuth logout handler (matching
the existing start/refresh pattern) and validate the logoutUrl protocol
on the frontend before redirecting. Also replace inline type annotation
with the named OAuthAuthenticatorLogoutResult type.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jack Palmer <jackpalmer@spotify.com>
2026-04-01 13:06:43 +01:00
Patrik Oldsberg 538d0a1488 cli: enable embedded-postgres via config instead of env var
Rather than requiring the `EXPERIMENTAL_DEV_DB` environment variable,
the embedded postgres server is now started automatically when
`backend.database.client` is set to `embedded-postgres` in the app
config. The CLI reads the config before spawning the backend and
injects the actual pg connection details via env override.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 13:03:11 +02:00
Patrik Oldsberg f14df56222 cli: experimental support for using embedded-postgres as dev DB
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
2026-04-01 12:57:49 +02:00
Patrik Oldsberg b9fec1bdc8 Merge pull request #33642 from backstage/dist-workspace-pack-batching
cli-module-build: pack packages in batches inside createDistWorkspace
2026-04-01 11:54:21 +02:00
Fredrik Adelöw 9c953f9eff Merge pull request #32943 from Vivek1819/fix/scaffolder-markdown-links-new-tab
fix(scaffolder): open markdown links in new tab for template outputs
2026-04-01 11:49:20 +02:00
MT Lewis 8f174e18e9 cli-module-build: pack sequentially when cycles are detected in dependencies
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: MT Lewis <mtlewis@users.noreply.github.com>
2026-04-01 09:48:11 +01:00
Karthik 329f5920b6 feat(techdocs): add techdocs-cli option to disable external font download
Signed-off-by: Karthik <karthik.jk11@gmail.com>
2026-03-31 21:39:52 +05:30
Fredrik Adelöw f46363130c Update packages/core-components/src/components/MarkdownContent/MarkdownContent.tsx
Signed-off-by: Fredrik Adelöw <freben@gmail.com>
2026-03-31 17:54:39 +02:00
github-actions[bot] a2cb332e25 Version Packages (next) 2026-03-31 15:30:51 +00:00
Patrik Oldsberg 292b6431a2 Merge pull request #33688 from backstage/fix-frontend-plugin-legacy-id
Fix template name collision and export path in CLI new module
2026-03-31 17:24:04 +02:00
Fredrik Adelöw 0449cf02fd Update packages/core-components/src/components/MarkdownContent/MarkdownContent.tsx
Signed-off-by: Fredrik Adelöw <freben@gmail.com>
2026-03-31 17:20:34 +02:00
Jonathan Roebuck 906f104f6b feat(core-app-api): redirect to provider logoutUrl on sign-out when available
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Jonathan Roebuck <jroebuck@spotify.com>
2026-03-31 16:20:23 +01:00
Fredrik Adelöw 8a2a81fa1e Merge pull request #33687 from backstage/freben/bump-glob-rollup
Bump glob to v13 and rollup to v4.59+ to fix security vulnerabilities
2026-03-31 16:06:22 +02:00
Fredrik Adelöw 739b655063 Merge pull request #33250 from backstage/renovate/use-sync-external-store-1.x
chore(deps): update dependency @types/use-sync-external-store to v1
2026-03-31 15:58:16 +02:00
Fredrik Adelöw ad19cb040f Merge pull request #33629 from jonkoops/auditor-zod-v4-refactor
refactor(backend-defaults): migrate internal Zod usage from v3 to v4
2026-03-31 15:52:18 +02:00
Fredrik Adelöw b6c0ef5d5d Add windowsPathsNoEscape to glob calls that may receive backslash paths
Glob v13 treats backslashes as escape characters by default, unlike v7
which treated them as path separators on Windows. This broke Windows CI
where path.join/resolve produce backslash paths.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Fredrik Adelöw <freben@spotify.com>
2026-03-31 15:20:56 +02:00
Vincenzo Scamporlino 3964163dce Fix export path in frontend plugin module template
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
2026-03-31 14:36:58 +02:00
Vincenzo Scamporlino e38bcefb99 Fix template name collision between new and legacy frontend plugin templates
The legacy frontend plugin template had the same name (`frontend-plugin`) as
the new frontend plugin template, causing a conflict error when both were shown
(e.g. when the frontend system could not be auto-detected). Rename the legacy
template to `frontend-plugin-legacy` so both can coexist.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
2026-03-31 14:36:53 +02:00