#Is there a way to access constants
1 messages · Page 1 of 1 (latest)
It would appear this isn't allowed?
I have a docker module that uses a hadolint module I wrote, and as part of that the hadolint has some constants for types. The Lint function on the docker module has this definition:
`func (d *Docker) Lint(
ctx context.Context,
// The failure threshold
// +optional
threshold dagger.HadolintFailureThresholdKind,`
However, I end up getting this error when I try to use the module:
Error: failed to generate code: failed to run codegen: failed to load dependencies as modules: failed to load module dependencies: select: failed to add object to module "docker": failed to validate type def: object "Docker" function "Lint" arg "threshold" cannot reference external type from dependency module "hadolint"
Which implies I can't reference a constant from one module defined in another even if that module is installed as a dep