---
title: "github.com/spf13/cobra v1.10.0 Breaking Changes"
description: "What each github.com/spf13/cobra release removed, renamed or changed: 10 breaking changes in 3 versions on Go modules, each with its source."
canonical_url: https://since.dev/packages/go/github.com/spf13/cobra
last_updated: 2026-12-04
---

# github.com/spf13/cobra breaking changes

github.com/spf13/cobra v1.10.0 (September 1, 2025) is its newest release with breaking changes. The first: Signature changed github.com/spf13/cobra.FParseErrWhitelist. Every breaking API change we have recorded in github.com/spf13/cobra on Go modules: 10 breaking changes in 3 versions. Below, its 3 versions with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `v1.10.2`, released December 3, 2025. 

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

- From [v1.9.0](#v-v1-9-0) to [v1.10.0](#v-v1-10-0): 2 breaking changes in 2 versions.

## github.com/spf13/cobra v1.10.0 breaking changes

github.com/spf13/cobra v1.10.0, released September 1, 2025: 1 breaking change.

- **Signature changed** `github.com/spf13/cobra.FParseErrWhitelist`  

Was type FParseErrWhitelist flag.ParseErrorsWhitelist; now type FParseErrWhitelist flag.ParseErrorsAllowlist. [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.10.0)

## github.com/spf13/cobra v1.9.1 breaking changes

github.com/spf13/cobra v1.9.1, released February 16, 2025: 1 breaking change.

- **Signature changed** `github.com/spf13/cobra.CompletionFunc`  

Was type CompletionFunc func(\*Command, \[\]string, string) (\[\]Completion, ShellCompDirective); now type CompletionFunc = func(\*Command, \[\]string, string) (\[\]Completion, ShellCompDirective). [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.1)

## github.com/spf13/cobra v1.9.0 breaking changes

github.com/spf13/cobra v1.9.0, released February 15, 2025: 8 breaking changes.

- **Signature changed** `github.com/spf13/cobra.AppendActiveHelp`  

Was func AppendActiveHelp(\[\]string, string) \[\]string; now func AppendActiveHelp(\[\]Completion, string) \[\]Completion. [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.Command.GetFlagCompletionFunc`  

Was func GetFlagCompletionFunc(string) (func(\*Command, \[\]string, string) (\[\]string, ShellCompDirective), bool); now func GetFlagCompletionFunc(string) (CompletionFunc, bool). [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.Command.InitDefaultCompletionCmd`  

Was func InitDefaultCompletionCmd(); now func InitDefaultCompletionCmd(...string). [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.Command.RegisterFlagCompletionFunc`  

Was func RegisterFlagCompletionFunc(string, func(\*Command, \[\]string, string) (\[\]string, ShellCompDirective)) error; now func RegisterFlagCompletionFunc(string, CompletionFunc) error. [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.Command.ValidArgs`  

Was ValidArgs \[\]string; now ValidArgs \[\]Completion. [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.Command.ValidArgsFunction`  

Was ValidArgsFunction func(\*Command, \[\]string, string) (\[\]string, ShellCompDirective); now ValidArgsFunction CompletionFunc. [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.FixedCompletions`  

Was func FixedCompletions(\[\]string, ShellCompDirective) func(\*Command, \[\]string, string) (\[\]string, ShellCompDirective); now func FixedCompletions(\[\]Completion, ShellCompDirective) CompletionFunc. [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)
- **Signature changed** `github.com/spf13/cobra.NoFileCompletions`  

Was func NoFileCompletions(\*Command, \[\]string, string) (\[\]string, ShellCompDirective); now func NoFileCompletions(\*Command, \[\]string, string) (\[\]Completion, ShellCompDirective). [pkg.go.dev](https://pkg.go.dev/github.com/spf13/cobra@v1.9.0)

## 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.
