Description
/kind bug
Which area this bug is related to?
/area api
Bug Summary
Describe the bug:
When consumers pick up the latest api package that's under development, they typically run a go get
command to update their go.mod file but the version that gets generated is v2.0.0-<timestamp of last commit>
. This looks out of date because it implies changes to the v2.0.0 spec when v2.1.0 is our latest. This can cause confusion since the underlying code is actually the latest.
Expected behavior
We should ensure the version reflects the latest version that's under development
Additional context
v2.0.0 is being generated because the main branch does not have any tags (these are associated with our release branches), so go get
generates a pseudo version that's based on the version specified in the module path (v2).
Any workaround?
Suggestion on how to fix the bug
Based on how pseudo-versions work, we may be able to correct this by adding pre-release tags to the api repo: https://golang.org/ref/mod#pseudo-versions