Skip to content

Commit

Permalink
[chore][receiver/podman] Fix lint on Windows (open-telemetry#30313)
Browse files Browse the repository at this point in the history
**Description:**
Fixing lint issues when GOOS=windows. This is in preparation to include lint with GOOS=windows as part of CI .
  • Loading branch information
pjanotti committed Jan 5, 2024
1 parent dec1b96 commit fb26113
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 deletions.
7 changes: 1 addition & 6 deletions receiver/podmanreceiver/factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,5 @@ func createMetricsReceiver(
consumer consumer.Metrics,
) (receiver.Metrics, error) {
podmanConfig := config.(*Config)
dsr, err := newMetricsReceiver(ctx, params, podmanConfig, consumer, nil)
if err != nil {
return nil, err
}

return dsr, nil
return newMetricsReceiver(ctx, params, podmanConfig, consumer, nil)
}
8 changes: 4 additions & 4 deletions receiver/podmanreceiver/receiver_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ import (

func newMetricsReceiver(
_ context.Context,
settings receiver.CreateSettings,
config *Config,
nextConsumer consumer.Metrics,
clientFactory any,
_ receiver.CreateSettings,
_ *Config,
_ consumer.Metrics,
_ any,
) (receiver.Metrics, error) {
return nil, fmt.Errorf("podman receiver is not supported on windows")
}

0 comments on commit fb26113

Please sign in to comment.