Repository navigation
fix(platform): collect a connector's declared config fields - #2878
Merged
Merged
Conversation
The add dialog never rendered a connector's configFields, so required hosts (e.g. imap-smtp) could not be supplied and createCredential refused with "needs <label>". Return configFields from the catalog, collect them in a typed extra module, gate submit on completeness, and round-trip config on edit so a save cannot wipe hosts.
Israeltheminer
force-pushed
the
fix/credential-config-fields
branch
from
August 2, 2026 18:40
e1d8e2d to
0c0a4f4
Compare
Contributor
Author
|
Rebased onto current |
4 tasks
That toggle ships in the stacked imap-smtp PR; asserting it here fails UI because the form does not render the switch yet.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adding an IMAP / SMTP mailbox credential fails with
— naming a field the form never offers.
createCredentialvalidates the submittedconfig against the connector's declared
configFieldsand refuses a missingrequired one, but the add dialog installed
noExtras(), so it renders none ofthem. Any connector declaring a required config field is unreachable through the
UI;
imap-smtprequires bothimapHostandsmtpHost.The backend half already existed —
normalizeConfigcoerces types, honours enums,applies defaults and rejects undeclared keys. This wires the form to it.
Changes
listConnectorsreturnsconfigFields. The settings catalog dropped them,so the UI could not have known what to ask for.
declaration:
boolean→ switch,string+enum→ select over exactly thosevalues, otherwise an input. Numbers stay strings in form state and are coerced
by the server. A declared default renders as a placeholder, not a prefilled value.
''.Completeness and edit round-trip
CredentialExtraModulegains optional vendor-awareisComplete; both dialogs gate on it.listCredentialsreturnsconfigso edit cannot wipe hosts/ports.Follow-ups
Note
Field labels come from the shipped connector YAML rather than the locale catalogs.