---
title: "github.com/prometheus/client_golang v0.12.1 Breaking Changes"
description: "What each github.com/prometheus/client_golang release removed, renamed or changed: 39 breaking changes in 1 version on Go modules, each with its source."
canonical_url: https://since.dev/packages/go/github.com/prometheus/client_golang
last_updated: 2026-12-04
---

# github.com/prometheus/client_golang breaking changes

github.com/prometheus/client_golang v0.12.1 (January 29, 2022) is its newest release with breaking changes, 39 of them. The first: Removed github.com/prometheus/client_golang/api.DoGetFallback. Every breaking API change we have recorded in github.com/prometheus/client_golang on Go modules: 39 breaking changes in 1 version. Below, its one version with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `v1.25.0`, released October 8, 2026. 

Packages on Go modules run on Go. [Go end of life dates](https://since.dev/calendar/go.md).

## github.com/prometheus/client_golang v0.12.1 breaking changes

github.com/prometheus/client_golang v0.12.1, released January 29, 2022: 39 breaking changes.

- **Removed** `github.com/prometheus/client_golang/api.DoGetFallback`  

github.com/prometheus/client_golang/api.DoGetFallback was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/api.Error`  

github.com/prometheus/client_golang/api.Error was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/api.ErrorAPI`  

github.com/prometheus/client_golang/api.ErrorAPI was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/api.NewErrorAPI`  

github.com/prometheus/client_golang/api.NewErrorAPI was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/api/prometheus/v1.Error.Err`  

github.com/prometheus/client_golang/api/prometheus/v1.Error.Err was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/api/prometheus/v1.Error.Warnings`  

github.com/prometheus/client_golang/api/prometheus/v1.Error.Warnings was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus.Handler`  

github.com/prometheus/client_golang/prometheus.Handler was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus.InstrumentHandler`  

github.com/prometheus/client_golang/prometheus.InstrumentHandler was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus.InstrumentHandlerFunc`  

github.com/prometheus/client_golang/prometheus.InstrumentHandlerFunc was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus.InstrumentHandlerFuncWithOpts`  

github.com/prometheus/client_golang/prometheus.InstrumentHandlerFuncWithOpts was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus.InstrumentHandlerWithOpts`  

github.com/prometheus/client_golang/prometheus.InstrumentHandlerWithOpts was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus.UninstrumentedHandler`  

Use promhttp.HandlerFor instead. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus/push.AddCollectors`  

github.com/prometheus/client_golang/prometheus/push.AddCollectors was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus/push.AddFromGatherer`  

github.com/prometheus/client_golang/prometheus/push.AddFromGatherer was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus/push.Collectors`  

github.com/prometheus/client_golang/prometheus/push.Collectors was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus/push.FromGatherer`  

github.com/prometheus/client_golang/prometheus/push.FromGatherer was removed in github.com/prometheus/client_golang v0.12.1 [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Removed** `github.com/prometheus/client_golang/prometheus/push.HostnameGroupingKey`  

Use https://github.com/prometheus/node_exporter instead. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api.Client.Do`  

Was func Do(context.Context, \*http.Request) (\*http.Response, \[\]byte, Error); now func Do(context.Context, \*http.Request) (\*http.Response, \[\]byte, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.AlertManagers`  

Was func AlertManagers(context.Context) (AlertManagersResult, api.Error); now func AlertManagers(context.Context) (AlertManagersResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Alerts`  

Was func Alerts(context.Context) (AlertsResult, api.Error); now func Alerts(context.Context) (AlertsResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.CleanTombstones`  

Was func CleanTombstones(context.Context) api.Error; now func CleanTombstones(context.Context) error. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Config`  

Was func Config(context.Context) (ConfigResult, api.Error); now func Config(context.Context) (ConfigResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.DeleteSeries`  

Was func DeleteSeries(context.Context, \[\]string, time.Time, time.Time) api.Error; now func DeleteSeries(context.Context, \[\]string, time.Time, time.Time) error. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Flags`  

Was func Flags(context.Context) (FlagsResult, api.Error); now func Flags(context.Context) (FlagsResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.LabelValues`  

Was func LabelValues(context.Context, string) (model.LabelValues, api.Error); now func LabelValues(context.Context, string, \[\]string, time.Time, time.Time) (model.LabelValues, Warnings, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Query`  

Was func Query(context.Context, string, time.Time) (model.Value, api.Error); now func Query(context.Context, string, time.Time) (model.Value, Warnings, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.QueryRange`  

Was func QueryRange(context.Context, string, Range) (model.Value, api.Error); now func QueryRange(context.Context, string, Range) (model.Value, Warnings, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Rules`  

Was func Rules(context.Context) (RulesResult, api.Error); now func Rules(context.Context) (RulesResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Series`  

Was func Series(context.Context, \[\]string, time.Time, time.Time) (\[\]model.LabelSet, api.Error); now func Series(context.Context, \[\]string, time.Time, time.Time) (\[\]model.LabelSet, Warnings, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Snapshot`  

Was func Snapshot(context.Context, bool) (SnapshotResult, api.Error); now func Snapshot(context.Context, bool) (SnapshotResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.Targets`  

Was func Targets(context.Context) (TargetsResult, api.Error); now func Targets(context.Context) (TargetsResult, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/api/prometheus/v1.API.TargetsMetadata`  

Was func TargetsMetadata(context.Context, string, string, string) (\[\]MetricMetadata, api.Error); now func TargetsMetadata(context.Context, string, string, string) (\[\]MetricMetadata, error). [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentHandlerCounter`  

Was func InstrumentHandlerCounter(\*prometheus.CounterVec, http.Handler) http.HandlerFunc; now func InstrumentHandlerCounter(\*prometheus.CounterVec, http.Handler, ...Option) http.HandlerFunc. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentHandlerDuration`  

Was func InstrumentHandlerDuration(prometheus.ObserverVec, http.Handler) http.HandlerFunc; now func InstrumentHandlerDuration(prometheus.ObserverVec, http.Handler, ...Option) http.HandlerFunc. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentHandlerRequestSize`  

Was func InstrumentHandlerRequestSize(prometheus.ObserverVec, http.Handler) http.HandlerFunc; now func InstrumentHandlerRequestSize(prometheus.ObserverVec, http.Handler, ...Option) http.HandlerFunc. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentHandlerResponseSize`  

Was func InstrumentHandlerResponseSize(prometheus.ObserverVec, http.Handler) http.Handler; now func InstrumentHandlerResponseSize(prometheus.ObserverVec, http.Handler, ...Option) http.Handler. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentHandlerTimeToWriteHeader`  

Was func InstrumentHandlerTimeToWriteHeader(prometheus.ObserverVec, http.Handler) http.HandlerFunc; now func InstrumentHandlerTimeToWriteHeader(prometheus.ObserverVec, http.Handler, ...Option) http.HandlerFunc. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentRoundTripperCounter`  

Was func InstrumentRoundTripperCounter(\*prometheus.CounterVec, http.RoundTripper) RoundTripperFunc; now func InstrumentRoundTripperCounter(\*prometheus.CounterVec, http.RoundTripper, ...Option) RoundTripperFunc. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)
- **Signature changed** `github.com/prometheus/client_golang/prometheus/promhttp.InstrumentRoundTripperDuration`  

Was func InstrumentRoundTripperDuration(prometheus.ObserverVec, http.RoundTripper) RoundTripperFunc; now func InstrumentRoundTripperDuration(prometheus.ObserverVec, http.RoundTripper, ...Option) RoundTripperFunc. [pkg.go.dev](https://pkg.go.dev/github.com/prometheus/client%5Fgolang@v0.12.1)

## Related packages

- [github.com/prometheus/client_model](https://since.dev/packages/go/github.com/prometheus/client%5Fmodel.md)
- [github.com/prometheus/common](https://since.dev/packages/go/github.com/prometheus/common.md)
- [github.com/prometheus/procfs](https://since.dev/packages/go/github.com/prometheus/procfs.md)

## Check your code

These are the changes. To see which of them reach your code, [scan a public repository](https://since.dev/scan.md), or have your coding agent call `check_code` with your manifest or lockfile over [MCP](https://since.dev/docs.md#mcp). [The API](https://since.dev/docs.md#api) reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous maintenance.

Scan a public repository now, or give your agent one line.

[Scan a repository](https://since.dev/scan.md). Any public GitHub repository. No sign-in.

### Tell your agent what changed since it was trained.

`claude mcp add --transport http since https://api.since.dev/mcp`

[Get an API key](https://app.since.dev/login?mode=signup)

Codex, Cursor and any MCP client use https://api.since.dev/mcp.

---

Every page on this site as Markdown: https://since.dev/sitemap.md. For agents: https://since.dev/llms.txt.
