Skip to content

Commit 0b6a1c2

Browse files
committed
Deprecate obsolete errors pkg
The /errors package has its origin in when capi providers were machineActuators that needed to vendor core capi to function. There's no usage recommendations and value is questionable since we moved to CRDs and conditions for interoperability between core and providers. I think we should deprecate it and if there's any use case relying on it we should support it via conditions
1 parent 1e6896e commit 0b6a1c2

File tree

7 files changed

+8
-0
lines changed

7 files changed

+8
-0
lines changed

docs/book/src/developer/providers/migrations/v1.7-to-v1.8.md

+1
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,4 @@ maintainers of providers and consumers of our Go API.
2727
- It's highly recommended to move to a new setup-envtest version that uses envtest binaries from controller-tools releases
2828
instead of the deprecated GCS bucket. More details can be found in [#10569](https://github.com/kubernetes-sigs/cluster-api/pull/10569)
2929
and [kubernetes-sigs/controller-runtime#2811](https://github.com/kubernetes-sigs/controller-runtime/pull/2811).
30+
- The Errors package [has been deprecated in v1.8](https://github.com/kubernetes-sigs/cluster-api/issues/10784). It's recommented to remove any usage of the currently exported variables.

errors/clusters.go

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17+
// Deprecated: This package will be removed in one of the next releases.
1718
package errors
1819

1920
import (

errors/consts.go

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17+
// Deprecated: This package will be removed in one of the next releases.
1718
package errors
1819

1920
// MachineStatusError defines errors states for Machine objects.

errors/doc.go

+2
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,6 @@ limitations under the License.
1515
*/
1616

1717
// Package errors makes a set of error message handlers available for use by Cluster API Providers.
18+
//
19+
// Deprecated: This package will be removed in one of the next releases.
1820
package errors

errors/kubeadmcontrolplane.go

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17+
// Deprecated: This package will be removed in one of the next releases.
1718
package errors
1819

1920
// KubeadmControlPlaneError is a more descriptive kind of error that represents an error condition that

errors/machines.go

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17+
// Deprecated: This package will be removed in one of the next releases.
1718
package errors
1819

1920
import (

errors/pointer.go

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17+
// Deprecated: This package will be removed in one of the next releases.
1718
package errors
1819

1920
// MachineStatusErrorPtr converts a MachineStatusError to a pointer.

0 commit comments

Comments
 (0)