VFX-D-1205¶
Title¶
UndeclaredDependencyType
Explanation¶
A step's type needs infrastructure of a particular kind — mq-expect.kafka needs a kafka
dependency, db-assert.postgres needs a postgres one — and environment.dependencies declares no
entry of that kind.
Note the distinction the finding turns on: environment.dependencies is an object keyed by your
logical name (orders-db), and each entry's type field is the kind (postgres). This rule
checks the kinds, not the names; a dangling target name is VFX-D-1202.
The finding is suppressed when the step's target names a declared service. The composed
schema's own target description says a customer-supplied service is a legitimate provider of the
same infrastructure ("a customer-supplied broker under its own entrypoint/config"), so demanding a
managed dependency there would be wrong.
Two step types need a kind whose name differs from the provider in their type: mail-expect.smtp
needs a mailpit dependency (the provider names the protocol) and storage-assert.s3 needs a
minio one (the provider names the API).
Reported as a warning in the semanticDiagnostics channel.
Common causes¶
- A step added without the matching
environment.dependenciesentry. - A dependency declared with the wrong
typevalue — matching is case-sensitive, soPostgresis notpostgres. - A suite that assumes an externally-provided broker or database but does not declare it as a service either.
mail-expect.smtporstorage-assert.s3steps written against asmtpors3dependency kind, neither of which the schema'sdependency.typeenum defines.
Fixes¶
- Add the dependency: an entry under
environment.dependencieswhosetypeis the kind the message names. - Or declare the infrastructure as a service under
environment.servicesand point the step'stargetat it. - Call
describe_step_typeon the step's type to see its full field contract, andget_schemawithsection: "environment"for the dependency shape and the thirteen kinds the schema accepts.