Skip to content

Commit

Permalink
chore: Remove preempted deprecation warnings (#1655)
Browse files Browse the repository at this point in the history
Signed-off-by: Evans Mungai <[email protected]>
  • Loading branch information
banjoh authored Oct 21, 2024
1 parent 289102f commit 9c24ab6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ require (
github.com/vmware-tanzu/velero v1.14.1
go.opentelemetry.io/otel v1.31.0
go.opentelemetry.io/otel/sdk v1.31.0
go.opentelemetry.io/otel/trace v1.31.0
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8
golang.org/x/mod v0.21.0
golang.org/x/sync v0.8.0
Expand Down Expand Up @@ -123,7 +124,6 @@ require (
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.53.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0 // indirect
go.opentelemetry.io/otel/metric v1.31.0 // indirect
go.opentelemetry.io/otel/trace v1.31.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/tools v0.22.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157 // indirect
Expand Down
10 changes: 5 additions & 5 deletions pkg/supportbundle/load.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func GetSupportBundleFromURI(bundleURI string) (*troubleshootv1beta2.SupportBund
}

// ParseSupportBundle parses a support bundle from a byte array into a SupportBundle object
// Deprecated: use loader.LoadSpecs instead
// We will deprecate this in favour of use loader.LoadSpecs once the new API is stable
func ParseSupportBundle(doc []byte, followURI bool) (*troubleshootv1beta2.SupportBundle, error) {
doc, err := docrewrite.ConvertToV1Beta2(doc)
if err != nil {
Expand Down Expand Up @@ -102,13 +102,13 @@ func ParseSupportBundle(doc []byte, followURI bool) (*troubleshootv1beta2.Suppor
}

// ParseSupportBundle parses a support bundle from a byte array into a SupportBundle object
// Deprecated: use loader.LoadSpecs instead
// We will deprecate this in favour of use loader.LoadSpecs once the new API is stable
func ParseSupportBundleFromDoc(doc []byte) (*troubleshootv1beta2.SupportBundle, error) {
return ParseSupportBundle(doc, true)
}

// GetRedactorFromURI parses a redactor from a URI into a Redactor object
// Deprecated: use loader.LoadSpecs instead
// We will deprecate this in favour of use loader.LoadSpecs once the new API is stable
func GetRedactorFromURI(redactorURI string) (*troubleshootv1beta2.Redactor, error) {
redactorContent, err := LoadRedactorSpec(redactorURI)
if err != nil {
Expand All @@ -127,7 +127,7 @@ func GetRedactorFromURI(redactorURI string) (*troubleshootv1beta2.Redactor, erro
}

// GetRedactorsFromURIs parses redactors from a URIs Redactor objects
// Deprecated: use loader.LoadSpecs instead
// We will deprecate this in favour of use loader.LoadSpecs once the new API is stable
func GetRedactorsFromURIs(redactorURIs []string) ([]*troubleshootv1beta2.Redact, error) {
redactors := []*troubleshootv1beta2.Redact{}
for _, redactor := range redactorURIs {
Expand Down Expand Up @@ -263,7 +263,7 @@ func loadSpecFromURL(arg string) ([]byte, error) {
}

// ParseRedactorsFromDocs parses a slice of YAML docs and returns a slice of Redactors
// Deprecated: use loader.LoadSpecs instead
// We will deprecate this in favour of use loader.LoadSpecs once the new API is stable
func ParseRedactorsFromDocs(docs []string) ([]*troubleshootv1beta2.Redact, error) {
var redactors []*troubleshootv1beta2.Redact

Expand Down

0 comments on commit 9c24ab6

Please sign in to comment.