Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use cue to vet another cue file #2210

Closed
sahroshan opened this issue Jan 11, 2023 · 1 comment
Closed

use cue to vet another cue file #2210

sahroshan opened this issue Jan 11, 2023 · 1 comment
Labels
NeedsInvestigation Triage Requires triage/attention

Comments

@sahroshan
Copy link

sahroshan commented Jan 11, 2023

Hi,
I am trying to validate a cue file with another cue file. Is it possible to validate cue with another cue?

What version of CUE are you using (cue version)?

➜  cue version
cue version v0.5.0-beta.2

       -compiler gc
        -ldflags -s -w
     CGO_ENABLED 0
          GOARCH amd64
            GOOS darwin
         GOAMD64 v1


Does this issue reproduce with the latest release?

yes

What did you do?

  1. create a schema file
-- schema.cue
close({
	foo: bar: string
})
  1. create another cue file
-- another.cue
foo: {
	bar: "passed down"
}
extra: "this extra field not defined in schema"
  1. run vet command cue vet another.cue schema.cue

What did you expect to see?

Error for field extra in another.cue

What did you see instead?

cue vet another.cue schema.cue does not raise any error. And exit status is 0.

@sahroshan sahroshan added NeedsInvestigation Triage Requires triage/attention labels Jan 11, 2023
@sahroshan sahroshan changed the title vet does not report extra fields at root level vet does not report extra fields at root level in another cue file Jan 11, 2023
@sahroshan sahroshan changed the title vet does not report extra fields at root level in another cue file use cue to vet another cue file Jan 11, 2023
@myitcv myitcv added the zGarden label Jun 13, 2023
@mvdan
Copy link
Member

mvdan commented Jun 14, 2023

Duplicate of #2214, which was converted from your discussion with the same request.

@mvdan mvdan closed this as not planned Won't fix, can't repro, duplicate, stale Jun 14, 2023
@mvdan mvdan removed the zGarden label Jun 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsInvestigation Triage Requires triage/attention
Projects
None yet
Development

No branches or pull requests

3 participants