Skip to content

fix(saas-ui): connect providers from the host catalog - #1240

Merged
antoinetoussaint-byte merged 3 commits into
mainfrom
issue-1238-the-datasources-panel-offers-one-provider-by-name
Oct 23, 2026
Merged

antoinetoussaint-byte merged 3 commits into
mainfrom
issue-1238-the-datasources-panel-offers-one-provider-by-name

Conversation

@antoinetoussaint-byte

@antoinetoussaint-byte antoinetoussaint-byte commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

The shared datasource panel now offers the providers returned by the host catalog. Removing a provider removes its connect form; refusing one leaves it visible with the catalog's exact reason. Provider field keys, labels, help and required flags come from its descriptor, and the adapter uses the SDK's message descriptors to encode each AddSource config oneof.

Fixes #1238. This is the self-contained frontend delivery, independent of #1235's provider implementation; neither overlapping branch was modified.

Classification: fix at the owning SaaS UI client and panel. Reuses DatasourceService.GetDatasourceCatalog, AddSource, generated SDK descriptors, existing transport/auth bindings, layout primitives, loading timing, collection reads and installation completion. It adds no provider-field table, backend registry, admission rule or generated contract. Credentials are typed transient call inputs, cleared before submission and excluded from mutation caches and error rendering. Existing exports remain compatible; both new client methods are optional and no panel prop is required.

The follow-up removes the provider enum check from the catalog adapter. Installation support requires the descriptor's credential mode and matching SDK setup operations for its connector key. Catalog admission also gates installation-return redemption, not just rendering: a removed or refused provider cannot be redeemed or offered through that path. Tests cover removal while the return form is open as well as removal/refusal before it mounts.

Merged main's #1239 validation-library migration, preserving its schema changes and combining both sets of registry consumer assertions. UI packages are co-versioned at 0.13.1; the host derives its shared version from the package.

The Immutable module package failure was TestEveryWorkspaceGroupReadIsDeclared, not a version assertion. Its literal-accessor scan interpreted the DOM form helper's read("secret") and read("collection") as workspace configuration reads. Renaming that helper to fieldValue makes its actual responsibility explicit. No workspace read was removed, no dependency was fabricated, and no gate, exclusion or baseline was changed.

Documentation: packages/saas-ui/README.md describes catalog behavior, compatibility, credential handling, installation-return admission and wire-schema limits; ui-inventory.json registers the component and its admitting/refusing preview stories (both under module/services/frontend/code/).

Validation on the updated branch:

  • codefly ci run --changed-file module/services/frontend/code/packages/saas-ui/src/datasources/catalog.ts --phase lint,compile,test: all three phases passed, including all 4,912 frontend tests and architecture/token/preview guards.
  • GOWORK=off go test ./... in module/tools, package validation, declared generators without drift, and declared conformance suites passed. The Python suite used its declared test dependencies in an isolated environment. Two canonical archive builds produced identical tar, checksum and metadata files.
  • npm run test:published-plugin-contract passed, including the fresh registry consumer's declarations, exports, rendering, styles, shared plugin context, schema validation, both unchanged panel-prop shapes, and a legacy injected client with neither new method.
  • Naming (including manual review of added strings), boundaries, workspace integrity and kit-version checks passed. Author and committer use the requested no-reply identity.

Limits: no live external-provider connection or browser visual qualification was run. The separate older test-published-ui.mjs still fails during fresh installation because unconstrained peers select @hookform/resolvers@6 with conflicting optional effect dependencies; the gate’s registry harness uses its existing lockfile-derived resolution and passes. This PR does not make a refused host provider admissible; additional wire fields require a compatible SDK and are never silently dropped. No release or publication was performed. Landing uses the merge queue.

…urces-panel-offers-one-provider-by-name

# Conflicts:
#	module/services/frontend/code/package-lock.json
#	module/services/frontend/code/packages/codefly-ui/package.json
#	module/services/frontend/code/packages/saas-ui/package.json
#	module/services/frontend/code/scripts/test-registry-ui.mjs
@antoinetoussaint-byte
antoinetoussaint-byte added this pull request to the merge queue Oct 23, 2026
Merged via the queue into main with commit 6162e84 Oct 23, 2026
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The datasources panel offers one provider by name and never reads the catalog, so a provider the host admits cannot be connected from any surface

1 participant