Skip to content

Operator SDK doesn't support v char in version, claiming it's not semantic #5342

@cardil

Description

@cardil

Bug Report

What did you do?

Running make bundle the Operator SDK fails with fatal error.

What did you expect to see?

I expected a bundle should build fine with following as version: v0.2.0-13-ga74dac1

What did you see instead? Under which circumstances?

The following error has been raised:

FATA[0000] invalid command options: v0.2.0-13-ga74dac1 is not a valid semantic version: Invalid character(s) found in major number "v0"

Environment

Operator type:

/language go

Kubernetes cluster type:

Minikube v1.23.2

$ operator-sdk version
operator-sdk version: "v1.14.0", commit: "78f08b4852faf344ad3ef457c54f86087aaa0a0a", kubernetes version: "1.21", go version: "go1.16.9", GOOS: "linux", GOARCH: "amd64"

$ go version
go version go1.16 linux/amd64

$ kubectl version
Client Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.3", GitCommit:"c92036820499fedefec0f847e2054d824aea6cd1", GitTreeState:"clean", BuildDate:"2021-10-27T18:41:28Z", GoVersion:"go1.16.9", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.2", GitCommit:"8b5a19147530eaac9476b0ab82980b4088bbc1b2", GitTreeState:"clean", BuildDate:"2021-09-15T21:32:41Z", GoVersion:"go1.16.8", Compiler:"gc", Platform:"linux/amd64"}

Possible Solution

I think the Operator SDK should be adjusted to allow using a v char in version string, as that is extremely common. After https://semver.org/#is-v123-a-semantic-version

Metadata

Metadata

Labels

language/goIssue is related to a Go operator projectlifecycle/rottenDenotes an issue or PR that has aged beyond stale and will be auto-closed.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions