v0.13.0-rc.1
This release adds further fixes to the new evaluator, and speeds up the CLI when there are many inputs.
Changes which may break some users are marked below with: ⚠️
Evaluator
The new evaluator is improved to fix more regressions which led to incorrect errors. Since the last alpha release, two newly added projects to Unity now succeed with evalv3, and we have resolved eight issues reported on GitHub.
We also fix a bug where anonymous CUE files, such as those without a package clause, did not properly report unused import errors.
cmd/cue
The cue help filetypes logic, written itself in CUE, no longer requires using the evaluator to parse CLI arguments or load CUE packages. This results in significant speed-ups when using the CLI with many inputs.
Fix a bug where some errors shown to the user did not use relative paths to CUE files or directories as expected.
Go API
⚠️ CUE_EXPERIMENT=decodeint64 can no longer be disabled as we consider the experiment finished, having been introduced in CUE v0.11.0.
Fix a recent regression where using os.Getwd alongside the ./cmd/cue/cmd API had stopped working as it did before.
Encodings
cue exp gengotypes now allows control over how to generate optional CUE fields via e.g. @(,optional=nullable), where the default now is not to use pointers.
⚠️ cue exp gengotypes tweaks how it parses @(,type=) options to support composite types such as slices and maps. Note that this means package paths with slashes must be quoted now.
All changes
106 changes since v0.13.0-alpha.4by area
cmd16
cmd/cueadd CUE_EXPERIMENT=cmdreferencepkgcmd/cueadd testscript showing input unmarshal behavior withcue cmdcmd/cuedocument that embedding is limited to files in the same modulecmd/cueupdate which experiments are on by defaultcmd/cuetest the "found packages $X and $Y in $DIR" error messagecmd/cuedon't use os.Getwd at init timecmd/cuemove CUE_DEBUG_PARSER_TRACE to CUE_DEBUG=parsertracecmd/cueadd testscript for CUE_DEBUG_PARSER_TRACEcmd/cueadd more gengotypes test cases for optional=nillablecmd/cueadd a testscript for --inject-varscmd/cueadd testscript to ensure we report unused importscmd/cuemention vet-c's three behaviourscmd/cuefix up xml+koala testscript to actually test stdincmd/cuetest that gengotypes keeps top-level definition docscmd/cueadd gengotypes test cases for the optional attribute optioncmd/cueadd CUE_BENCH to benchmark CLI invocations with Go allocs
cue16
cue/testdataadd test cases for #3924cue/loadmake MultiplePackageError support relative dir pathscue/testdataadd regression test for issue 2310cue/errorsuse slices.CompactFunc to deduplicate errorscue/errorsprint relative positions when used as arguments toocue/testdataadd regression tests for issue 2337cue/testdataadd a regression test for issue 2241cue/testdataadd a regression test for issue 2229cue/testdataadd regression test for issue 1867cue/testdataremove resolve/002.txtarcue/testdataadd regression test for issue 2209cue/testdataadd a regression test for issue 1640cue/testdataadd a regression test for issue 2526cuefix two godoc linkscue/formatadd test case for formatting empty and near-empty filescue/ast/astutilrefactor walkVisitor away
encoding14
encoding/jsonschemafix x-kubernetes-group-version-kindencoding/jsonschemarecognize date-time tooencoding/jsonschemaupdate format supportencoding/jsonschemaadd numeric format to CRD testencoding/jsonschemaavoid adding unnecessary ellipsesencoding/jsonschemaimplement x-kubernetes-group-version-kindencoding/jsonschemaadd VersionKubernetesAPIencoding/jsonschemaCRD metadata field is not requiredencoding/jsonschemaCRDs always define resourcesencoding/jsonschemaadd metadata field to CRD test caseencoding/openapiadd regression test for issue 1643encoding/xml/koalaupdate koala header commentsencoding/jsonschemafix the tests on Go tipencoding/jsonschemaadd OpenOnlyWhenExplicit option
internal53
internal/core/adtfix disjunction state managementinternal/core/adtadd tests for Issue 3925 and 3905internal/core/adtavoid finalizing too earlyinternal/core/adtadd tests for issue 3919internal/filetypesremove version from TODOinternal/core/adtfix some embedding issues with closednessinternal/core/adtadd tests for 3921internal/encoding/gotypeshandle cyclic types out of the boxinternal/core/adtcarry over enclosing scopeinternal/core/adtadd tests for 3920internal/core/adtupdate environment for disjunctionsinternal/core/adtadd tests for issue 3891internal/golangorgxcuelsp: load cueinternal/golangorgxcuelsp: remove Go-specific analysisinternal/core/adthandle vertices properly for comprehensions spanning disjunctionsinternal/core/adtadd tests for issue 3899internal/cueexperimentphase out DecodeInt64internal/encoding/gotypesimplement optional=nillableinternal/encoding/gotypesparse type options as Go expressionsinternal/filetypesremove dependency on CUE evaluatorinternal/filetypesgenerate FromFileinternal/filetypesgenerate toFile implementationinternal/filetypes/internal/genfuncCUE to Go translationinternal/filetypes/internal/genfuncCUE expression simplificationinternal/filetypes/internal/genstructnew packageinternal/filetypesremove special casesinternal/core/adtallow stack-based unrolling of blockinginternal/core/adtadd tests for 3899internal/ci/goreleaseradjust after evalv3 fix for #3908internal/core/adtfix default handlinginternal/core/runtimevalidate imports in package-less files toointernal/cuetxtarsupport matrix name skips like #skip-v2internal/golangorgxstub out gcimporterinternal/golangorgxdrop testenv APIs we won't needinternal/golangorgxremove the goroot packageinternal/golangorgxremove the aliases packageinternal/golangorgxremove refactor/inlineinternal/golangorgxdrop util/slices in favor of slicesinternal/encoding/gotypesdon't drop docs for top-level definitionsinternal/filetypesstrict separation of tags vs subsidiary tags logicinternal/filetypesregularize Defaultinternal/filetypesclarify FromFileinternal/filetypesrefactor parseType to parseScopeinternal/filetypesadd evaluator mutexinternal/filetypesconsolidationinternal/encoding/gotypesanalyze all CUE definitions firstinternal/encoding/gotypescontrol optional types via attributesinternal/encoding/gotypeshandle quoted CUE fields correctlyinternal/core/adtfix expression comments in SimplifyBoundsinternal/core/adtavoid apd.Decimal errors in SimplifyBoundsinternal/core/adtreuse a slice to make copies of the required reqSetsinternal/ciflip to using the official curated cue.dev schemasinternal/golangorgxcuelsp: view definitions for cue
pkg3
pkgmake $id in tasks a reference to a hidden fieldpkg/listadd a regression test for issue 3416pkg/listadd regression test for issue 2594
Other4
- Revert "internal/core/adt: carry over enclosing scope"
allcue fmttools/flowmove CUE_DEBUG_TOOLS_FLOW=1 to CUE_DEBUG=toolsflow=1allclean up a number of txtar test skips
Downloads
Every file this release published on GitHub, with its SHA-256. Most people install CUE as Installing CUE describes, which also shows how to check a download.
Archives
| Platform | File and SHA-256 |
|---|---|
| macOS, Intel | cue_b2bcb9d44df559556d38e07a9ded13a10c58ada3bac80acd2fedbfe295f92287 |
| macOS, Apple silicon | cue_6d6889605f2f566a0f576eae5dc6402bda273759154d017272f1c9093da0ec9c |
| Linux, x86-64 | cue_84a0546e04abb3b17424a56e7e99119b20db0cfee7dcf76d0150d66ed9d0ed94 |
| Linux, Arm64 | cue_847c5e0f9f17827036f638dfe41d2769025cfa69e0fec2cab10c6362d00da052 |
| Windows, x86-64 | cue_23095053b52ca6193229188c927a81556dd2d0f2f709eafc0921be3be8c1f683 |
| Windows, Arm64 | cue_d113898125558c8ce13d87d95510e5b960eea952f24fbd8080cd08b8dd81d141 |
SHA-256 checksums for all of these: checksums.txt