diff --git a/cmd/new-plugin/formats.go b/cmd/new-plugin/formats.go index 7b08632..5982874 100644 --- a/cmd/new-plugin/formats.go +++ b/cmd/new-plugin/formats.go @@ -159,16 +159,15 @@ func {{.Lower}}Ingest(t *testing.T, file string) []event.Event { defDir: "plugins/migrationguide/sdkguide", def: `package sdkguide -// {{.Ident}} is {{.Provider}}'s SDK guide to a major release (MIGRATION.md at -// the release tag). +// {{.Ident}} is {{.Provider}}'s SDK guide to each major release (MIGRATION.md +// at the major's first tag), its releases listed from PyPI. // -// ` + todo + `: the PyPI name, the repo, the major release and the calls the -// guide's table names. Say what you checked, with the date. +// ` + todo + `: the PyPI name, the repo and the calls the guide's table +// names. Say what you checked, with the date. var {{.Ident}} = Guide{ API: "{{.ID}}", Package: "{{.PyPI}}", Repo: "TODO-owner/TODO-repo", - Major: 1, Methods: "` + "`TODO.create()`" + `", Symbols: []string{"TODO.create"}, } @@ -216,9 +215,10 @@ const {{.Lower}}Previous = "0.0.0" // {{.Lower}}Ingest is the version pair {{.Lower}}Previous -> the guide's // major over a saved copy of the guide. +// ` + todo + `: the major the saved guide is for. func {{.Lower}}Ingest(t *testing.T, file string) []event.Event { t.Helper() - g := sdkguide.{{.Ident}} + g := sdkguide.{{.Ident}}.At(1) env := kittest.Env(t, kittest.Pages{g.URL(): file}) return kittest.Versions(t, env, Plugin{Guide: g}, plugin.Version{ID: {{.Lower}}Previous, Ref: "v" + {{.Lower}}Previous}, plugin.Version{ID: g.Version(), Ref: "v" + g.Version()}) @@ -233,19 +233,19 @@ func {{.Lower}}Ingest(t *testing.T, file string) []event.Event { defDir: "plugins/migrationguide/members", def: `package members -// {{.Ident}} is {{.Provider}}'s migration guide to a release, with its table -// of removed members. +// {{.Ident}} is {{.Provider}}'s migration guide to each major, with its table +// of removed members, read at the major's first tag. // -// ` + todo + `: the package, how the guide writes the module, the release, -// the repo, the guide's path at the release tag and the heading the table is -// under. Say what you checked, with the date. +// ` + todo + `: the package, how the guide writes the module, the repo, the +// guide's path at a major's tag ({major} for its number, {prev} for the one +// before) and the heading the table is under. Say what you checked, with the +// date. var {{.Ident}} = Guide{ API: "{{.ID}}", Package: "{{.PyPI}}", Module: "{{.Module}}", - Release: "1.0.0", Repo: "TODO-owner/TODO-repo", - Path: "TODO/migration_guide.rst", + Path: "TODO/migration_guide_{major}.rst", Section: "Removed members", } `, @@ -300,13 +300,17 @@ func Test{{.Ident}}DropsANonChange(t *testing.T) { // ` + todo + `: the real release before it. const {{.Lower}}Previous = "0.0.0" -// {{.Lower}}Ingest is the version pair {{.Lower}}Previous -> the guide's -// release over a saved copy of the guide. +// {{.Lower}}Release is the major's first release the saved guide is for. +// ` + todo + `: the real release. +const {{.Lower}}Release = "1.0.0" + +// {{.Lower}}Ingest is the version pair {{.Lower}}Previous -> +// {{.Lower}}Release over a saved copy of the guide. func {{.Lower}}Ingest(t *testing.T, file string) []event.Event { t.Helper() g := members.{{.Ident}} - env := kittest.Env(t, kittest.Pages{g.URL(): file}) - return kittest.Versions(t, env, Plugin{Guide: g}, plugin.Version{ID: {{.Lower}}Previous}, plugin.Version{ID: g.Release}) + env := kittest.Env(t, kittest.Pages{g.RawURL("v"+{{.Lower}}Release, 1): file}) + return kittest.Versions(t, env, Plugin{Guide: g}, plugin.Version{ID: {{.Lower}}Previous}, plugin.Version{ID: {{.Lower}}Release}) } `, imports: []string{"slices", "github.com/patch-it-dev/patch-it-plugins/core/event", "github.com/patch-it-dev/patch-it-plugins/core/plugin", "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide/members"}, @@ -328,9 +332,6 @@ var {{.Ident}} = File{ API: "{{.ID}}", Package: "{{.PyPI}}", Ecosystem: "pypi", Module: "{{.Module}}", Repo: "TODO-owner/TODO-repo", TagPrefix: "v", Path: "CHANGELOG.md", } - -// {{.Ident}}Golden is the release the golden test pins. -var {{.Ident}}Golden = {{.Ident}}.At("1.0.0") `, register: `plugin.Register(Plugin{File: {{.Ident}}})`, pluginOf: `Plugin{File: {{.Ident}}}`, @@ -345,7 +346,12 @@ var {{.Ident}}Golden = {{.Ident}}.At("1.0.0") - A placeholder entry. `}, source: "{{.File}}-CHANGELOG.md", - ingest: `// {{.Lower}}Previous is the release before {{.Ident}}Golden's on the + ingest: `// {{.Ident}}Golden is the release the golden test pins: only a test names +// one. +// ` + todo + `: the real release. +var {{.Ident}}Golden = {{.Ident}}.At("1.0.0") + +// {{.Lower}}Previous is the release before {{.Ident}}Golden's on the // registry: the pair's older side. // ` + todo + `: the real release before it. const {{.Lower}}Previous = "0.0.0" @@ -421,40 +427,46 @@ func {{.Lower}}Ingest(t *testing.T, file string) []event.Event { defDir: "plugins/catalog", def: `package catalog -// {{.Ident}} is {{.Provider}}'s catalog: one JSON object, one key per command -// or endpoint, at a git ref. +import "regexp" + +// {{.Ident}} is {{.Provider}}'s command catalog: one JSON file per command in a +// directory of its repo, read at each release tag, as Redis's is (redis.go). // // ` + todo + `: the ecosystem and package for the events' subject, the repo, -// the catalog's path and the commits API URL for the newest ref. Say what you -// checked, with the date, as catalog.go does for Redis. -var {{.Ident}} = Catalog{ +// the directory and the release tags' shape. Say what you checked, with the +// date, as redis.go does for Redis. +var {{.Ident}} = Commands{ API: "{{.ID}}", Ecosystem: "{{.ProviderID}}", Package: "{{.ProviderID}}", - Repo: "TODO-owner/TODO-repo", Path: "TODO/commands.json", - RefsURL: "https://api.github.com/repos/TODO-owner/TODO-repo/commits/main", + Repo: "TODO-owner/TODO-repo", Dir: "TODO/commands", + Release: regexp.MustCompile(` + "`" + `^v?(\d+\.\d+\.\d+)$` + "`" + `), } `, - register: `plugin.Register(Plugin{Catalog: {{.Ident}}})`, - pluginOf: `Plugin{Catalog: {{.Ident}}}`, + register: `plugin.Register({{.Ident}})`, + pluginOf: `{{.Ident}}`, fixtures: map[string]string{ - "{{.File}}-old.json": "{\"PLACEHOLDER\": {}}\n", - "{{.File}}-new.json": "{\"PLACEHOLDER\": {}}\n", + "{{.File}}-old.json": "[{\"name\": \"placeholder.json\", \"type\": \"file\"}, {\"name\": \"kept.json\", \"type\": \"file\"}]\n", + "{{.File}}-new.json": "[{\"name\": \"kept.json\", \"type\": \"file\"}]\n", + "{{.File}}-placeholder.json": "{\"PLACEHOLDER\": {\"summary\": \"a placeholder\"}}\n", }, - source: "{{.File}}-new.json", - ingest: `// The two refs the saved snapshots are at. -// ` + todo + `: the real commits, oldest first. + dropFile: "[{\"name\": \"placeholder.json\", \"type\": \"file\"}, {\"name\": \"kept.json\", \"type\": \"file\"}, {\"name\": \"added.json\", \"type\": \"file\"}]\n", + source: "{{.File}}-new.json", + ingest: `// The two releases the saved listings are at. +// ` + todo + `: the real tags, oldest first. const ( - {{.Lower}}OldRef = "0000000000000000000000000000000000000000" - {{.Lower}}NewRef = "1111111111111111111111111111111111111111" + {{.Lower}}OldRef = "v1.0.0" + {{.Lower}}NewRef = "v2.0.0" ) -// {{.Lower}}Ingest extracts the change from the saved old snapshot to file. +// {{.Lower}}Ingest is the version pair from the saved old listing to file, +// the newer release's listing; a file gone from it is read at the old tag. func {{.Lower}}Ingest(t *testing.T, file string) []event.Event { t.Helper() env := kittest.Env(t, kittest.Pages{ - {{.Ident}}.URL({{.Lower}}OldRef): "testdata/{{.File}}-old.json", - {{.Ident}}.URL({{.Lower}}NewRef): file, + {{.Ident}}.listingURL({{.Lower}}OldRef): "testdata/{{.File}}-old.json", + {{.Ident}}.listingURL({{.Lower}}NewRef): file, + {{.Ident}}.FileURL({{.Lower}}OldRef, "placeholder.json"): "testdata/{{.File}}-placeholder.json", }) - return kittest.Versions(t, env, Plugin{Catalog: {{.Ident}}}, + return kittest.Versions(t, env, {{.Ident}}, plugin.Version{ID: {{.Lower}}OldRef, Ref: {{.Lower}}OldRef}, plugin.Version{ID: {{.Lower}}NewRef, Ref: {{.Lower}}NewRef}) } `, diff --git a/core/github/github.go b/core/github/github.go index b056470..f0db860 100644 --- a/core/github/github.go +++ b/core/github/github.go @@ -16,6 +16,7 @@ import ( "time" "github.com/patch-it-dev/patch-it-plugins/core/fetch" + "github.com/patch-it-dev/patch-it-plugins/core/plugin" ) // API is GitHub's REST API. @@ -63,7 +64,8 @@ func LatestRelease(ctx context.Context, get Getter, url string) (string, error) } // LatestCommit reads a commit list (url: commits?path=&per_page=1, newest -// first) and returns the newest commit's SHA, or an error when it lists none. +// first) and returns the newest commit's SHA, or an error when it lists none +// (plugin.ErrNothingToRead: no commit ever changed the path). func LatestCommit(ctx context.Context, get Getter, url string) (string, error) { body, err := get(ctx, url) if err != nil { @@ -76,7 +78,7 @@ func LatestCommit(ctx context.Context, get Getter, url string) (string, error) { return "", fmt.Errorf("parsing github commits response: %w", err) } if len(commits) == 0 || commits[0].SHA == "" { - return "", fmt.Errorf("github lists no commit") + return "", fmt.Errorf("github lists no commit: %w", plugin.ErrNothingToRead) } return commits[0].SHA, nil } diff --git a/core/versions/versions.go b/core/versions/versions.go index 6684245..5cf8d3d 100644 --- a/core/versions/versions.go +++ b/core/versions/versions.go @@ -149,6 +149,16 @@ func GitHubCommits(ctx context.Context, get Getter, repo, path string) ([]plugin // yanked releases, none without files), oldest first by version. The Ref is // the version; a plugin that reads a repo at a tag maps it. func PyPIReleases(ctx context.Context, get Getter, pkg string) ([]plugin.Version, error) { + return pypiReleases(ctx, get, pkg, false) +} + +// PyPIReleasesWithYanked are PyPIReleases and the yanked final releases too: +// for a source whose change can be documented at a release later yanked. +func PyPIReleasesWithYanked(ctx context.Context, get Getter, pkg string) ([]plugin.Version, error) { + return pypiReleases(ctx, get, pkg, true) +} + +func pypiReleases(ctx context.Context, get Getter, pkg string, withYanked bool) ([]plugin.Version, error) { body, err := get(ctx, PyPI+"/pypi/"+url.PathEscape(pkg)+"/json") if err != nil { return nil, fmt.Errorf("listing %s's releases on PyPI: %w", pkg, err) @@ -175,7 +185,7 @@ func PyPIReleases(ctx context.Context, get Getter, pkg string) ([]plugin.Version first = f.Uploaded } } - if yanked { + if yanked && !withYanked { continue } out = append(out, plugin.Version{ID: v, Released: first.UTC(), Ref: v, URL: "https://pypi.org/project/" + pkg + "/" + v + "/"}) @@ -249,6 +259,12 @@ func Major(v string) int { return n } +// FirstOfMajor is true for X.0.0, the first release of a major (X > 0). +func FirstOfMajor(v string) bool { + m := Major(v) + return m > 0 && v == fmt.Sprintf("%d.0.0", m) +} + // Pairs are the consecutive pairs of vs, oldest first: what a backfill // extracts, one pair at a time. func Pairs(vs []plugin.Version) [][2]plugin.Version { diff --git a/core/versions/versions_test.go b/core/versions/versions_test.go index e6d3e40..eef3ce1 100644 --- a/core/versions/versions_test.go +++ b/core/versions/versions_test.go @@ -116,6 +116,21 @@ func TestPyPIReleasesAreFinalAndNotYanked(t *testing.T) { if !vs[0].Released.Equal(time.Date(2024, 1, 1, 0, 0, 0, 0, time.UTC)) { t.Errorf("released %v", vs[0].Released) } + all, err := PyPIReleasesWithYanked(context.Background(), get, "acme") + if err != nil { + t.Fatal(err) + } + if got := ids(all); got != "1.0.0@1.0.0 1.9.0@1.9.0 1.9.1@1.9.1 1.10.0@1.10.0" { + t.Errorf("with yanked: got %s", got) + } +} + +func TestFirstOfMajor(t *testing.T) { + for v, want := range map[string]bool{"2.0.0": true, "11.0.0": true, "2.0.1": false, "2.1.0": false, "0.0.0": false, "2.0": false, "2.0.0rc1": false} { + if got := FirstOfMajor(v); got != want { + t.Errorf("FirstOfMajor(%q) = %v, want %v", v, got, want) + } + } } func TestNPMReleases(t *testing.T) { diff --git a/docs/which-kind.md b/docs/which-kind.md index f2f67c9..fd39bf2 100644 --- a/docs/which-kind.md +++ b/docs/which-kind.md @@ -12,7 +12,7 @@ Every kind is one of two shapes ([writing-a-plugin.md, step 4](writing-a-plugin. | Is there a **guide that lists what a release removed**, one per major or per release, in a table? | `migrationguide` | The guide at the release's tag: removed request parameters (reader `sdk`) or removed members of a module (reader `members`, RST or Markdown tables) | `MIGRATION.md` per major; "removed members" tables in a 2.0 migration guide; an API version removal guide | | Is there a **changelog**: a file per release (`CHANGELOG.md`, `CHANGES.rst`, `HISTORY.rst`), or a machine-readable JSON changelog? | `changelog` | The release's section at its tag (reader `markdown`), or the life-cycle entries a JSON changelog adds commit by commit (reader `json`) | Keep a Changelog files; reStructuredText release notes; an API changelog JSON in a repo; a Terraform provider's changelog | | Is there a **live page of dated notices**: a deprecations or shutdown table, an end-of-life table, or an **RSS/Atom feed** of announcements? | `notices` | The page as it is now, cited through a Web Archive snapshot, against the snapshot kept from the read before: a living page, with no versions of its own (reader `deprecations`, `feed`, or an end-of-life table) | A model deprecations page; an API end-of-life policy table; a changelog feed with a "deprecation" label; a Kubernetes API removals page | -| Is there a **flat catalog**, one JSON entry per name (a command, an endpoint), with no release tags? | `catalog` | Two snapshots, compared for names that disappeared entirely | A list of commands a server accepts, kept in a repo | +| Is there a **structured catalog** in the provider's repo: one JSON file per command, or one file of upcoming removals? | `catalog` | Each release (or commit) of the catalog, compared with the one before: names that disappeared entirely, or removals newly announced | The command definitions a server is built from, at each release tag | | Is it a **published package** with no changelog worth reading? | `apisurface` | Each release's files from the registry (PyPI first), compared: removed or renamed classes, functions, methods, and parameters removed or newly required | An SDK generated from a spec, released often, whose changelog says "chore: update types" | Still no "yes"? Open a [discussion](https://github.com/patch-it-dev/patch-it-plugins/discussions) with the source's link: a new kind is a new package under `plugins/`, and the questions above get one more row. diff --git a/docs/writing-a-plugin.md b/docs/writing-a-plugin.md index 01b4ea7..036ceda 100644 --- a/docs/writing-a-plugin.md +++ b/docs/writing-a-plugin.md @@ -83,10 +83,10 @@ Write the numbers on the provider page, as `providers/vercel.md` does for its sp | Kind | Reads | Add a source by | |---|---|---| | `plugins/openapi` | An OpenAPI spec per release, diffed with `core/diff/` and turned into events by `core/normalize/` | An `adapter.Adapter` in `plugins/openapi/adapter/` (latest tag, fetch a tag's spec; `Versions` to list every release) and a `plugin.RegisterProvider` block | -| `plugins/notices` | A live page of dated notices: a model provider's deprecations page (a table of date, model, replacement), a vendor's RSS or Atom feed, a vendor's table of whole API version ranges and their support status | A `retire.Page` in `plugins/notices/retire/providers.go`, a `feed.Feed` with a reader for that vendor's entries in `plugins/notices/feed/`, or an `eol.Page` in `plugins/notices/eol/` (`new-plugin` doesn't scaffold this reader yet) | +| `plugins/notices` | A live page of dated notices: a model provider's deprecations page (a table of date, model, replacement: Markdown, Markdoc or HTML), a vendor's RSS or Atom feed, a vendor's table of whole API version ranges and their support status | A `retire.Page` in `plugins/notices/retire/providers.go`, a `feed.Feed` with a reader for that vendor's entries in `plugins/notices/feed/`, or an `eol.Page` in `plugins/notices/eol/` (`new-plugin` doesn't scaffold this reader yet) | | `plugins/migrationguide` | A guide that lists what a release removed, at the release's tag: an SDK's migration guide per new major (removed request parameters), or a package's table of removed members (an RST simple table or a Markdown pipe table) | A `sdkguide.Guide` in `plugins/migrationguide/sdkguide/`, or a `members.Guide` in `plugins/migrationguide/members/` | | `plugins/changelog` | A changelog: a `CHANGELOG.md` / `CHANGES.rst` / `HISTORY.rst`, each release's section at its tag (releases from PyPI or npm), or a vendor's machine-readable API changelog in JSON (per day, endpoint and API version, oasdiff change codes), commit by commit | A `changelog.File` with its `TagPrefix`, or a `changelog.Log` | -| `plugins/catalog` | A flat JSON catalog, one entry per name, with no release tags to pin — a commit SHA stands in | A `catalog.Catalog`, diffed between two snapshots for names that disappeared entirely | +| `plugins/catalog` | A provider's own structured list of what it offers: a command catalog kept as one JSON file per command in its repo, read at each release tag and compared for commands that disappeared entirely | A `catalog.Commands` (repo, directory, release tag pattern); a catalog of another shape is a new reader type in the package | | `plugins/apisurface` | A published package's public API, compared between two releases: the classes, functions, methods and parameters in each release's files (Python first: the wheel or sdist from PyPI) | A `apisurface.Package` (registry name, ecosystem, top-level module) and its `plugin.RegisterProvider` block | ## 4. The interface @@ -136,7 +136,7 @@ When a release or a page has no part the reader can use (a changelog with no sec A source that has versions (a spec's releases, a package's releases, a guide per major, the commits that changed a file) is read version by version, so a customer several versions behind gets every step: the runner lists the versions, reads each consecutive pair with `ReadAt` and extracts it once (a released version never changes). -- **List** with [`core/versions`](../core/versions/versions.go): `GitHubReleases`, `GitHubTags`, `GitHubCommits` (the commits that changed a file), `PyPIReleases`, `NPMReleases`, `GitHubPages` (any other GitHub list, page by page). An OpenAPI adapter lists its own versions (`adapter.Lister`): every adapter does. Never pin a tag in code: a version you need for a golden test is a pinned *case* in the test (`changelog.Urllib3.At("2.0.0")`), not the registered source. +- **List** with [`core/versions`](../core/versions/versions.go): `GitHubReleases`, `GitHubTags`, `GitHubCommits` (the commits that changed a file), `PyPIReleases` (`PyPIReleasesWithYanked` when a change can be documented at a release later yanked), `NPMReleases`, `GitHubPages` (any other GitHub list, page by page). An OpenAPI adapter lists its own versions (`adapter.Lister`): every adapter does. Never pin a tag in code: a version you need for a golden test is a pinned *case* in the test (`changelog.Urllib3.At("2.0.0")`, in a `_test.go` file), not the registered source; `plugins/all`'s `TestNoPinnedReleaseInPluginCode` fails on a release number or commit SHA in any plugin's non-test code. - **Read at** a version's `Ref` (a tag, a commit SHA) and return the exact URL read as the snapshot's `SourceURL`: it's the events' citation. - **Extract** sets `previous_version` to `from`'s version: every `api_operation` and `package_release` event must name it (the contract's rule 13). `from` is zero only for the first version read, which has nothing to compare: patch-it's hosted ingestion service reads that version as its first snapshot and extracts nothing from it, so a version pair always starts at a real `from` (an `api_operation` or `package_release` event extracted from zero would be rejected). @@ -204,11 +204,13 @@ The test kit, `core/kit/kittest`, runs the plugin with no network, no database a ```go func TestGolden(t *testing.T) { env := kittest.Env(t, kittest.Pages{ - Redis.URL(oldRef): "testdata/redis-doc-cc0427b.json", - Redis.URL(newRef): "testdata/redis-doc-06f3598.json", + Redis.listingURL("8.8-m03"): "testdata/redis-contents-src-commands-8.8-m03.json", + Redis.listingURL("8.8-rc1"): "testdata/redis-contents-src-commands-8.8-rc1.json", + Redis.FileURL("8.8-m03", "gcra.json"): "testdata/redis-8.8-m03-gcra.json", + Redis.FileURL("8.8-m03", "gcrasetvalue.json"): "testdata/redis-8.8-m03-gcrasetvalue.json", }) - got := kittest.Versions(t, env, Plugin{Catalog: Redis}, - plugin.Version{ID: oldRef, Ref: oldRef}, plugin.Version{ID: newRef, Ref: newRef}) + got := kittest.Versions(t, env, Redis, + plugin.Version{ID: "8.8-m03", Ref: "8.8-m03"}, plugin.Version{ID: "8.8-rc1", Ref: "8.8-rc1"}) kittest.Golden(t, "testdata/golden/redis-commands.json", got) } ``` diff --git a/plugins/all/pins_test.go b/plugins/all/pins_test.go new file mode 100644 index 0000000..62fd2a1 --- /dev/null +++ b/plugins/all/pins_test.go @@ -0,0 +1,56 @@ +package all + +import ( + "go/ast" + "go/parser" + "go/token" + "io/fs" + "path/filepath" + "regexp" + "strconv" + "strings" + "testing" +) + +// release is a specific release in a string: a version number with three +// parts ("2.0.0", "v0.86.0", "posthog-v8.0.0", "python-agent-110000" aside) +// or a full commit SHA. A source lists its versions (PyPI, npm, tags, +// commits); only a test pins one, through its saved fixtures. +var release = regexp.MustCompile(`(^|[^0-9A-Za-z.])v?\d+\.\d+\.\d+([^0-9]|$)|(^|[^0-9a-f])[0-9a-f]{40}([^0-9a-f]|$)`) + +// No plugin's code names a specific release or commit: every version comes +// from where the source publishes them. Comments may name the release a +// reader was checked at; a string the code uses may not. +func TestNoPinnedReleaseInPluginCode(t *testing.T) { + fset := token.NewFileSet() + err := filepath.WalkDir("..", func(path string, d fs.DirEntry, err error) error { + if err != nil { + return err + } + if d.IsDir() && d.Name() == "testdata" { + return filepath.SkipDir + } + if d.IsDir() || !strings.HasSuffix(path, ".go") || strings.HasSuffix(path, "_test.go") { + return nil + } + f, err := parser.ParseFile(fset, path, nil, 0) + if err != nil { + return err + } + ast.Inspect(f, func(n ast.Node) bool { + lit, ok := n.(*ast.BasicLit) + if !ok || lit.Kind != token.STRING { + return true + } + s, err := strconv.Unquote(lit.Value) + if err == nil && release.MatchString(s) { + t.Errorf("%s: %q names a specific release; list versions from the source and pin one only in a test", fset.Position(lit.Pos()), s) + } + return true + }) + return nil + }) + if err != nil { + t.Fatal(err) + } +} diff --git a/plugins/catalog/catalog.go b/plugins/catalog/catalog.go index 164ed96..aaf2470 100644 --- a/plugins/catalog/catalog.go +++ b/plugins/catalog/catalog.go @@ -1,28 +1,21 @@ -// Package catalog is the source plugin for a provider that publishes its -// whole command or endpoint surface as one structured JSON file, one entry -// keyed by name: read it at a commit, compare it with the one read before, -// and report -// every name that disappeared entirely between them. Unlike openapi's typed -// spec, an entry here is opaque: no request or response shape to walk, just -// whether the name is still there. Redis first: its command surface has no -// OpenAPI spec, but redis-doc's commands.json is the real, machine-readable -// file redis.io's own command reference is generated from. +// Package catalog is the kind for a provider's own structured list of what +// it offers or is about to take away: a command catalog, a file of upcoming +// removals. Unlike openapi's typed spec, an entry here is opaque beyond its +// name (and, for a list of upcoming changes, its date and what to use +// instead). Each reader is a plugin of its own in this package, read +// version by version (plugin.Versioned): Redis's commands at each release +// tag (redis.go), GitHub's GraphQL upcoming changes at each commit +// (graphql.go). // -// Precision over recall: a name that moves to a different key (a genuine -// rename) reads as one removal and one addition, same as any other. This -// never guesses a rename from two disappearances and appearances landing in -// the same diff; it only ever reports what's gone. +// Precision over recall: a name that moves (a genuine rename) reads as one +// removal and one addition, same as any other. A reader never guesses a +// rename from a disappearance and an appearance landing in the same diff. package catalog import ( - "context" - "encoding/json" "fmt" - "sort" - "time" "github.com/patch-it-dev/patch-it-plugins/core/event" - "github.com/patch-it-dev/patch-it-plugins/core/github" "github.com/patch-it-dev/patch-it-plugins/core/plugin" ) @@ -31,162 +24,45 @@ func init() { ID: "redis", Name: "Redis", Category: plugin.CategoryDatabases, Homepage: "https://redis.io", Sources: []plugin.Source{{ ID: "commands", Layer: plugin.LayerRuntime, Page: "providers/redis.md", - Watches: "Commands removed entirely from Redis's own command catalog between two snapshots", - URLs: []string{"https://github.com/redis/redis-doc/blob/master/commands.json"}, - Plugin: Plugin{Catalog: Redis}, + Watches: "Commands removed entirely between two Redis releases, from the command definitions in the server's own source (src/commands/) at each release tag", + URLs: []string{"https://github.com/redis/redis/tree/unstable/src/commands", "https://github.com/redis/redis/releases"}, + Plugin: Redis, + }}, + }) + plugin.RegisterProvider(plugin.Provider{ + ID: "github", Name: "GitHub", Category: plugin.CategoryDevTools, Homepage: "https://github.com", + Sources: []plugin.Source{{ + ID: "graphql", Layer: plugin.LayerAPI, Page: "providers/github-graphql.md", + Watches: "GraphQL API fields, arguments, input fields and enum values GitHub announces it will remove, with the date, from the file its breaking-changes page is built from", + URLs: []string{"https://docs.github.com/en/graphql/overview/breaking-changes", "https://github.com/github/docs/blob/main/src/graphql/data/fpt/upcoming-changes.json"}, + Packages: []string{"npm:@octokit/graphql"}, + Plugin: GitHubGraphQL, }}, }) } -// Catalog is one provider's command or endpoint catalog: a single JSON -// object, one key per entry, fetched at a git ref. -type Catalog struct { - API string // the source id the events carry: "redis/commands" - Ecosystem string // the package_release subject's ecosystem: "redis" - Package string // the package_release subject's package: "redis" - Repo string // owner/name on GitHub the catalog lives in - Path string // the catalog's path in the repo - RefsURL string // GitHub's commits API, for the newest ref: .../commits/ -} - -// Redis is redis-doc's commands.json, regenerated from each real Redis -// release and read by redis.io's own command reference (checked 2026-11-18). -// The repo has no tags, so a ref here is a commit SHA, not a release. -var Redis = Catalog{ - API: "redis/commands", Ecosystem: "redis", Package: "redis", - Repo: "redis/redis-doc", Path: "commands.json", - RefsURL: "https://api.github.com/repos/redis/redis-doc/commits/master", -} - -// URL is the catalog as it was at ref: its own provenance. -func (c Catalog) URL(ref string) string { - return fmt.Sprintf("https://raw.githubusercontent.com/%s/%s/%s", c.Repo, ref, c.Path) -} - -// parse reads the catalog as a flat map of name to its raw entry: every -// field of an entry (arity, complexity, ACL categories...) is unread, except -// where an entry's own bytes become an event's excerpt. -func parse(data []byte) (map[string]json.RawMessage, error) { - var out map[string]json.RawMessage - if err := json.Unmarshal(data, &out); err != nil { - return nil, fmt.Errorf("parsing catalog: %w", err) - } - return out, nil -} - -// removed is every name of old that new doesn't have, sorted so the result -// (and the fingerprints built from it) don't depend on map order. -func removed(old, new map[string]json.RawMessage) []string { - var out []string - for name := range old { - if _, ok := new[name]; !ok { - out = append(out, name) - } - } - sort.Strings(out) - return out -} - -// Plugin reads one catalog. -type Plugin struct { - Catalog Catalog -} - -func (p Plugin) Name() string { return p.Catalog.API } - -// ListVersions is the catalog repo's newest commit: the catalog has no -// releases, so each commit read is a version, and the change into it is -// extracted against the one read before. -func (p Plugin) ListVersions(ctx context.Context, env plugin.Env) ([]plugin.Version, error) { - ref, err := p.latestRef(ctx, env) - if err != nil { - return nil, err - } - return []plugin.Version{{ID: ref, Ref: ref}}, nil -} - -// ReadAt fetches the catalog at v's commit. -func (p Plugin) ReadAt(ctx context.Context, env plugin.Env, v plugin.Version) (plugin.Snapshot, error) { - url := p.Catalog.URL(v.Ref) - body, err := env.Get(ctx, url) - if err != nil { - return plugin.Snapshot{}, fmt.Errorf("fetching %s: %w", url, err) - } - return plugin.Snapshot{Version: v, Content: body, SourceURL: url}, nil -} - -// Extract is an event per command in from's catalog that isn't in to's, -// with previous_version from's commit. A zero from has nothing to compare. -func (p Plugin) Extract(_ context.Context, env plugin.Env, from, to plugin.Snapshot) (plugin.Result, error) { - events, rejected, err := p.events(from.Content, to.Content, from.Version.Ref, to.Version.Ref, env.Now()) - if err != nil { - return plugin.Result{}, err - } - return plugin.Result{Events: events, Rejected: rejected}, nil -} - -var _ plugin.Versioned = Plugin{} - -// latestRef asks GitHub for the catalog repo's newest commit. -func (p Plugin) latestRef(ctx context.Context, env plugin.Env) (string, error) { - sha, err := github.Head(ctx, env.Get, p.Catalog.RefsURL) - if err != nil { - return "", fmt.Errorf("looking up the newest commit: %w", err) - } - return sha, nil -} - -// events diffs two parsed snapshots into events. oldContent is empty for -// the first version read (nothing before it): diffing against no snapshot -// reports nothing, the same as an unchanged one. -func (p Plugin) events(oldContent, newContent []byte, from, to string, now time.Time) ([]event.Event, []error, error) { - c := p.Catalog - newEntries, err := parse(newContent) - if err != nil { - return nil, nil, fmt.Errorf("parsing %s: %w", c.URL(to), err) - } - var oldEntries map[string]json.RawMessage - if len(oldContent) > 0 { - oldEntries, err = parse(oldContent) - if err != nil { - return nil, nil, fmt.Errorf("parsing %s: %w", c.URL(from), err) - } - } - - var events []event.Event - var rejected []error - for _, name := range removed(oldEntries, newEntries) { - subject := event.Subject{ - Type: event.SubjectPackageRelease, Ecosystem: c.Ecosystem, Package: c.Package, - Change: event.PackageRemovedSymbol, Symbols: []string{name}, - } - e := event.Event{ - API: c.API, Version: to, PreviousVersion: from, - ChangeType: event.ChangeTypeBreaking, - Breaking: true, - Subject: subject, - Description: fmt.Sprintf("%s no longer exists: calling it now fails.", name), - SourceURL: c.URL(from), - SourceExcerpt: excerpt(name, oldEntries[name]), - Confidence: 1.0, - DetectedAt: now, +// finish fingerprints and validates the events a reader made, keeping the +// valid ones and the reasons the others failed. details, when given, are +// the fingerprints' detail, one per event: what separates two changes at +// one location. +func finish(api string, made []event.Event, details []string) (events []event.Event, rejected []error) { + for i, e := range made { + detail := "" + if details != nil { + detail = details[i] } - e.Fingerprint = event.Fingerprint(e.API, e.Version, e.ChangeType, subject, "") + e.Fingerprint = event.Fingerprint(e.API, e.Version, e.ChangeType, e.Subject, detail) if err := e.Validate(); err != nil { - rejected = append(rejected, fmt.Errorf("%s: %w", name, err)) + rejected = append(rejected, fmt.Errorf("%s %s: %w", api, e.Description, err)) continue } events = append(events, e) } - return events, rejected, nil + return events, rejected } -// excerpt quotes the entry exactly as the old snapshot had it: the evidence -// that name existed, in the catalog's own shape. Capped at the contract's -// 2000-character limit, the entry's closing braces never cut off: nested -// command-line arguments can run long. -func excerpt(name string, raw json.RawMessage) string { - s := fmt.Sprintf("%q: %s", name, string(raw)) +// excerpt caps a quote at the contract's 2000 characters. +func excerpt(s string) string { if r := []rune(s); len(r) > 2000 { s = string(r[:1999]) + "…" } diff --git a/plugins/catalog/catalog_test.go b/plugins/catalog/catalog_test.go index e34f31f..1e5ba88 100644 --- a/plugins/catalog/catalog_test.go +++ b/plugins/catalog/catalog_test.go @@ -2,118 +2,91 @@ package catalog import ( "context" + "errors" + "slices" + "strings" "testing" - "time" "github.com/patch-it-dev/patch-it-plugins/core/event" + "github.com/patch-it-dev/patch-it-plugins/core/fetch" "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" "github.com/patch-it-dev/patch-it-plugins/core/plugin" ) -// The two commits redis-doc's own history shows the removal happen between: -// PR #1697 dropped FUNCTION CREATE and FUNCTION INFO from commands.json on -// 2022-01-24 (checked 2026-11-18), replacing the single-function CREATE with -// a whole-library LOAD. Neither command ever reached a tagged Redis release -// (not even 7.0's first release candidate, which shipped a week later with -// neither in its own src/commands/): a real removal, but one that happened -// before any user could depend on it, not a production break. -const ( - oldRef = "cc0427b3c3671e90b92f1ad2fe4e835fd32cd3c9" - newRef = "06f3598f39c7ca86dbdb0aa1668cfdd1b82b908d" -) - -func env(pages kittest.Pages, t *testing.T) plugin.Env { - return plugin.Env{Get: pages.Get(t), Now: time.Now} -} - -func fixturePages() kittest.Pages { - return kittest.Pages{ - Redis.URL(oldRef): "testdata/redis-doc-cc0427b.json", - Redis.URL(newRef): "testdata/redis-doc-06f3598.json", +// redisPair is the version pair from -> to over the saved listings (and the +// removed files at from's tag), as the hosted ingestion service extracts it. +func redisPair(t *testing.T, from, to string, files ...string) []event.Event { + t.Helper() + pages := kittest.Pages{ + Redis.listingURL(from): "testdata/redis-contents-src-commands-" + from + ".json", + Redis.listingURL(to): "testdata/redis-contents-src-commands-" + to + ".json", } -} - -// The golden test and the pair fixture in one: testdata/redis-doc-cc0427b.json -// and redis-doc-06f3598.json are real, trimmed excerpts of redis-doc's -// commands.json at those two commits (checked 2026-11-18). Between them, -// FUNCTION CREATE and FUNCTION INFO disappear, FUNCTION LOAD appears, and GET -// (an unrelated, long-lived command) is unchanged: the version pair -// oldRef → newRef, read with ReadAt and Extract. -func TestPairRecreatesTheRealFunctionCommandRemoval(t *testing.T) { - ctx := context.Background() - s := kittest.NewMem() - e := env(fixturePages(), t) - - rejected, err := kittest.Pair(ctx, e, s, Plugin{Catalog: Redis}, oldRef, newRef) - if err != nil || rejected { - t.Fatalf("pair: rejected=%v err=%v", rejected, err) + for _, f := range files { + pages[Redis.FileURL(from, f)] = "testdata/redis-" + from + "-" + f } + return kittest.Versions(t, kittest.Env(t, pages), Redis, plugin.Version{ID: from, Ref: from}, plugin.Version{ID: to, Ref: to}) +} - events, err := s.All() - if err != nil { - t.Fatalf("reading events: %v", err) - } - // Precision over recall: GET (unchanged) and FUNCTION LOAD (added, not - // removed) must produce nothing. Only the two real removals should. - got := map[string]bool{} - for _, ev := range events { - if len(ev.Subject.Symbols) != 1 { - t.Fatalf("event with %d symbols, want exactly 1: %+v", len(ev.Subject.Symbols), ev) +// The one removal in redis/redis's src/commands/ between any two tags from +// 7.0 to 8.12 (checked 2026-11-20): GCRA and GCRASETVALUE, added in the +// 8.8 milestone builds, are gone at 8.8-rc1. Final releases never removed a +// command in that span, so the golden pins this pre-release pair: the real +// files, the real listings. +func TestGolden(t *testing.T) { + got := redisPair(t, "8.8-m03", "8.8-rc1", "gcra.json", "gcrasetvalue.json") + var names []string + for _, e := range got { + names = append(names, e.Subject.Symbols[0]) + if e.SourceURL != Redis.FileURL("8.8-m03", strings.ToLower(e.Subject.Symbols[0])+".json") || !strings.Contains(e.SourceExcerpt, `"since":"8.8.0"`) { + t.Errorf("%s: cites %s, quoting %.80q", e.Subject.Symbols[0], e.SourceURL, e.SourceExcerpt) } - got[ev.Subject.Symbols[0]] = true } - want := map[string]bool{"FUNCTION CREATE": true, "FUNCTION INFO": true} - if len(got) != len(want) { - t.Fatalf("stored %v, want exactly %v (GET and FUNCTION LOAD must drop silently)", got, want) - } - for name := range want { - if !got[name] { - t.Errorf("missing an event for %s", name) - } + if !slices.Equal(names, []string{"GCRA", "GCRASETVALUE"}) { + t.Errorf("removed %v, want GCRA and GCRASETVALUE", names) } + kittest.Golden(t, "testdata/golden/redis-commands.json", got) +} - // Acceptance criteria: every event carries source_url and a non-empty - // source_excerpt, is marked breaking, and is placed on the real refs. - for _, ev := range events { - if ev.API != "redis/commands" || ev.Version != newRef || ev.PreviousVersion != oldRef { - t.Errorf("event %v: api=%s version=%s previous_version=%s, want redis/commands %s from %s", - ev.Subject.Symbols, ev.API, ev.Version, ev.PreviousVersion, newRef, oldRef) - } - if ev.ChangeType != event.ChangeTypeBreaking || !ev.Breaking { - t.Errorf("event %v: change_type=%s breaking=%v, want breaking", ev.Subject.Symbols, ev.ChangeType, ev.Breaking) - } - if ev.SourceURL != Redis.URL(oldRef) { - t.Errorf("event %v: source_url=%s, want the old snapshot, where the removed command is still evidenced", ev.Subject.Symbols, ev.SourceURL) - } - if ev.SourceExcerpt == "" { - t.Errorf("event %v: missing source_excerpt", ev.Subject.Symbols) - } +// The pinned drop test: 8.8.0 -> 8.10.0 adds 17 command files (the array +// commands, INCREX…) and removes none. Nothing is an event, and nothing +// past the two listings is fetched. +func TestReleasesThatOnlyAddCommandsHaveNoEvents(t *testing.T) { + if got := redisPair(t, "8.8.0", "8.10.0"); len(got) != 0 { + t.Errorf("%d events, want 0", len(got)) } +} - // Reading the same pair again must not duplicate the events. - if _, err := kittest.Pair(ctx, e, s, Plugin{Catalog: Redis}, oldRef, newRef); err != nil { - t.Fatalf("second read of the pair: %v", err) +// A subcommand is named with its container, as code sends it. +func TestASubcommandIsNamedWithItsContainer(t *testing.T) { + name, _, err := command([]byte(`{"KILL": {"summary": "x", "container": "CLIENT"}}`)) + if err != nil || name != "CLIENT KILL" { + t.Errorf("%q, %v", name, err) } - if again, _ := s.All(); len(again) != len(events) { - t.Errorf("reading the pair again added events: %d -> %d", len(events), len(again)) + if _, _, err := command([]byte(`{"A": {}, "B": {}}`)); err == nil { + t.Error("two commands in one file must be an error, not a guess") } } -// The catalog's versions are its newest commit, looked up on GitHub; that -// version read with nothing before it has nothing to compare, so no events. -// kittest extracts it twice, so a second extract that found anything new -// would fail it too. -func TestTheNewestCommitAloneHasNoEvents(t *testing.T) { - pages := kittest.Pages{ - Redis.RefsURL: "testdata/commits-master.json", - Redis.URL(newRef): "testdata/redis-doc-06f3598.json", +// Versions are the final releases on GitHub, by version number (a patch to +// an older line published later stays in its place), each read at its tag. +// A release before src/commands/ existed has nothing to read. +func TestVersionsAreFinalReleasesByVersion(t *testing.T) { + env := kittest.Env(t, kittest.Pages{ + "https://api.github.com/repos/redis/redis/releases?per_page=100&page=1": "testdata/redis-releases-excerpt.json", + }) + vs, err := Redis.ListVersions(context.Background(), env) + if err != nil { + t.Fatal(err) + } + var ids []string + for _, v := range vs { + ids = append(ids, v.ID+"@"+v.Ref) } - e, p := kittest.Env(t, pages), Plugin{Catalog: Redis} - vs, err := p.ListVersions(context.Background(), e) - if err != nil || len(vs) != 1 || vs[0].Ref != newRef { - t.Fatalf("versions %v, %v; want the newest commit, %s", vs, err, newRef) + if got := strings.Join(ids, " "); got != "6.2.20@6.2.20 7.2.10@7.2.10 8.0.0@8.0.0 8.0.1@8.0.1" { + t.Errorf("versions %s", got) } - if events := kittest.Versions(t, e, p, plugin.Version{}, vs[0]); len(events) != 0 { - t.Errorf("found %d events, want 0: there is nothing yet to diff against", len(events)) + notFound := plugin.Env{Get: func(context.Context, string) ([]byte, error) { return nil, &fetch.StatusError{StatusCode: 404} }} + if _, err := Redis.ReadAt(context.Background(), notFound, plugin.Version{ID: "6.2.20", Ref: "6.2.20"}); !errors.Is(err, plugin.ErrNothingToRead) { + t.Errorf("no src/commands/ at the tag: %v, want plugin.ErrNothingToRead", err) } } diff --git a/plugins/catalog/graphql.go b/plugins/catalog/graphql.go new file mode 100644 index 0000000..511f94b --- /dev/null +++ b/plugins/catalog/graphql.go @@ -0,0 +1,199 @@ +package catalog + +import ( + "context" + "encoding/json" + "fmt" + "html" + "regexp" + "sort" + "strings" + + "github.com/patch-it-dev/patch-it-plugins/core/event" + "github.com/patch-it-dev/patch-it-plugins/core/github" + "github.com/patch-it-dev/patch-it-plugins/core/plugin" + "github.com/patch-it-dev/patch-it-plugins/core/versions" +) + +// UpcomingChanges is a GraphQL API's file of announced removals, kept in a +// repo and read at each commit that changed it: GitHub's +// src/graphql/data/fpt/upcoming-changes.json in github/docs, which +// docs.github.com's "Breaking changes" page is built from. The file is an +// object keyed by removal date, each a list of {location, description, +// reason, date, criticality}: location is "Type.field" (or +// "Type.field.argument"), date the day it goes. +// +// A version is a commit (its date, its SHA). An entry in to's file that +// from's didn't have is a newly announced removal: a deprecation event on +// that location whose version is the removal date (GitHub's GraphQL API has +// no versions of its own, so the day it breaks is the one to gate on, as a +// model's shutdown date is), with previous_version the commit before. An +// entry a commit drops and a later one restores, with the same date, is then +// the same event again, which the store dedupes by fingerprint. An entry dated before the commit that +// adds it isn't an announcement (a revert putting back a removal already +// made: the file lost and regained 17 such entries on 2026-01-05 and 06), and +// an entry that leaves the file isn't read: it shipped, or was withdrawn, +// and the file doesn't say which. +type UpcomingChanges struct { + API string // the source id the events carry: "github/graphql" + Vendor string // for sentences: "GitHub" + Repo string // owner/name on GitHub + Path string // the file's path in the repo + // Endpoint is the GraphQL endpoint as an operation: every query and + // mutation is a POST to it ("POST /graphql"). + Endpoint string +} + +// GitHubGraphQL is GitHub's GraphQL API's upcoming changes (checked +// 2026-11-21: 1,291 entries, every one "criticality": "breaking", 29 +// commits since 2023-05-01). +var GitHubGraphQL = UpcomingChanges{ + API: "github/graphql", Vendor: "GitHub", + Repo: "github/docs", Path: "src/graphql/data/fpt/upcoming-changes.json", + Endpoint: "POST /graphql", +} + +func (u UpcomingChanges) Name() string { return u.API } + +// FileURL is the file at a commit: its own provenance. +func (u UpcomingChanges) FileURL(sha string) string { + return fmt.Sprintf("%s/%s/%s/%s", github.Raw, u.Repo, sha, u.Path) +} + +// ListVersions is every commit that changed the file, oldest first. +func (u UpcomingChanges) ListVersions(ctx context.Context, env plugin.Env) ([]plugin.Version, error) { + return versions.GitHubCommits(ctx, env.Get, u.Repo, u.Path) +} + +// ReadAt fetches the file at v's commit. +func (u UpcomingChanges) ReadAt(ctx context.Context, env plugin.Env, v plugin.Version) (plugin.Snapshot, error) { + url := u.FileURL(v.Ref) + body, err := env.Get(ctx, url) + if err != nil { + return plugin.Snapshot{}, fmt.Errorf("fetching %s: %w", url, err) + } + return plugin.Snapshot{Version: v, Content: body, SourceURL: url}, nil +} + +// upcoming is one entry of the file: the fields read, in the file's order, +// which is also how an event quotes it (the entry's "owner", a GitHub team +// or handle, is left out). +type upcoming struct { + Location string `json:"location"` + Description string `json:"description"` + Reason string `json:"reason"` + Date string `json:"date"` + Criticality string `json:"criticality"` +} + +func (e upcoming) key() string { return e.Location + "@" + e.Date } + +// entries reads the file: every entry, in the file's order of dates. +func entries(body []byte) ([]upcoming, error) { + var byDate map[string][]json.RawMessage + if err := json.Unmarshal(body, &byDate); err != nil { + return nil, err + } + dates := make([]string, 0, len(byDate)) + for d := range byDate { + dates = append(dates, d) + } + sort.Strings(dates) + var out []upcoming + for _, d := range dates { + for _, r := range byDate[d] { + var e upcoming + if err := json.Unmarshal(r, &e); err != nil { + return nil, err + } + out = append(out, e) + } + } + return out, nil +} + +var gqlTag = regexp.MustCompile(`<[^>]+>`) + +// gqlText is an entry's HTML as one plain sentence. +func gqlText(s string) string { + return strings.Join(strings.Fields(html.UnescapeString(gqlTag.ReplaceAllString(s, ""))), " ") +} + +// Extract is a deprecation event per entry in to's file that from's didn't +// have, dated before to's commit or not at all excluded (see +// UpcomingChanges), with previous_version from's commit. A zero from has +// nothing to compare. +func (u UpcomingChanges) Extract(_ context.Context, env plugin.Env, from, to plugin.Snapshot) (plugin.Result, error) { + if from.IsZero() { + return plugin.Result{}, nil + } + before, err := entries(from.Content) + if err != nil { + return plugin.Result{}, fmt.Errorf("reading %s: %w", from.SourceURL, err) + } + after, err := entries(to.Content) + if err != nil { + return plugin.Result{}, fmt.Errorf("reading %s: %w", to.SourceURL, err) + } + had := map[string]bool{} + for _, e := range before { + had[e.key()] = true + } + var made []event.Event + var details []string + for _, e := range after { + if had[e.key()] || e.Date < to.Version.ID || e.Criticality != "breaking" { + continue + } + subject, ok := u.subject(e.Location) + if !ok { + continue + } + var quote strings.Builder + enc := json.NewEncoder("e) + enc.SetEscapeHTML(false) + if err := enc.Encode(e); err != nil { + return plugin.Result{}, err + } + hint := gqlText(e.Description) + if r := gqlText(e.Reason); r != "" && r != hint { + hint += " " + r + } + made = append(made, event.Event{ + API: u.API, Version: e.Date, PreviousVersion: from.Version.ID, + ChangeType: event.ChangeTypeDeprecation, + Subject: subject, + Description: fmt.Sprintf("%s's GraphQL API removes %s on %s: code that queries or sends it fails from that date.", + u.Vendor, e.Location, e.Date), + MigrationHint: hint, + SourceURL: to.SourceURL, + SourceExcerpt: excerpt(strings.TrimSpace(quote.String())), + Confidence: 1.0, + DetectedAt: env.Now().UTC(), + }) + details = append(details, "") + } + events, rejected := finish(u.API, made, details) + return plugin.Result{Events: events, Rejected: rejected}, nil +} + +// subject places a location in the contract's api_operation: an input +// object's field, or an argument of a root field (Query.field.argument), is +// a request parameter of the endpoint; any other location (a field, a root +// field itself, a field's argument, an enum's value) is a property of its +// type, as a schema. +func (u UpcomingChanges) subject(location string) (event.Subject, bool) { + typ, rest, ok := strings.Cut(location, ".") + if !ok || typ == "" || rest == "" { + return event.Subject{}, false + } + root := typ == "Query" || typ == "Mutation" || typ == "Subscription" + if strings.HasSuffix(typ, "Input") || (root && strings.Contains(rest, ".")) { + return event.Subject{Type: event.SubjectAPIOperation, Kind: event.KindRequestParameter, Side: event.SideRequest, + Operation: u.Endpoint, Property: location}, true + } + return event.Subject{Type: event.SubjectAPIOperation, Kind: event.KindSchemaProperty, Side: event.SideResponse, + Schema: typ, Property: rest}, true +} + +var _ plugin.Versioned = UpcomingChanges{} diff --git a/plugins/catalog/graphql_test.go b/plugins/catalog/graphql_test.go new file mode 100644 index 0000000..632ccbd --- /dev/null +++ b/plugins/catalog/graphql_test.go @@ -0,0 +1,145 @@ +package catalog + +import ( + "context" + "fmt" + "strings" + "testing" + + "github.com/patch-it-dev/patch-it-plugins/core/event" + "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" + "github.com/patch-it-dev/patch-it-plugins/core/plugin" + "github.com/patch-it-dev/patch-it-plugins/core/versions" +) + +// The commits of github/docs the saved files are at (testdata/README.md), +// oldest first, as GitHub's commit list names them. +var graphqlCommits = []plugin.Version{ + {ID: "2026-01-05", Ref: "fc26275f90e62249fabc0f287255b3e5e60cb6e8"}, + {ID: "2026-01-06", Ref: "54c26c43342f7818c4001af7eaf6a3295e3f822d"}, + {ID: "2026-01-08", Ref: "2706f417a6afec24c57482d62f70035ee35c10fb"}, + {ID: "2026-02-13", Ref: "fc7cedfe9c6b2c0a40fd213cd18c0afc774b67fc"}, + {ID: "2026-03-03", Ref: "3a14e541873e834edf32b43b71911fe80d109a70"}, + {ID: "2026-05-22", Ref: "a934f06d211bef668253e3826c118a4e559dc1ba"}, + {ID: "2026-06-23", Ref: "c5738e5815fff90d38f0166f7c9949bfb664e003"}, +} + +func graphqlPages() kittest.Pages { + pages := kittest.Pages{} + for _, v := range graphqlCommits { + pages[GitHubGraphQL.FileURL(v.Ref)] = "testdata/github-graphql-upcoming-changes-" + v.Ref[:8] + ".json" + } + return pages +} + +func graphqlPair(t *testing.T, from, to plugin.Version) []event.Event { + t.Helper() + return kittest.Versions(t, kittest.Env(t, graphqlPages()), GitHubGraphQL, from, to) +} + +// The golden test: four consecutive commits, three pairs. 2026-03-03 adds +// CheckAnnotation.databaseId and Artifact.databaseId (removed on +// 2027-01-01, in the file's order), 2026-05-22 User.viewerRelevantRepositories +// and 2026-06-23 CopilotAgentTask.type (both 2026-10-01). Every entry the +// commits share is no event. +func TestGraphQLGolden(t *testing.T) { + var got []event.Event + var names []string + for _, pair := range versions.Pairs(graphqlCommits[3:]) { + for _, e := range graphqlPair(t, pair[0], pair[1]) { + got = append(got, e) + names = append(names, fmt.Sprintf("%s->%s %s.%s", e.PreviousVersion, pair[1].ID, e.Subject.Schema, e.Subject.Property)) + } + } + want := "2026-02-13->2026-03-03 CheckAnnotation.databaseId | 2026-02-13->2026-03-03 Artifact.databaseId | 2026-03-03->2026-05-22 User.viewerRelevantRepositories | 2026-05-22->2026-06-23 CopilotAgentTask.type" + if strings.Join(names, " | ") != want { + t.Errorf("got %s\nwant %s", strings.Join(names, " | "), want) + } + for _, e := range got { + if e.ChangeType != event.ChangeTypeDeprecation || e.Subject.Kind != event.KindSchemaProperty || !strings.Contains(e.SourceExcerpt, `"criticality":"breaking"`) || strings.Contains(e.SourceExcerpt, "owner") { + t.Errorf("%+v", e) + } + } + for i := range got { + got[i].ID = 0 + } + kittest.Golden(t, "testdata/golden/github-graphql.json", got) +} + +// The pinned drop test: on 2026-01-05 the file lost 17 entries (removals +// dated 2024-07-01 to 2026-01-01, already made), got them back the next day +// and lost them again on 2026-01-08. Putting back a removal already past +// isn't an announcement, and an entry leaving the file says nothing: no +// event in either pair, though the second pair adds 17 entries. +func TestGraphQLRevertsAreNoAnnouncement(t *testing.T) { + for _, pair := range versions.Pairs(graphqlCommits[:3]) { + if got := graphqlPair(t, pair[0], pair[1]); len(got) != 0 { + t.Errorf("%s -> %s: %d events, want 0", pair[0].ID, pair[1].ID, len(got)) + } + } + // The second pair does add entries: what the date check drops. + from, _ := GitHubGraphQL.ReadAt(context.Background(), kittest.Env(t, graphqlPages()), graphqlCommits[0]) + to, _ := GitHubGraphQL.ReadAt(context.Background(), kittest.Env(t, graphqlPages()), graphqlCommits[1]) + a, _ := entries(from.Content) + b, _ := entries(to.Content) + if len(b)-len(a) != 17 { + t.Errorf("the re-added entries: %d, want 17", len(b)-len(a)) + } +} + +// An input object's field and a root field's argument are request +// parameters of POST /graphql; any other location is a property of its type. +func TestGraphQLLocations(t *testing.T) { + for loc, want := range map[string]string{ + "AddPullRequestReviewInput.comments": "request_parameter POST /graphql AddPullRequestReviewInput.comments", + "Query.sponsorables.dependencyEcosystem": "request_parameter POST /graphql Query.sponsorables.dependencyEcosystem", + "RepositoryPermission.TRIAGE_PLUS": "schema_property RepositoryPermission TRIAGE_PLUS", + "Issue.stateReason.enableDuplicate": "schema_property Issue stateReason.enableDuplicate", + } { + s, ok := GitHubGraphQL.subject(loc) + got := strings.Join(strings.Fields(fmt.Sprintf("%s %s %s %s", s.Kind, s.Operation, s.Schema, s.Property)), " ") + if !ok || got != want { + t.Errorf("%s: %q, want %q", loc, got, want) + } + } + if _, ok := GitHubGraphQL.subject("NoDot"); ok { + t.Error("a location without a field isn't read") + } +} + +func TestGraphQLVersionsAreTheFilesCommits(t *testing.T) { + env := kittest.Env(t, kittest.Pages{ + "https://api.github.com/repos/github/docs/commits?path=src%2Fgraphql%2Fdata%2Ffpt%2Fupcoming-changes.json&per_page=100&page=1": "testdata/github-commits-upcoming-changes-excerpt.json", + }) + vs, err := GitHubGraphQL.ListVersions(context.Background(), env) + if err != nil || len(vs) != 3 || vs[0].Ref != graphqlCommits[3].Ref || vs[2].ID != "2026-05-22" { + t.Errorf("%v %v", vs, err) + } +} + +// An entry a commit drops while still upcoming and a later commit restores +// is the same event: its version is the removal date, not the commit's, so +// the fingerprint matches and the store keeps one. +func TestGraphQLARestoredEntryIsTheSameEvent(t *testing.T) { + first := graphqlPair(t, graphqlCommits[3], graphqlCommits[4]) + // 2026-03-03's file without its two additions, then the file again. + from, err := GitHubGraphQL.ReadAt(context.Background(), kittest.Env(t, graphqlPages()), graphqlCommits[3]) + if err != nil { + t.Fatal(err) + } + to, err := GitHubGraphQL.ReadAt(context.Background(), kittest.Env(t, graphqlPages()), graphqlCommits[4]) + if err != nil { + t.Fatal(err) + } + from.Version = plugin.Version{ID: "2026-04-01", Ref: "dropped"} + to.Version = plugin.Version{ID: "2026-04-02", Ref: "restored"} + again, err := GitHubGraphQL.Extract(context.Background(), kittest.Env(t, nil), from, to) + if err != nil || len(again.Events) != len(first) { + t.Fatalf("%v, %d events", err, len(again.Events)) + } + for i, e := range again.Events { + if e.Version != "2027-01-01" || e.Fingerprint != first[i].Fingerprint { + t.Errorf("%s: version %s, same fingerprint %v", e.Subject.Property, e.Version, e.Fingerprint == first[i].Fingerprint) + } + } +} diff --git a/plugins/catalog/redis.go b/plugins/catalog/redis.go new file mode 100644 index 0000000..e78253c --- /dev/null +++ b/plugins/catalog/redis.go @@ -0,0 +1,193 @@ +package catalog + +import ( + "bytes" + "context" + "encoding/json" + "errors" + "fmt" + "net/url" + "regexp" + "slices" + "sort" + "strings" + + "github.com/patch-it-dev/patch-it-plugins/core/event" + "github.com/patch-it-dev/patch-it-plugins/core/fetch" + "github.com/patch-it-dev/patch-it-plugins/core/github" + "github.com/patch-it-dev/patch-it-plugins/core/plugin" + "github.com/patch-it-dev/patch-it-plugins/core/versions" +) + +// Commands is a server's command catalog kept as one JSON file per command +// in a directory of its own repo, read at each release tag: Redis's +// src/commands/, which the server's command table (and redis.io's command +// reference) is generated from. Each file is one object, keyed by the +// command's name, a subcommand naming its parent as "container" +// ({"KILL": {"container": "CLIENT", ...}} is CLIENT KILL). +// +// A version is a release: its tag lists the directory (one GitHub API +// call), and a command whose file is gone from the next release's listing +// is removed. Only a removed file is fetched, at the older tag, for the +// command's name and the entry quoted as evidence. +type Commands struct { + API string // the source id the events carry: "redis/commands" + Ecosystem string // the package_release subject's ecosystem: "redis" + Package string // the package_release subject's package: "redis" + Repo string // owner/name on GitHub + Dir string // the directory of command files in the repo + // Release matches a final release's tag; its first submatch is the + // version. + Release *regexp.Regexp +} + +// Redis is redis/redis's src/commands/ (checked 2026-11-20: 460 files at +// 8.10.0, every final release a GitHub release tagged X.Y.Z). The directory +// exists from 7.0.0; an older release has nothing to read. +var Redis = Commands{ + API: "redis/commands", Ecosystem: "redis", Package: "redis", + Repo: "redis/redis", Dir: "src/commands", + Release: regexp.MustCompile(`^(\d+\.\d+\.\d+)$`), +} + +func (c Commands) Name() string { return c.API } + +// listingURL is GitHub's listing of the directory at a ref. +func (c Commands) listingURL(ref string) string { + return fmt.Sprintf("%s/repos/%s/contents/%s?ref=%s", github.API, c.Repo, c.Dir, url.QueryEscape(ref)) +} + +// FileURL is one command's file at a ref: its own provenance, as a tag +// never changes. +func (c Commands) FileURL(ref, file string) string { + return fmt.Sprintf("%s/%s/%s/%s/%s", github.Raw, c.Repo, ref, c.Dir, file) +} + +// ListVersions is every final release on GitHub, ordered by version, not by +// publication date: Redis patches older lines after a newer one ships +// (7.2.10 after 8.0.0), and a pair across lines would read the older line's +// missing commands as removals. +func (c Commands) ListVersions(ctx context.Context, env plugin.Env) ([]plugin.Version, error) { + vs, err := versions.GitHubReleases(ctx, env.Get, c.Repo, c.Release.MatchString) + if err != nil { + return nil, err + } + for i := range vs { + vs[i].ID = c.Release.FindStringSubmatch(vs[i].Ref)[1] + } + slices.SortStableFunc(vs, func(a, b plugin.Version) int { return versions.Compare(a.ID, b.ID) }) + return vs, nil +} + +// ReadAt lists the command files at v's tag, as a sorted JSON array of file +// names. A release without the directory (before 7.0.0) has nothing to +// read. +func (c Commands) ReadAt(ctx context.Context, env plugin.Env, v plugin.Version) (plugin.Snapshot, error) { + u := c.listingURL(v.Ref) + body, err := env.Get(ctx, u) + var se *fetch.StatusError + if errors.As(err, &se) && se.StatusCode == 404 { + return plugin.Snapshot{}, fmt.Errorf("no %s at %s: %w", c.Dir, v.Ref, plugin.ErrNothingToRead) + } + if err != nil { + return plugin.Snapshot{}, fmt.Errorf("listing %s at %s: %w", c.Dir, v.Ref, err) + } + var entries []struct { + Name string `json:"name"` + Type string `json:"type"` + } + if err := json.Unmarshal(body, &entries); err != nil { + return plugin.Snapshot{}, fmt.Errorf("parsing the listing of %s at %s: %w", c.Dir, v.Ref, err) + } + var files []string + for _, e := range entries { + if e.Type == "file" && strings.HasSuffix(e.Name, ".json") { + files = append(files, e.Name) + } + } + if len(files) == 0 { + return plugin.Snapshot{}, fmt.Errorf("no command files in %s at %s: %w", c.Dir, v.Ref, plugin.ErrNothingToRead) + } + sort.Strings(files) + content, _ := json.Marshal(files) + return plugin.Snapshot{Version: v, Content: content, SourceURL: fmt.Sprintf("https://github.com/%s/tree/%s/%s", c.Repo, v.Ref, c.Dir)}, nil +} + +// Extract is an event per command whose file is in from's listing and not +// in to's, citing the file at from's tag, with previous_version from's +// release. A zero from has nothing to compare. +func (c Commands) Extract(ctx context.Context, env plugin.Env, from, to plugin.Snapshot) (plugin.Result, error) { + if from.IsZero() { + return plugin.Result{}, nil + } + var before, after []string + if err := json.Unmarshal(from.Content, &before); err != nil { + return plugin.Result{}, fmt.Errorf("reading %s: %w", from.SourceURL, err) + } + if err := json.Unmarshal(to.Content, &after); err != nil { + return plugin.Result{}, fmt.Errorf("reading %s: %w", to.SourceURL, err) + } + var made []event.Event + for _, file := range before { + if slices.Contains(after, file) { + continue + } + u := c.FileURL(from.Version.Ref, file) + body, err := env.Get(ctx, u) + if err != nil { + return plugin.Result{}, fmt.Errorf("fetching %s: %w", u, err) + } + name, entry, err := command(body) + if err != nil { + return plugin.Result{}, fmt.Errorf("reading %s: %w", u, err) + } + made = append(made, event.Event{ + API: c.API, Version: to.Version.ID, PreviousVersion: from.Version.ID, + ChangeType: event.ChangeTypeBreaking, Breaking: true, + Subject: event.Subject{ + Type: event.SubjectPackageRelease, Ecosystem: c.Ecosystem, Package: c.Package, + Change: event.PackageRemovedSymbol, Symbols: []string{name}, + }, + Description: fmt.Sprintf("%s is gone in Redis %s (it was in %s): calling it fails.", name, to.Version.ID, from.Version.ID), + SourceURL: u, + SourceExcerpt: excerpt(entry), + Confidence: 1.0, + DetectedAt: env.Now().UTC(), + }) + } + events, rejected := finish(c.API, made, nil) + return plugin.Result{Events: events, Rejected: rejected}, nil +} + +// command reads one command file: its name ("CLIENT KILL" for a subcommand) +// and the file's entry, quoted as the file writes it, whitespace between +// tokens left out. +func command(body []byte) (name, entry string, err error) { + var file map[string]json.RawMessage + if err := json.Unmarshal(body, &file); err != nil { + return "", "", err + } + if len(file) != 1 { + return "", "", fmt.Errorf("%d commands in one file, want 1", len(file)) + } + for key, raw := range file { + var meta struct { + Container string `json:"container"` + } + if err := json.Unmarshal(raw, &meta); err != nil { + return "", "", err + } + name = key + if meta.Container != "" { + name = meta.Container + " " + key + } + var compact bytes.Buffer + if err := json.Compact(&compact, body); err != nil { + return "", "", err + } + entry = compact.String() + } + return name, entry, nil +} + +var _ plugin.Versioned = Commands{} diff --git a/plugins/catalog/registered_test.go b/plugins/catalog/registered_test.go index 66cb74d..1f8630c 100644 --- a/plugins/catalog/registered_test.go +++ b/plugins/catalog/registered_test.go @@ -7,5 +7,6 @@ import ( ) func TestRegistersItself(t *testing.T) { - kittest.Registered(t, Plugin{Catalog: Redis}) + kittest.Registered(t, Redis) + kittest.Registered(t, GitHubGraphQL) } diff --git a/plugins/catalog/testdata/README.md b/plugins/catalog/testdata/README.md index eea3aac..f71b7c9 100644 --- a/plugins/catalog/testdata/README.md +++ b/plugins/catalog/testdata/README.md @@ -1,9 +1,14 @@ # Saved catalog snapshots +The golden files, `golden/redis-commands.json` and `golden/github-graphql.json`, are what the catalog kind stores from the files below (`go test ./plugins/catalog -update`). + | File | URL | Fetched | License | Quote | |---|---|---|---|---| -| `redis-doc-cc0427b.json` | https://github.com/redis/redis-doc/blob/cc0427b3c3671e90b92f1ad2fe4e835fd32cd3c9/commands.json | 2026-11-18 | BSD-3-Clause (redis-doc); trimmed to `FUNCTION CREATE`, `FUNCTION INFO` and `GET` | `"FUNCTION CREATE": {"summary": "Create a function with the given arguments (name, code, description)", "since": "7.0.0", ...}` | -| `redis-doc-06f3598.json` | https://github.com/redis/redis-doc/blob/06f3598f39c7ca86dbdb0aa1668cfdd1b82b908d/commands.json | 2026-11-18 | BSD-3-Clause (redis-doc); trimmed to `FUNCTION LOAD` and `GET` | `"FUNCTION LOAD": {"summary": "Create a function with the given arguments (name, code, description)", "since": "7.0.0", ...}` | -| `commits-master.json` | n/a: a stand-in for `GET https://api.github.com/repos/redis/redis-doc/commits/master`'s response shape, not a saved page. The plugin never cites this lookup as an event's evidence, only the two files above. | — | — | — | - -Both `commands.json` snapshots are real, un-invented excerpts: `06f3598` ([PR #1697](https://github.com/redis/redis-doc/pull/1697), 2022-01-24) is the actual commit that removed `FUNCTION CREATE` and `FUNCTION INFO` and added `FUNCTION LOAD`; `cc0427b` is its immediate parent. `GET` is kept whole and unmodified in both as the drop-test fixture: an unrelated, decades-old command that must never produce an event just because the file around it changed. +| `redis-contents-src-commands-8.8-m03.json` | https://api.github.com/repos/redis/redis/contents/src/commands?ref=8.8-m03 | 2026-11-20 | BSD-3-Clause / RSALv2 / SSPLv1 / AGPLv3 (redis/redis); the listing cut to the two fields read, `name` and `type`, every entry kept | `{"name": "gcra.json", "type": "file"}` | +| `redis-contents-src-commands-8.8-rc1.json` | https://api.github.com/repos/redis/redis/contents/src/commands?ref=8.8-rc1 | 2026-11-20 | as above | no `gcra.json`, no `gcrasetvalue.json` | +| `redis-contents-src-commands-8.8.0.json`, `redis-contents-src-commands-8.10.0.json` | https://api.github.com/repos/redis/redis/contents/src/commands?ref=8.8.0 and `?ref=8.10.0` | 2026-11-20 | as above | the drop test: 17 files added, none removed | +| `redis-8.8-m03-gcra.json` | https://raw.githubusercontent.com/redis/redis/8.8-m03/src/commands/gcra.json | 2026-11-20 | as above, kept whole, byte for byte | `"GCRA": {"summary": "Rate limit via GCRA (Generic Cell Rate Algorithm).", … "since": "8.8.0"` | +| `redis-8.8-m03-gcrasetvalue.json` | https://raw.githubusercontent.com/redis/redis/8.8-m03/src/commands/gcrasetvalue.json | 2026-11-20 | as above, kept whole, byte for byte | `"GCRASETVALUE": {"summary": "An internal command for recording a GCRA TAT value during AOF rewrite and replication."` | +| `redis-releases-excerpt.json` | https://api.github.com/repos/redis/redis/releases (shape only) | written for the test, 2026-11-20 | not a saved copy: five entries in the shape of GitHub's releases API (`tag_name`, `draft`, `prerelease`, `published_at`, `html_url`), dates approximate, a pre-release and a patch to an older line published later among them | for the version-listing test only | +| `github-graphql-upcoming-changes-.json` (seven) | https://github.com/github/docs/blob//src/graphql/data/fpt/upcoming-changes.json at fc26275f, 54c26c43, 2706f417 (2026-01-05 to 08) and fc7cedfe, 3a14e541, a934f06d, c5738e58 (2026-02-13 to 06-23) | 2026-11-21 | CC BY 4.0 (github/docs content). Excerpts for testing: each keeps the first entry under every date of the first file of its group, and every entry the group's commits add; every kept entry unchanged, in the file's order. The plugin finds the same additions between them as between the full files (2, 1, 1; and 17 re-added, past-dated) | `"location": "CheckAnnotation.databaseId", "description": "

databaseId will be removed. Use fullDatabaseId instead.

"` | +| `github-commits-upcoming-changes-excerpt.json` | https://api.github.com/repos/github/docs/commits?path=src/graphql/data/fpt/upcoming-changes.json (shape only) | written for the test, 2026-11-21 | not a saved copy: three of the real commits (SHA, date, URL), newest first as GitHub lists them | for the version-listing test only | diff --git a/plugins/catalog/testdata/commits-master.json b/plugins/catalog/testdata/commits-master.json deleted file mode 100644 index 68ec6b0..0000000 --- a/plugins/catalog/testdata/commits-master.json +++ /dev/null @@ -1 +0,0 @@ -{"sha": "06f3598f39c7ca86dbdb0aa1668cfdd1b82b908d"} diff --git a/plugins/catalog/testdata/github-commits-upcoming-changes-excerpt.json b/plugins/catalog/testdata/github-commits-upcoming-changes-excerpt.json new file mode 100644 index 0000000..0be001c --- /dev/null +++ b/plugins/catalog/testdata/github-commits-upcoming-changes-excerpt.json @@ -0,0 +1,5 @@ +[ + {"sha": "a934f06d211bef668253e3826c118a4e559dc1ba", "html_url": "https://github.com/github/docs/commit/a934f06d211bef668253e3826c118a4e559dc1ba", "commit": {"committer": {"date": "2026-05-22T17:14:56Z"}}}, + {"sha": "3a14e541873e834edf32b43b71911fe80d109a70", "html_url": "https://github.com/github/docs/commit/3a14e541873e834edf32b43b71911fe80d109a70", "commit": {"committer": {"date": "2026-03-03T16:45:09Z"}}}, + {"sha": "fc7cedfe9c6b2c0a40fd213cd18c0afc774b67fc", "html_url": "https://github.com/github/docs/commit/fc7cedfe9c6b2c0a40fd213cd18c0afc774b67fc", "commit": {"committer": {"date": "2026-02-13T16:44:32Z"}}} +] diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-2706f417.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-2706f417.json new file mode 100644 index 0000000..c125b9b --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-2706f417.json @@ -0,0 +1,232 @@ +{ + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-3a14e541.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-3a14e541.json new file mode 100644 index 0000000..de52581 --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-3a14e541.json @@ -0,0 +1,270 @@ +{ + "2027-01-01": [ + { + "location": "CheckAnnotation.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2027-01-01", + "criticality": "breaking", + "owner": "github/actions-persistence" + }, + { + "location": "Artifact.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2027-01-01", + "criticality": "breaking", + "owner": "github/actions-persistence" + } + ], + "2026-07-01": [ + { + "location": "Team.viewerSubscription", + "description": "

viewerSubscription will be removed.

", + "reason": "

Team.viewerSubscription will be removed. Team notifications subscriptions are being deprecated.

", + "date": "2026-07-01", + "criticality": "breaking", + "owner": "peter-evans" + } + ], + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-07-01": [ + { + "location": "PullRequestReviewComment.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "JanKoszewski" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-54c26c43.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-54c26c43.json new file mode 100644 index 0000000..05022ae --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-54c26c43.json @@ -0,0 +1,370 @@ +{ + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-07-01": [ + { + "location": "TeamDiscussion.viewerCanPin", + "description": "

viewerCanPin will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.url", + "description": "

url will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.title", + "description": "

title will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.team", + "description": "

team will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.resourcePath", + "description": "

resourcePath will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.number", + "description": "

number will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.isPrivate", + "description": "

isPrivate will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.isPinned", + "description": "

isPinned will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.commentsUrl", + "description": "

commentsUrl will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.commentsResourcePath", + "description": "

commentsResourcePath will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.bodyVersion", + "description": "

bodyVersion will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "TeamDiscussion.authorAssociation", + "description": "

authorAssociation will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "CreateTeamDiscussionPayload.teamDiscussion", + "description": "

teamDiscussion will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "CreateTeamDiscussionInput.title", + "description": "

title will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "CreateTeamDiscussionInput.teamId", + "description": "

teamId will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "CreateTeamDiscussionInput.private", + "description": "

private will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + }, + { + "location": "CreateTeamDiscussionInput.body", + "description": "

body will be removed. Follow the guide at https://github.blog/changelog/2023-02-08-sunset-notice-team-discussions/ to find a suitable replacement.

", + "reason": "

The Team Discussions feature is deprecated in favor of Organization Discussions.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "deborah-digges" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-a934f06d.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-a934f06d.json new file mode 100644 index 0000000..d860287 --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-a934f06d.json @@ -0,0 +1,280 @@ +{ + "2027-01-01": [ + { + "location": "CheckAnnotation.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2027-01-01", + "criticality": "breaking", + "owner": "github/actions-persistence" + }, + { + "location": "Artifact.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2027-01-01", + "criticality": "breaking", + "owner": "github/actions-persistence" + } + ], + "2026-10-01": [ + { + "location": "User.viewerRelevantRepositories", + "description": "

viewerRelevantRepositories will be removed. Use viewerCopilotChatRepositorySuggestions instead.

", + "reason": "

viewerRelevantRepositories has been renamed to viewerCopilotChatRepositorySuggestions.

", + "date": "2026-10-01", + "criticality": "breaking", + "owner": "github/client-apps-platform" + } + ], + "2026-07-01": [ + { + "location": "Team.viewerSubscription", + "description": "

viewerSubscription will be removed.

", + "reason": "

Team.viewerSubscription will be removed. Team notifications subscriptions are being deprecated.

", + "date": "2026-07-01", + "criticality": "breaking", + "owner": "peter-evans" + } + ], + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-07-01": [ + { + "location": "PullRequestReviewComment.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "JanKoszewski" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-c5738e58.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-c5738e58.json new file mode 100644 index 0000000..41679ff --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-c5738e58.json @@ -0,0 +1,288 @@ +{ + "2027-01-01": [ + { + "location": "CheckAnnotation.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2027-01-01", + "criticality": "breaking", + "owner": "github/actions-persistence" + }, + { + "location": "Artifact.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2027-01-01", + "criticality": "breaking", + "owner": "github/actions-persistence" + } + ], + "2026-10-01": [ + { + "location": "User.viewerRelevantRepositories", + "description": "

viewerRelevantRepositories will be removed. Use viewerCopilotChatRepositorySuggestions instead.

", + "reason": "

viewerRelevantRepositories has been renamed to viewerCopilotChatRepositorySuggestions.

", + "date": "2026-10-01", + "criticality": "breaking", + "owner": "github/client-apps-platform" + }, + { + "location": "CopilotAgentTask.type", + "description": "

type will be removed. Use codingAgentFilter and codingAgentTypeFilter instead.

", + "reason": "

type will be removed.

", + "date": "2026-10-01", + "criticality": "breaking", + "owner": "github/copilot-mission-control" + } + ], + "2026-07-01": [ + { + "location": "Team.viewerSubscription", + "description": "

viewerSubscription will be removed.

", + "reason": "

Team.viewerSubscription will be removed. Team notifications subscriptions are being deprecated.

", + "date": "2026-07-01", + "criticality": "breaking", + "owner": "peter-evans" + } + ], + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-07-01": [ + { + "location": "PullRequestReviewComment.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "JanKoszewski" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-fc26275f.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-fc26275f.json new file mode 100644 index 0000000..c125b9b --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-fc26275f.json @@ -0,0 +1,232 @@ +{ + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/github-graphql-upcoming-changes-fc7cedfe.json b/plugins/catalog/testdata/github-graphql-upcoming-changes-fc7cedfe.json new file mode 100644 index 0000000..05cff49 --- /dev/null +++ b/plugins/catalog/testdata/github-graphql-upcoming-changes-fc7cedfe.json @@ -0,0 +1,252 @@ +{ + "2026-07-01": [ + { + "location": "Team.viewerSubscription", + "description": "

viewerSubscription will be removed.

", + "reason": "

Team.viewerSubscription will be removed. Team notifications subscriptions are being deprecated.

", + "date": "2026-07-01", + "criticality": "breaking", + "owner": "peter-evans" + } + ], + "2026-04-01": [ + { + "location": "TeamRemoveRepositoryAuditEntry.userUrl", + "description": "

userUrl will be removed.

", + "reason": "

The GraphQL audit-log is deprecated. Please use the REST API instead.

", + "date": "2026-04-01", + "criticality": "breaking", + "owner": "audit_logs" + } + ], + "2026-01-01": [ + { + "location": "NotificationThread.subject", + "description": "

subject will be removed. Use the optionalSubject field instead.

", + "reason": "

Null values are possible for this field.

", + "date": "2026-01-01", + "criticality": "breaking", + "owner": "github/notifications" + } + ], + "2025-10-01": [ + { + "location": "SecurityAdvisory.cvss", + "description": "

cvss will be removed. New cvss_severities field will now contain both cvss_v3 and cvss_v4 properties.

", + "reason": "

cvss will be removed.

", + "date": "2025-10-01", + "criticality": "breaking", + "owner": "github/advisory-database" + } + ], + "2025-04-01": [ + { + "location": "User.viewerCanCreateProjects", + "description": "

viewerCanCreateProjects will be removed.

", + "reason": "

Projects (classic) is being deprecated in favor of the new Projects experience, see: https://github.blog/changelog/2024-05-23-sunset-notice-projects-classic/.

", + "date": "2025-04-01", + "criticality": "breaking", + "owner": "github/memex" + } + ], + "2025-01-01": [ + { + "location": "AddMobileDevicePublicKeyPayload.expiresAt", + "description": "

expiresAt will be removed. Do not rely on this field, it is currently set to a date far in the future if a device key is expirationless

", + "reason": "

We are deprecating expirations for mobile device keys used in mobile 2FA

", + "date": "2025-01-01", + "criticality": "breaking", + "owner": "chriskirkland" + } + ], + "2024-10-01": [ + { + "location": "Workflow.hasWorkflowDispatchTrigger", + "description": "

hasWorkflowDispatchTrigger will be removed. Use has_workflow_dispatch_trigger_for_branch(branch_ref) instead.

", + "reason": "

has_workflow_dispatch_trigger is being removed because it can be misleading and only checks a repository's default branch

", + "date": "2024-10-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2024-07-01": [ + { + "location": "PullRequestReviewComment.databaseId", + "description": "

databaseId will be removed. Use fullDatabaseId instead.

", + "reason": "

databaseId will be removed because it does not support 64-bit signed integer identifiers.

", + "date": "2024-07-01", + "criticality": "breaking", + "owner": "JanKoszewski" + } + ], + "2024-04-01": [ + { + "location": "TopicSuggestionDeclineReason.TOO_SPECIFIC", + "description": "

TOO_SPECIFIC will be removed.

", + "reason": "

Suggested topics are no longer supported

", + "date": "2024-04-01", + "criticality": "breaking", + "owner": "calvinchilds" + } + ], + "2023-10-01": [ + { + "location": "PullRequestReviewComment.position", + "description": "

position will be removed. Use the line and startLine fields instead, which are file line numbers instead of diff line numbers

", + "reason": "

We are phasing out diff-relative positioning for PR comments

", + "date": "2023-10-01", + "criticality": "breaking", + "owner": "aharpole" + } + ], + "2023-07-01": [ + { + "location": "ProjectV2ItemFieldGroup.field", + "description": "

field will be removed. Check out the ProjectV2ItemFieldGroup#groupByField API as an example for the more capable alternative.

", + "reason": "

The ProjectV2ItemFieldGroup#field API is deprecated in favour of the more capable ProjectV2ItemFieldGroup#groupByField API.

", + "date": "2023-07-01", + "criticality": "breaking", + "owner": "stevepopovich" + } + ], + "2023-04-01": [ + { + "location": "Repository.squashPrTitleUsedAsDefault", + "description": "

squashPrTitleUsedAsDefault will be removed. Use Repository.squashMergeCommitTitle instead.

", + "reason": "

squashPrTitleUsedAsDefault will be removed.

", + "date": "2023-04-01", + "criticality": "breaking", + "owner": "github/pull_requests" + } + ], + "2023-02-10": [ + { + "location": "PackageType.MAVEN", + "description": "

MAVEN will be removed.

", + "reason": "

MAVEN will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2023-02-10", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2023-01-01": [ + { + "location": "ProjectV2View.visibleFields", + "description": "

visibleFields will be removed. Check out the ProjectV2View#fields API as an example for the more capable alternative.

", + "reason": "

The ProjectV2View#visibleFields API is deprecated in favour of the more capable ProjectV2View#fields API.

", + "date": "2023-01-01", + "criticality": "breaking", + "owner": "mattruggio" + } + ], + "2022-12-28": [ + { + "location": "PackageType.RUBYGEMS", + "description": "

RUBYGEMS will be removed.

", + "reason": "

RUBYGEMS will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-12-28", + "criticality": "breaking", + "owner": "ankitkaushal01" + } + ], + "2022-11-21": [ + { + "location": "PackageType.NUGET", + "description": "

NUGET will be removed.

", + "reason": "

NUGET will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2022-11-21", + "criticality": "breaking", + "owner": "s-anupam" + } + ], + "2022-10-01": [ + { + "location": "RemovePullRequestFromMergeQueueInput.branch", + "description": "

branch will be removed.

", + "reason": "

PRs are removed from the merge queue for the base branch, the branch argument is now a no-op

", + "date": "2022-10-01", + "criticality": "breaking", + "owner": "jhunschejones" + } + ], + "2022-07-01": [ + { + "location": "Query.sponsorables.dependencyEcosystem", + "description": "

dependencyEcosystem will be removed. Use the ecosystem argument instead.

", + "reason": "

The type is switching from SecurityAdvisoryEcosystem to DependencyGraphEcosystem.

", + "date": "2022-07-01", + "criticality": "breaking", + "owner": "cheshire137" + } + ], + "2021-10-01": [ + { + "location": "ReactionGroup.users", + "description": "

users will be removed. Use the reactors field instead.

", + "reason": "

Reactors can now be mannequins, bots, and organizations.

", + "date": "2021-10-01", + "criticality": "breaking", + "owner": "synthead" + } + ], + "2021-06-21": [ + { + "location": "PackageType.DOCKER", + "description": "

DOCKER will be removed.

", + "reason": "

DOCKER will be removed from this enum as this type will be migrated to only be used by the Packages REST API.

", + "date": "2021-06-21", + "criticality": "breaking", + "owner": "reybard" + } + ], + "2021-01-01": [ + { + "location": "MergeStateStatus.DRAFT", + "description": "

DRAFT will be removed. Use PullRequest.isDraft instead.

", + "reason": "

DRAFT state will be removed from this enum and isDraft should be used instead

", + "date": "2021-01-01", + "criticality": "breaking", + "owner": "nplasterer" + } + ], + "2020-10-01": [ + { + "location": "Sponsorship.sponsor", + "description": "

sponsor will be removed. Use Sponsorship.sponsorEntity instead.

", + "reason": "

Sponsorship.sponsor will be removed.

", + "date": "2020-10-01", + "criticality": "breaking", + "owner": "nholden" + } + ], + "2020-04-01": [ + { + "location": "Sponsorship.maintainer", + "description": "

maintainer will be removed. Use Sponsorship.sponsorable instead.

", + "reason": "

Sponsorship.maintainer will be removed.

", + "date": "2020-04-01", + "criticality": "breaking", + "owner": "antn" + } + ], + "2020-01-01": [ + { + "location": "UnassignedEvent.user", + "description": "

user will be removed. Use the assignee field instead.

", + "reason": "

Assignees can now be mannequins.

", + "date": "2020-01-01", + "criticality": "breaking", + "owner": "tambling" + } + ], + "2019-04-01": [ + { + "location": "LegacyMigration.uploadUrlTemplate", + "description": "

uploadUrlTemplate will be removed. Use uploadUrl instead.

", + "reason": "

uploadUrlTemplate is being removed because it is not a standard URL and adds an extra user step.

", + "date": "2019-04-01", + "criticality": "breaking", + "owner": "tambling" + } + ] +} diff --git a/plugins/catalog/testdata/golden/github-graphql.json b/plugins/catalog/testdata/golden/github-graphql.json new file mode 100644 index 0000000..579aac2 --- /dev/null +++ b/plugins/catalog/testdata/golden/github-graphql.json @@ -0,0 +1,90 @@ +[ + { + "id": 0, + "fingerprint": "sha256:b2d3b47705a97f5ad0eba1ad05610205e8134a851eb1a61e7ff4588dcb316f64", + "api": "github/graphql", + "version": "2027-01-01", + "previous_version": "2026-02-13", + "change_type": "deprecation", + "breaking": false, + "subject": { + "type": "api_operation", + "kind": "schema_property", + "side": "response", + "schema": "CheckAnnotation", + "property": "databaseId" + }, + "description": "GitHub's GraphQL API removes CheckAnnotation.databaseId on 2027-01-01: code that queries or sends it fails from that date.", + "migration_hint": "databaseId will be removed. Use fullDatabaseId instead. databaseId will be removed because it does not support 64-bit signed integer identifiers.", + "source_url": "https://raw.githubusercontent.com/github/docs/3a14e541873e834edf32b43b71911fe80d109a70/src/graphql/data/fpt/upcoming-changes.json", + "source_excerpt": "{\"location\":\"CheckAnnotation.databaseId\",\"description\":\"

databaseId will be removed. Use fullDatabaseId instead.

\",\"reason\":\"

databaseId will be removed because it does not support 64-bit signed integer identifiers.

\",\"date\":\"2027-01-01\",\"criticality\":\"breaking\"}", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 0, + "fingerprint": "sha256:cd07336291aa000b124d74fd081c22b95cc1ca0fabadf51cf776e9bb93e309f5", + "api": "github/graphql", + "version": "2027-01-01", + "previous_version": "2026-02-13", + "change_type": "deprecation", + "breaking": false, + "subject": { + "type": "api_operation", + "kind": "schema_property", + "side": "response", + "schema": "Artifact", + "property": "databaseId" + }, + "description": "GitHub's GraphQL API removes Artifact.databaseId on 2027-01-01: code that queries or sends it fails from that date.", + "migration_hint": "databaseId will be removed. Use fullDatabaseId instead. databaseId will be removed because it does not support 64-bit signed integer identifiers.", + "source_url": "https://raw.githubusercontent.com/github/docs/3a14e541873e834edf32b43b71911fe80d109a70/src/graphql/data/fpt/upcoming-changes.json", + "source_excerpt": "{\"location\":\"Artifact.databaseId\",\"description\":\"

databaseId will be removed. Use fullDatabaseId instead.

\",\"reason\":\"

databaseId will be removed because it does not support 64-bit signed integer identifiers.

\",\"date\":\"2027-01-01\",\"criticality\":\"breaking\"}", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 0, + "fingerprint": "sha256:da197a3086fc3c9c3642b6045598ee0f65d32f78b16c26c3697eedc79c0463ed", + "api": "github/graphql", + "version": "2026-10-01", + "previous_version": "2026-03-03", + "change_type": "deprecation", + "breaking": false, + "subject": { + "type": "api_operation", + "kind": "schema_property", + "side": "response", + "schema": "User", + "property": "viewerRelevantRepositories" + }, + "description": "GitHub's GraphQL API removes User.viewerRelevantRepositories on 2026-10-01: code that queries or sends it fails from that date.", + "migration_hint": "viewerRelevantRepositories will be removed. Use viewerCopilotChatRepositorySuggestions instead. viewerRelevantRepositories has been renamed to viewerCopilotChatRepositorySuggestions.", + "source_url": "https://raw.githubusercontent.com/github/docs/a934f06d211bef668253e3826c118a4e559dc1ba/src/graphql/data/fpt/upcoming-changes.json", + "source_excerpt": "{\"location\":\"User.viewerRelevantRepositories\",\"description\":\"

viewerRelevantRepositories will be removed. Use viewerCopilotChatRepositorySuggestions instead.

\",\"reason\":\"

viewerRelevantRepositories has been renamed to viewerCopilotChatRepositorySuggestions.

\",\"date\":\"2026-10-01\",\"criticality\":\"breaking\"}", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 0, + "fingerprint": "sha256:baa075ad2dbf3bd79789a7485b386db64b050383e1b6bf2de5ac11719d70263f", + "api": "github/graphql", + "version": "2026-10-01", + "previous_version": "2026-05-22", + "change_type": "deprecation", + "breaking": false, + "subject": { + "type": "api_operation", + "kind": "schema_property", + "side": "response", + "schema": "CopilotAgentTask", + "property": "type" + }, + "description": "GitHub's GraphQL API removes CopilotAgentTask.type on 2026-10-01: code that queries or sends it fails from that date.", + "migration_hint": "type will be removed. Use codingAgentFilter and codingAgentTypeFilter instead. type will be removed.", + "source_url": "https://raw.githubusercontent.com/github/docs/c5738e5815fff90d38f0166f7c9949bfb664e003/src/graphql/data/fpt/upcoming-changes.json", + "source_excerpt": "{\"location\":\"CopilotAgentTask.type\",\"description\":\"

type will be removed. Use codingAgentFilter and codingAgentTypeFilter instead.

\",\"reason\":\"

type will be removed.

\",\"date\":\"2026-10-01\",\"criticality\":\"breaking\"}", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + } +] diff --git a/plugins/catalog/testdata/golden/redis-commands.json b/plugins/catalog/testdata/golden/redis-commands.json new file mode 100644 index 0000000..3aefa65 --- /dev/null +++ b/plugins/catalog/testdata/golden/redis-commands.json @@ -0,0 +1,48 @@ +[ + { + "id": 1, + "fingerprint": "sha256:e615435aafad455137331aa8fb2365fc29c10fa75180a3129404c937ad9994d5", + "api": "redis/commands", + "version": "8.8-rc1", + "previous_version": "8.8-m03", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "package_release", + "ecosystem": "redis", + "package": "redis", + "change": "removed_symbol", + "symbols": [ + "GCRA" + ] + }, + "description": "GCRA is gone in Redis 8.8-rc1 (it was in 8.8-m03): calling it fails.", + "source_url": "https://raw.githubusercontent.com/redis/redis/8.8-m03/src/commands/gcra.json", + "source_excerpt": "{\"GCRA\":{\"summary\":\"Rate limit via GCRA (Generic Cell Rate Algorithm).\",\"complexity\":\"O(1)\",\"group\":\"rate_limit\",\"since\":\"8.8.0\",\"arity\":-5,\"function\":\"gcraCommand\",\"command_flags\":[\"WRITE\",\"DENYOOM\",\"FAST\"],\"acl_categories\":[\"RATE_LIMIT\"],\"key_specs\":[{\"flags\":[\"RW\",\"ACCESS\",\"UPDATE\"],\"begin_search\":{\"index\":{\"pos\":1}},\"find_keys\":{\"range\":{\"lastkey\":0,\"step\":1,\"limit\":0}}}],\"reply_schema\":{\"type\":\"array\",\"minItems\":5,\"maxItems\":5,\"description\":\"Rate limiting result\",\"items\":[{\"type\":\"integer\",\"description\":\"Limited: 0 if allowed, 1 if rate limited\"},{\"type\":\"integer\",\"description\":\"Max request tokens: always equal to max_burst+1\"},{\"type\":\"integer\",\"description\":\"Number of tokens available immediately\"},{\"type\":\"integer\",\"description\":\"Retry after: seconds after which the caller should retry. Always -1 if not limited\"},{\"type\":\"integer\",\"description\":\"Full burst after: seconds after which a full burst will be allowed\"}]},\"arguments\":[{\"name\":\"key\",\"type\":\"key\",\"key_spec_index\":0},{\"name\":\"max-burst\",\"type\":\"integer\"},{\"name\":\"tokens-per-period\",\"type\":\"integer\"},{\"name\":\"period\",\"type\":\"double\"},{\"name\":\"count\",\"type\":\"integer\",\"token\":\"TOKENS\",\"optional\":true}]}}", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 2, + "fingerprint": "sha256:b7bde4fd1e7978df475e23dfa7e283350ca4b63d17f88f7196930742bd24aecf", + "api": "redis/commands", + "version": "8.8-rc1", + "previous_version": "8.8-m03", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "package_release", + "ecosystem": "redis", + "package": "redis", + "change": "removed_symbol", + "symbols": [ + "GCRASETVALUE" + ] + }, + "description": "GCRASETVALUE is gone in Redis 8.8-rc1 (it was in 8.8-m03): calling it fails.", + "source_url": "https://raw.githubusercontent.com/redis/redis/8.8-m03/src/commands/gcrasetvalue.json", + "source_excerpt": "{\"GCRASETVALUE\":{\"summary\":\"An internal command for recording a GCRA TAT value during AOF rewrite and replication.\",\"complexity\":\"O(1)\",\"group\":\"rate_limit\",\"since\":\"8.8.0\",\"arity\":3,\"function\":\"gcraSetValueCommand\",\"command_flags\":[\"WRITE\",\"DENYOOM\",\"FAST\"],\"acl_categories\":[\"RATE_LIMIT\"],\"key_specs\":[{\"flags\":[\"OW\",\"UPDATE\"],\"begin_search\":{\"index\":{\"pos\":1}},\"find_keys\":{\"range\":{\"lastkey\":0,\"step\":1,\"limit\":0}}}],\"reply_schema\":{\"const\":\"OK\"},\"arguments\":[{\"name\":\"key\",\"type\":\"key\",\"key_spec_index\":0},{\"name\":\"tat\",\"type\":\"integer\"}]}}", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + } +] diff --git a/plugins/catalog/testdata/redis-8.8-m03-gcra.json b/plugins/catalog/testdata/redis-8.8-m03-gcra.json new file mode 100644 index 0000000..6980af1 --- /dev/null +++ b/plugins/catalog/testdata/redis-8.8-m03-gcra.json @@ -0,0 +1,92 @@ +{ + "GCRA": { + "summary": "Rate limit via GCRA (Generic Cell Rate Algorithm).", + "complexity": "O(1)", + "group": "rate_limit", + "since": "8.8.0", + "arity": -5, + "function": "gcraCommand", + "command_flags": [ + "WRITE", + "DENYOOM", + "FAST" + ], + "acl_categories": [ + "RATE_LIMIT" + ], + "key_specs": [ + { + "flags": [ + "RW", + "ACCESS", + "UPDATE" + ], + "begin_search": { + "index": { + "pos": 1 + } + }, + "find_keys": { + "range": { + "lastkey": 0, + "step": 1, + "limit": 0 + } + } + } + ], + "reply_schema": { + "type": "array", + "minItems": 5, + "maxItems": 5, + "description": "Rate limiting result", + "items": [ + { + "type": "integer", + "description": "Limited: 0 if allowed, 1 if rate limited" + }, + { + "type": "integer", + "description": "Max request tokens: always equal to max_burst+1" + }, + { + "type": "integer", + "description": "Number of tokens available immediately" + }, + { + "type": "integer", + "description": "Retry after: seconds after which the caller should retry. Always -1 if not limited" + }, + { + "type": "integer", + "description": "Full burst after: seconds after which a full burst will be allowed" + } + ] + }, + "arguments": [ + { + "name": "key", + "type": "key", + "key_spec_index": 0 + }, + { + "name": "max-burst", + "type": "integer" + }, + { + "name": "tokens-per-period", + "type": "integer" + }, + { + "name": "period", + "type": "double" + }, + { + "name": "count", + "type": "integer", + "token": "TOKENS", + "optional": true + } + ] + } +} diff --git a/plugins/catalog/testdata/redis-8.8-m03-gcrasetvalue.json b/plugins/catalog/testdata/redis-8.8-m03-gcrasetvalue.json new file mode 100644 index 0000000..5cce15c --- /dev/null +++ b/plugins/catalog/testdata/redis-8.8-m03-gcrasetvalue.json @@ -0,0 +1,52 @@ +{ + "GCRASETVALUE": { + "summary": "An internal command for recording a GCRA TAT value during AOF rewrite and replication.", + "complexity": "O(1)", + "group": "rate_limit", + "since": "8.8.0", + "arity": 3, + "function": "gcraSetValueCommand", + "command_flags": [ + "WRITE", + "DENYOOM", + "FAST" + ], + "acl_categories": [ + "RATE_LIMIT" + ], + "key_specs": [ + { + "flags": [ + "OW", + "UPDATE" + ], + "begin_search": { + "index": { + "pos": 1 + } + }, + "find_keys": { + "range": { + "lastkey": 0, + "step": 1, + "limit": 0 + } + } + } + ], + "reply_schema": { + "const": "OK" + }, + "arguments": [ + { + "name": "key", + "type": "key", + "key_spec_index": 0 + }, + { + "name": "tat", + "type": "integer" + } + ] + } +} diff --git a/plugins/catalog/testdata/redis-contents-src-commands-8.10.0.json b/plugins/catalog/testdata/redis-contents-src-commands-8.10.0.json new file mode 100644 index 0000000..b4f3e4d --- /dev/null +++ b/plugins/catalog/testdata/redis-contents-src-commands-8.10.0.json @@ -0,0 +1 @@ +[{"name":"README.md","type":"file"},{"name":"acl-cat.json","type":"file"},{"name":"acl-deluser.json","type":"file"},{"name":"acl-dryrun.json","type":"file"},{"name":"acl-genpass.json","type":"file"},{"name":"acl-getuser.json","type":"file"},{"name":"acl-help.json","type":"file"},{"name":"acl-list.json","type":"file"},{"name":"acl-load.json","type":"file"},{"name":"acl-log.json","type":"file"},{"name":"acl-save.json","type":"file"},{"name":"acl-setuser.json","type":"file"},{"name":"acl-users.json","type":"file"},{"name":"acl-whoami.json","type":"file"},{"name":"acl.json","type":"file"},{"name":"append.json","type":"file"},{"name":"arcount.json","type":"file"},{"name":"ardel.json","type":"file"},{"name":"ardelrange.json","type":"file"},{"name":"arget.json","type":"file"},{"name":"argetrange.json","type":"file"},{"name":"argrep.json","type":"file"},{"name":"arinfo.json","type":"file"},{"name":"arinsert.json","type":"file"},{"name":"arlastitems.json","type":"file"},{"name":"arlen.json","type":"file"},{"name":"armget.json","type":"file"},{"name":"armset.json","type":"file"},{"name":"arnext.json","type":"file"},{"name":"arop.json","type":"file"},{"name":"arring.json","type":"file"},{"name":"arscan.json","type":"file"},{"name":"arseek.json","type":"file"},{"name":"arset.json","type":"file"},{"name":"asking.json","type":"file"},{"name":"auth.json","type":"file"},{"name":"backup-abort.json","type":"file"},{"name":"backup-cleanup.json","type":"file"},{"name":"backup-help.json","type":"file"},{"name":"backup-list.json","type":"file"},{"name":"backup-seal.json","type":"file"},{"name":"backup-start.json","type":"file"},{"name":"backup-status.json","type":"file"},{"name":"backup.json","type":"file"},{"name":"bgrewriteaof.json","type":"file"},{"name":"bgsave.json","type":"file"},{"name":"bitcount.json","type":"file"},{"name":"bitfield.json","type":"file"},{"name":"bitfield_ro.json","type":"file"},{"name":"bitop.json","type":"file"},{"name":"bitpos.json","type":"file"},{"name":"blmove.json","type":"file"},{"name":"blmovem.json","type":"file"},{"name":"blmpop.json","type":"file"},{"name":"blpop.json","type":"file"},{"name":"brpop.json","type":"file"},{"name":"brpoplpush.json","type":"file"},{"name":"bzmpop.json","type":"file"},{"name":"bzpopmax.json","type":"file"},{"name":"bzpopmin.json","type":"file"},{"name":"client-caching.json","type":"file"},{"name":"client-getname.json","type":"file"},{"name":"client-getredir.json","type":"file"},{"name":"client-help.json","type":"file"},{"name":"client-id.json","type":"file"},{"name":"client-info.json","type":"file"},{"name":"client-kill.json","type":"file"},{"name":"client-list.json","type":"file"},{"name":"client-no-evict.json","type":"file"},{"name":"client-no-touch.json","type":"file"},{"name":"client-pause.json","type":"file"},{"name":"client-reply.json","type":"file"},{"name":"client-setinfo.json","type":"file"},{"name":"client-setname.json","type":"file"},{"name":"client-tracking.json","type":"file"},{"name":"client-trackinginfo.json","type":"file"},{"name":"client-unblock.json","type":"file"},{"name":"client-unpause.json","type":"file"},{"name":"client.json","type":"file"},{"name":"cluster-addslots.json","type":"file"},{"name":"cluster-addslotsrange.json","type":"file"},{"name":"cluster-bumpepoch.json","type":"file"},{"name":"cluster-count-failure-reports.json","type":"file"},{"name":"cluster-countkeysinslot.json","type":"file"},{"name":"cluster-delslots.json","type":"file"},{"name":"cluster-delslotsrange.json","type":"file"},{"name":"cluster-failover.json","type":"file"},{"name":"cluster-flushslots.json","type":"file"},{"name":"cluster-forget.json","type":"file"},{"name":"cluster-getkeysinslot.json","type":"file"},{"name":"cluster-help.json","type":"file"},{"name":"cluster-info.json","type":"file"},{"name":"cluster-keyslot.json","type":"file"},{"name":"cluster-links.json","type":"file"},{"name":"cluster-meet.json","type":"file"},{"name":"cluster-migration.json","type":"file"},{"name":"cluster-myid.json","type":"file"},{"name":"cluster-myshardid.json","type":"file"},{"name":"cluster-nodes.json","type":"file"},{"name":"cluster-replicas.json","type":"file"},{"name":"cluster-replicate.json","type":"file"},{"name":"cluster-reset.json","type":"file"},{"name":"cluster-saveconfig.json","type":"file"},{"name":"cluster-set-config-epoch.json","type":"file"},{"name":"cluster-setslot.json","type":"file"},{"name":"cluster-shards.json","type":"file"},{"name":"cluster-slaves.json","type":"file"},{"name":"cluster-slot-stats.json","type":"file"},{"name":"cluster-slots.json","type":"file"},{"name":"cluster-syncslots.json","type":"file"},{"name":"cluster.json","type":"file"},{"name":"command-count.json","type":"file"},{"name":"command-docs.json","type":"file"},{"name":"command-getkeys.json","type":"file"},{"name":"command-getkeysandflags.json","type":"file"},{"name":"command-help.json","type":"file"},{"name":"command-info.json","type":"file"},{"name":"command-list.json","type":"file"},{"name":"command.json","type":"file"},{"name":"config-get.json","type":"file"},{"name":"config-help.json","type":"file"},{"name":"config-resetstat.json","type":"file"},{"name":"config-rewrite.json","type":"file"},{"name":"config-set.json","type":"file"},{"name":"config.json","type":"file"},{"name":"copy.json","type":"file"},{"name":"dbsize.json","type":"file"},{"name":"debug.json","type":"file"},{"name":"decr.json","type":"file"},{"name":"decrby.json","type":"file"},{"name":"del.json","type":"file"},{"name":"delex.json","type":"file"},{"name":"digest.json","type":"file"},{"name":"discard.json","type":"file"},{"name":"dump.json","type":"file"},{"name":"echo.json","type":"file"},{"name":"eval.json","type":"file"},{"name":"eval_ro.json","type":"file"},{"name":"evalsha.json","type":"file"},{"name":"evalsha_ro.json","type":"file"},{"name":"exec.json","type":"file"},{"name":"exists.json","type":"file"},{"name":"expire.json","type":"file"},{"name":"expireat.json","type":"file"},{"name":"expiretime.json","type":"file"},{"name":"failover.json","type":"file"},{"name":"fcall.json","type":"file"},{"name":"fcall_ro.json","type":"file"},{"name":"flushall.json","type":"file"},{"name":"flushdb.json","type":"file"},{"name":"function-delete.json","type":"file"},{"name":"function-dump.json","type":"file"},{"name":"function-flush.json","type":"file"},{"name":"function-help.json","type":"file"},{"name":"function-kill.json","type":"file"},{"name":"function-list.json","type":"file"},{"name":"function-load.json","type":"file"},{"name":"function-restore.json","type":"file"},{"name":"function-stats.json","type":"file"},{"name":"function.json","type":"file"},{"name":"geoadd.json","type":"file"},{"name":"geodist.json","type":"file"},{"name":"geohash.json","type":"file"},{"name":"geopos.json","type":"file"},{"name":"georadius.json","type":"file"},{"name":"georadius_ro.json","type":"file"},{"name":"georadiusbymember.json","type":"file"},{"name":"georadiusbymember_ro.json","type":"file"},{"name":"geosearch.json","type":"file"},{"name":"geosearchstore.json","type":"file"},{"name":"get.json","type":"file"},{"name":"getbit.json","type":"file"},{"name":"getdel.json","type":"file"},{"name":"getex.json","type":"file"},{"name":"getrange.json","type":"file"},{"name":"getset.json","type":"file"},{"name":"hdel.json","type":"file"},{"name":"hello.json","type":"file"},{"name":"hexists.json","type":"file"},{"name":"hexpire.json","type":"file"},{"name":"hexpireat.json","type":"file"},{"name":"hexpiretime.json","type":"file"},{"name":"hget.json","type":"file"},{"name":"hgetall.json","type":"file"},{"name":"hgetdel.json","type":"file"},{"name":"hgetex.json","type":"file"},{"name":"himport-discard.json","type":"file"},{"name":"himport-discardall.json","type":"file"},{"name":"himport-prepare.json","type":"file"},{"name":"himport-set.json","type":"file"},{"name":"himport.json","type":"file"},{"name":"hincrby.json","type":"file"},{"name":"hincrbyfloat.json","type":"file"},{"name":"hkeys.json","type":"file"},{"name":"hlen.json","type":"file"},{"name":"hmget.json","type":"file"},{"name":"hmset.json","type":"file"},{"name":"hotkeys-get.json","type":"file"},{"name":"hotkeys-help.json","type":"file"},{"name":"hotkeys-reset.json","type":"file"},{"name":"hotkeys-start.json","type":"file"},{"name":"hotkeys-stop.json","type":"file"},{"name":"hotkeys.json","type":"file"},{"name":"hpersist.json","type":"file"},{"name":"hpexpire.json","type":"file"},{"name":"hpexpireat.json","type":"file"},{"name":"hpexpiretime.json","type":"file"},{"name":"hpttl.json","type":"file"},{"name":"hrandfield.json","type":"file"},{"name":"hscan.json","type":"file"},{"name":"hset.json","type":"file"},{"name":"hsetex.json","type":"file"},{"name":"hsetnx.json","type":"file"},{"name":"hstrlen.json","type":"file"},{"name":"httl.json","type":"file"},{"name":"hvals.json","type":"file"},{"name":"incr.json","type":"file"},{"name":"incrby.json","type":"file"},{"name":"incrbyfloat.json","type":"file"},{"name":"increx.json","type":"file"},{"name":"info.json","type":"file"},{"name":"keys.json","type":"file"},{"name":"lastsave.json","type":"file"},{"name":"latency-doctor.json","type":"file"},{"name":"latency-graph.json","type":"file"},{"name":"latency-help.json","type":"file"},{"name":"latency-histogram.json","type":"file"},{"name":"latency-history.json","type":"file"},{"name":"latency-latest.json","type":"file"},{"name":"latency-reset.json","type":"file"},{"name":"latency.json","type":"file"},{"name":"lcs.json","type":"file"},{"name":"lindex.json","type":"file"},{"name":"linsert.json","type":"file"},{"name":"llen.json","type":"file"},{"name":"lmove.json","type":"file"},{"name":"lmovem.json","type":"file"},{"name":"lmpop.json","type":"file"},{"name":"lolwut.json","type":"file"},{"name":"lpop.json","type":"file"},{"name":"lpos.json","type":"file"},{"name":"lpush.json","type":"file"},{"name":"lpushx.json","type":"file"},{"name":"lrange.json","type":"file"},{"name":"lrem.json","type":"file"},{"name":"lset.json","type":"file"},{"name":"ltrim.json","type":"file"},{"name":"memory-doctor.json","type":"file"},{"name":"memory-help.json","type":"file"},{"name":"memory-malloc-stats.json","type":"file"},{"name":"memory-purge.json","type":"file"},{"name":"memory-stats.json","type":"file"},{"name":"memory-usage.json","type":"file"},{"name":"memory.json","type":"file"},{"name":"mget.json","type":"file"},{"name":"migrate.json","type":"file"},{"name":"module-help.json","type":"file"},{"name":"module-list.json","type":"file"},{"name":"module-load.json","type":"file"},{"name":"module-loadex.json","type":"file"},{"name":"module-unload.json","type":"file"},{"name":"module.json","type":"file"},{"name":"monitor.json","type":"file"},{"name":"move.json","type":"file"},{"name":"mset.json","type":"file"},{"name":"msetex.json","type":"file"},{"name":"msetnx.json","type":"file"},{"name":"multi.json","type":"file"},{"name":"object-encoding.json","type":"file"},{"name":"object-freq.json","type":"file"},{"name":"object-help.json","type":"file"},{"name":"object-idletime.json","type":"file"},{"name":"object-refcount.json","type":"file"},{"name":"object.json","type":"file"},{"name":"persist.json","type":"file"},{"name":"pexpire.json","type":"file"},{"name":"pexpireat.json","type":"file"},{"name":"pexpiretime.json","type":"file"},{"name":"pfadd.json","type":"file"},{"name":"pfcount.json","type":"file"},{"name":"pfdebug.json","type":"file"},{"name":"pfmerge.json","type":"file"},{"name":"pfselftest.json","type":"file"},{"name":"ping.json","type":"file"},{"name":"psetex.json","type":"file"},{"name":"psubscribe.json","type":"file"},{"name":"psync.json","type":"file"},{"name":"pttl.json","type":"file"},{"name":"publish.json","type":"file"},{"name":"pubsub-channels.json","type":"file"},{"name":"pubsub-help.json","type":"file"},{"name":"pubsub-numpat.json","type":"file"},{"name":"pubsub-numsub.json","type":"file"},{"name":"pubsub-shardchannels.json","type":"file"},{"name":"pubsub-shardnumsub.json","type":"file"},{"name":"pubsub.json","type":"file"},{"name":"punsubscribe.json","type":"file"},{"name":"quit.json","type":"file"},{"name":"randomkey.json","type":"file"},{"name":"readonly.json","type":"file"},{"name":"readwrite.json","type":"file"},{"name":"rename.json","type":"file"},{"name":"renamenx.json","type":"file"},{"name":"replconf.json","type":"file"},{"name":"replicaof.json","type":"file"},{"name":"reset.json","type":"file"},{"name":"restore-asking.json","type":"file"},{"name":"restore.json","type":"file"},{"name":"role.json","type":"file"},{"name":"rpop.json","type":"file"},{"name":"rpoplpush.json","type":"file"},{"name":"rpush.json","type":"file"},{"name":"rpushx.json","type":"file"},{"name":"sadd.json","type":"file"},{"name":"save.json","type":"file"},{"name":"scan.json","type":"file"},{"name":"scard.json","type":"file"},{"name":"script-debug.json","type":"file"},{"name":"script-exists.json","type":"file"},{"name":"script-flush.json","type":"file"},{"name":"script-help.json","type":"file"},{"name":"script-kill.json","type":"file"},{"name":"script-load.json","type":"file"},{"name":"script.json","type":"file"},{"name":"sdiff.json","type":"file"},{"name":"sdiffcard.json","type":"file"},{"name":"sdiffstore.json","type":"file"},{"name":"select.json","type":"file"},{"name":"sentinel-ckquorum.json","type":"file"},{"name":"sentinel-config.json","type":"file"},{"name":"sentinel-debug.json","type":"file"},{"name":"sentinel-failover.json","type":"file"},{"name":"sentinel-flushconfig.json","type":"file"},{"name":"sentinel-get-master-addr-by-name.json","type":"file"},{"name":"sentinel-help.json","type":"file"},{"name":"sentinel-info-cache.json","type":"file"},{"name":"sentinel-is-master-down-by-addr.json","type":"file"},{"name":"sentinel-master.json","type":"file"},{"name":"sentinel-masters.json","type":"file"},{"name":"sentinel-monitor.json","type":"file"},{"name":"sentinel-myid.json","type":"file"},{"name":"sentinel-pending-scripts.json","type":"file"},{"name":"sentinel-remove.json","type":"file"},{"name":"sentinel-replicas.json","type":"file"},{"name":"sentinel-reset.json","type":"file"},{"name":"sentinel-sentinels.json","type":"file"},{"name":"sentinel-set.json","type":"file"},{"name":"sentinel-simulate-failure.json","type":"file"},{"name":"sentinel-slaves.json","type":"file"},{"name":"sentinel.json","type":"file"},{"name":"set.json","type":"file"},{"name":"setbit.json","type":"file"},{"name":"setex.json","type":"file"},{"name":"setnx.json","type":"file"},{"name":"setrange.json","type":"file"},{"name":"sflush.json","type":"file"},{"name":"shutdown.json","type":"file"},{"name":"sinter.json","type":"file"},{"name":"sintercard.json","type":"file"},{"name":"sinterstore.json","type":"file"},{"name":"sismember.json","type":"file"},{"name":"slaveof.json","type":"file"},{"name":"slowlog-get.json","type":"file"},{"name":"slowlog-help.json","type":"file"},{"name":"slowlog-len.json","type":"file"},{"name":"slowlog-reset.json","type":"file"},{"name":"slowlog.json","type":"file"},{"name":"smembers.json","type":"file"},{"name":"smismember.json","type":"file"},{"name":"smove.json","type":"file"},{"name":"sort.json","type":"file"},{"name":"sort_ro.json","type":"file"},{"name":"spop.json","type":"file"},{"name":"spublish.json","type":"file"},{"name":"srandmember.json","type":"file"},{"name":"srem.json","type":"file"},{"name":"sscan.json","type":"file"},{"name":"ssubscribe.json","type":"file"},{"name":"strlen.json","type":"file"},{"name":"subscribe.json","type":"file"},{"name":"substr.json","type":"file"},{"name":"sunion.json","type":"file"},{"name":"sunioncard.json","type":"file"},{"name":"sunionstore.json","type":"file"},{"name":"sunsubscribe.json","type":"file"},{"name":"swapdb.json","type":"file"},{"name":"sync.json","type":"file"},{"name":"time.json","type":"file"},{"name":"touch.json","type":"file"},{"name":"trimslots.json","type":"file"},{"name":"ttl.json","type":"file"},{"name":"type.json","type":"file"},{"name":"unlink.json","type":"file"},{"name":"unsubscribe.json","type":"file"},{"name":"unwatch.json","type":"file"},{"name":"wait.json","type":"file"},{"name":"waitaof.json","type":"file"},{"name":"watch.json","type":"file"},{"name":"xack.json","type":"file"},{"name":"xackdel.json","type":"file"},{"name":"xadd.json","type":"file"},{"name":"xautoclaim.json","type":"file"},{"name":"xcfgset.json","type":"file"},{"name":"xclaim.json","type":"file"},{"name":"xdel.json","type":"file"},{"name":"xdelex.json","type":"file"},{"name":"xgroup-create.json","type":"file"},{"name":"xgroup-createconsumer.json","type":"file"},{"name":"xgroup-delconsumer.json","type":"file"},{"name":"xgroup-destroy.json","type":"file"},{"name":"xgroup-help.json","type":"file"},{"name":"xgroup-setid.json","type":"file"},{"name":"xgroup.json","type":"file"},{"name":"xidmprecord.json","type":"file"},{"name":"xinfo-consumers.json","type":"file"},{"name":"xinfo-groups.json","type":"file"},{"name":"xinfo-help.json","type":"file"},{"name":"xinfo-stream.json","type":"file"},{"name":"xinfo.json","type":"file"},{"name":"xlen.json","type":"file"},{"name":"xnack.json","type":"file"},{"name":"xpending.json","type":"file"},{"name":"xrange.json","type":"file"},{"name":"xread.json","type":"file"},{"name":"xreadgroup.json","type":"file"},{"name":"xrevrange.json","type":"file"},{"name":"xsetid.json","type":"file"},{"name":"xtrim.json","type":"file"},{"name":"zadd.json","type":"file"},{"name":"zcard.json","type":"file"},{"name":"zcount.json","type":"file"},{"name":"zdiff.json","type":"file"},{"name":"zdiffstore.json","type":"file"},{"name":"zincrby.json","type":"file"},{"name":"zinter.json","type":"file"},{"name":"zintercard.json","type":"file"},{"name":"zinterstore.json","type":"file"},{"name":"zlexcount.json","type":"file"},{"name":"zmpop.json","type":"file"},{"name":"zmscore.json","type":"file"},{"name":"zpopmax.json","type":"file"},{"name":"zpopmin.json","type":"file"},{"name":"zrandmember.json","type":"file"},{"name":"zrange.json","type":"file"},{"name":"zrangebylex.json","type":"file"},{"name":"zrangebyscore.json","type":"file"},{"name":"zrangestore.json","type":"file"},{"name":"zrank.json","type":"file"},{"name":"zrem.json","type":"file"},{"name":"zremrangebylex.json","type":"file"},{"name":"zremrangebyrank.json","type":"file"},{"name":"zremrangebyscore.json","type":"file"},{"name":"zrevrange.json","type":"file"},{"name":"zrevrangebylex.json","type":"file"},{"name":"zrevrangebyscore.json","type":"file"},{"name":"zrevrank.json","type":"file"},{"name":"zscan.json","type":"file"},{"name":"zscore.json","type":"file"},{"name":"zunion.json","type":"file"},{"name":"zunionstore.json","type":"file"}] diff --git a/plugins/catalog/testdata/redis-contents-src-commands-8.8-m03.json b/plugins/catalog/testdata/redis-contents-src-commands-8.8-m03.json new file mode 100644 index 0000000..2e9a1c1 --- /dev/null +++ b/plugins/catalog/testdata/redis-contents-src-commands-8.8-m03.json @@ -0,0 +1 @@ +[{"name":"README.md","type":"file"},{"name":"acl-cat.json","type":"file"},{"name":"acl-deluser.json","type":"file"},{"name":"acl-dryrun.json","type":"file"},{"name":"acl-genpass.json","type":"file"},{"name":"acl-getuser.json","type":"file"},{"name":"acl-help.json","type":"file"},{"name":"acl-list.json","type":"file"},{"name":"acl-load.json","type":"file"},{"name":"acl-log.json","type":"file"},{"name":"acl-save.json","type":"file"},{"name":"acl-setuser.json","type":"file"},{"name":"acl-users.json","type":"file"},{"name":"acl-whoami.json","type":"file"},{"name":"acl.json","type":"file"},{"name":"append.json","type":"file"},{"name":"asking.json","type":"file"},{"name":"auth.json","type":"file"},{"name":"bgrewriteaof.json","type":"file"},{"name":"bgsave.json","type":"file"},{"name":"bitcount.json","type":"file"},{"name":"bitfield.json","type":"file"},{"name":"bitfield_ro.json","type":"file"},{"name":"bitop.json","type":"file"},{"name":"bitpos.json","type":"file"},{"name":"blmove.json","type":"file"},{"name":"blmpop.json","type":"file"},{"name":"blpop.json","type":"file"},{"name":"brpop.json","type":"file"},{"name":"brpoplpush.json","type":"file"},{"name":"bzmpop.json","type":"file"},{"name":"bzpopmax.json","type":"file"},{"name":"bzpopmin.json","type":"file"},{"name":"client-caching.json","type":"file"},{"name":"client-getname.json","type":"file"},{"name":"client-getredir.json","type":"file"},{"name":"client-help.json","type":"file"},{"name":"client-id.json","type":"file"},{"name":"client-info.json","type":"file"},{"name":"client-kill.json","type":"file"},{"name":"client-list.json","type":"file"},{"name":"client-no-evict.json","type":"file"},{"name":"client-no-touch.json","type":"file"},{"name":"client-pause.json","type":"file"},{"name":"client-reply.json","type":"file"},{"name":"client-setinfo.json","type":"file"},{"name":"client-setname.json","type":"file"},{"name":"client-tracking.json","type":"file"},{"name":"client-trackinginfo.json","type":"file"},{"name":"client-unblock.json","type":"file"},{"name":"client-unpause.json","type":"file"},{"name":"client.json","type":"file"},{"name":"cluster-addslots.json","type":"file"},{"name":"cluster-addslotsrange.json","type":"file"},{"name":"cluster-bumpepoch.json","type":"file"},{"name":"cluster-count-failure-reports.json","type":"file"},{"name":"cluster-countkeysinslot.json","type":"file"},{"name":"cluster-delslots.json","type":"file"},{"name":"cluster-delslotsrange.json","type":"file"},{"name":"cluster-failover.json","type":"file"},{"name":"cluster-flushslots.json","type":"file"},{"name":"cluster-forget.json","type":"file"},{"name":"cluster-getkeysinslot.json","type":"file"},{"name":"cluster-help.json","type":"file"},{"name":"cluster-info.json","type":"file"},{"name":"cluster-keyslot.json","type":"file"},{"name":"cluster-links.json","type":"file"},{"name":"cluster-meet.json","type":"file"},{"name":"cluster-migration.json","type":"file"},{"name":"cluster-myid.json","type":"file"},{"name":"cluster-myshardid.json","type":"file"},{"name":"cluster-nodes.json","type":"file"},{"name":"cluster-replicas.json","type":"file"},{"name":"cluster-replicate.json","type":"file"},{"name":"cluster-reset.json","type":"file"},{"name":"cluster-saveconfig.json","type":"file"},{"name":"cluster-set-config-epoch.json","type":"file"},{"name":"cluster-setslot.json","type":"file"},{"name":"cluster-shards.json","type":"file"},{"name":"cluster-slaves.json","type":"file"},{"name":"cluster-slot-stats.json","type":"file"},{"name":"cluster-slots.json","type":"file"},{"name":"cluster-syncslots.json","type":"file"},{"name":"cluster.json","type":"file"},{"name":"command-count.json","type":"file"},{"name":"command-docs.json","type":"file"},{"name":"command-getkeys.json","type":"file"},{"name":"command-getkeysandflags.json","type":"file"},{"name":"command-help.json","type":"file"},{"name":"command-info.json","type":"file"},{"name":"command-list.json","type":"file"},{"name":"command.json","type":"file"},{"name":"config-get.json","type":"file"},{"name":"config-help.json","type":"file"},{"name":"config-resetstat.json","type":"file"},{"name":"config-rewrite.json","type":"file"},{"name":"config-set.json","type":"file"},{"name":"config.json","type":"file"},{"name":"copy.json","type":"file"},{"name":"dbsize.json","type":"file"},{"name":"debug.json","type":"file"},{"name":"decr.json","type":"file"},{"name":"decrby.json","type":"file"},{"name":"del.json","type":"file"},{"name":"delex.json","type":"file"},{"name":"digest.json","type":"file"},{"name":"discard.json","type":"file"},{"name":"dump.json","type":"file"},{"name":"echo.json","type":"file"},{"name":"eval.json","type":"file"},{"name":"eval_ro.json","type":"file"},{"name":"evalsha.json","type":"file"},{"name":"evalsha_ro.json","type":"file"},{"name":"exec.json","type":"file"},{"name":"exists.json","type":"file"},{"name":"expire.json","type":"file"},{"name":"expireat.json","type":"file"},{"name":"expiretime.json","type":"file"},{"name":"failover.json","type":"file"},{"name":"fcall.json","type":"file"},{"name":"fcall_ro.json","type":"file"},{"name":"flushall.json","type":"file"},{"name":"flushdb.json","type":"file"},{"name":"function-delete.json","type":"file"},{"name":"function-dump.json","type":"file"},{"name":"function-flush.json","type":"file"},{"name":"function-help.json","type":"file"},{"name":"function-kill.json","type":"file"},{"name":"function-list.json","type":"file"},{"name":"function-load.json","type":"file"},{"name":"function-restore.json","type":"file"},{"name":"function-stats.json","type":"file"},{"name":"function.json","type":"file"},{"name":"gcra.json","type":"file"},{"name":"gcrasetvalue.json","type":"file"},{"name":"geoadd.json","type":"file"},{"name":"geodist.json","type":"file"},{"name":"geohash.json","type":"file"},{"name":"geopos.json","type":"file"},{"name":"georadius.json","type":"file"},{"name":"georadius_ro.json","type":"file"},{"name":"georadiusbymember.json","type":"file"},{"name":"georadiusbymember_ro.json","type":"file"},{"name":"geosearch.json","type":"file"},{"name":"geosearchstore.json","type":"file"},{"name":"get.json","type":"file"},{"name":"getbit.json","type":"file"},{"name":"getdel.json","type":"file"},{"name":"getex.json","type":"file"},{"name":"getrange.json","type":"file"},{"name":"getset.json","type":"file"},{"name":"hdel.json","type":"file"},{"name":"hello.json","type":"file"},{"name":"hexists.json","type":"file"},{"name":"hexpire.json","type":"file"},{"name":"hexpireat.json","type":"file"},{"name":"hexpiretime.json","type":"file"},{"name":"hget.json","type":"file"},{"name":"hgetall.json","type":"file"},{"name":"hgetdel.json","type":"file"},{"name":"hgetex.json","type":"file"},{"name":"hincrby.json","type":"file"},{"name":"hincrbyfloat.json","type":"file"},{"name":"hkeys.json","type":"file"},{"name":"hlen.json","type":"file"},{"name":"hmget.json","type":"file"},{"name":"hmset.json","type":"file"},{"name":"hotkeys-get.json","type":"file"},{"name":"hotkeys-help.json","type":"file"},{"name":"hotkeys-reset.json","type":"file"},{"name":"hotkeys-start.json","type":"file"},{"name":"hotkeys-stop.json","type":"file"},{"name":"hotkeys.json","type":"file"},{"name":"hpersist.json","type":"file"},{"name":"hpexpire.json","type":"file"},{"name":"hpexpireat.json","type":"file"},{"name":"hpexpiretime.json","type":"file"},{"name":"hpttl.json","type":"file"},{"name":"hrandfield.json","type":"file"},{"name":"hscan.json","type":"file"},{"name":"hset.json","type":"file"},{"name":"hsetex.json","type":"file"},{"name":"hsetnx.json","type":"file"},{"name":"hstrlen.json","type":"file"},{"name":"httl.json","type":"file"},{"name":"hvals.json","type":"file"},{"name":"incr.json","type":"file"},{"name":"incrby.json","type":"file"},{"name":"incrbyfloat.json","type":"file"},{"name":"info.json","type":"file"},{"name":"keys.json","type":"file"},{"name":"lastsave.json","type":"file"},{"name":"latency-doctor.json","type":"file"},{"name":"latency-graph.json","type":"file"},{"name":"latency-help.json","type":"file"},{"name":"latency-histogram.json","type":"file"},{"name":"latency-history.json","type":"file"},{"name":"latency-latest.json","type":"file"},{"name":"latency-reset.json","type":"file"},{"name":"latency.json","type":"file"},{"name":"lcs.json","type":"file"},{"name":"lindex.json","type":"file"},{"name":"linsert.json","type":"file"},{"name":"llen.json","type":"file"},{"name":"lmove.json","type":"file"},{"name":"lmpop.json","type":"file"},{"name":"lolwut.json","type":"file"},{"name":"lpop.json","type":"file"},{"name":"lpos.json","type":"file"},{"name":"lpush.json","type":"file"},{"name":"lpushx.json","type":"file"},{"name":"lrange.json","type":"file"},{"name":"lrem.json","type":"file"},{"name":"lset.json","type":"file"},{"name":"ltrim.json","type":"file"},{"name":"memory-doctor.json","type":"file"},{"name":"memory-help.json","type":"file"},{"name":"memory-malloc-stats.json","type":"file"},{"name":"memory-purge.json","type":"file"},{"name":"memory-stats.json","type":"file"},{"name":"memory-usage.json","type":"file"},{"name":"memory.json","type":"file"},{"name":"mget.json","type":"file"},{"name":"migrate.json","type":"file"},{"name":"module-help.json","type":"file"},{"name":"module-list.json","type":"file"},{"name":"module-load.json","type":"file"},{"name":"module-loadex.json","type":"file"},{"name":"module-unload.json","type":"file"},{"name":"module.json","type":"file"},{"name":"monitor.json","type":"file"},{"name":"move.json","type":"file"},{"name":"mset.json","type":"file"},{"name":"msetex.json","type":"file"},{"name":"msetnx.json","type":"file"},{"name":"multi.json","type":"file"},{"name":"object-encoding.json","type":"file"},{"name":"object-freq.json","type":"file"},{"name":"object-help.json","type":"file"},{"name":"object-idletime.json","type":"file"},{"name":"object-refcount.json","type":"file"},{"name":"object.json","type":"file"},{"name":"persist.json","type":"file"},{"name":"pexpire.json","type":"file"},{"name":"pexpireat.json","type":"file"},{"name":"pexpiretime.json","type":"file"},{"name":"pfadd.json","type":"file"},{"name":"pfcount.json","type":"file"},{"name":"pfdebug.json","type":"file"},{"name":"pfmerge.json","type":"file"},{"name":"pfselftest.json","type":"file"},{"name":"ping.json","type":"file"},{"name":"psetex.json","type":"file"},{"name":"psubscribe.json","type":"file"},{"name":"psync.json","type":"file"},{"name":"pttl.json","type":"file"},{"name":"publish.json","type":"file"},{"name":"pubsub-channels.json","type":"file"},{"name":"pubsub-help.json","type":"file"},{"name":"pubsub-numpat.json","type":"file"},{"name":"pubsub-numsub.json","type":"file"},{"name":"pubsub-shardchannels.json","type":"file"},{"name":"pubsub-shardnumsub.json","type":"file"},{"name":"pubsub.json","type":"file"},{"name":"punsubscribe.json","type":"file"},{"name":"quit.json","type":"file"},{"name":"randomkey.json","type":"file"},{"name":"readonly.json","type":"file"},{"name":"readwrite.json","type":"file"},{"name":"rename.json","type":"file"},{"name":"renamenx.json","type":"file"},{"name":"replconf.json","type":"file"},{"name":"replicaof.json","type":"file"},{"name":"reset.json","type":"file"},{"name":"restore-asking.json","type":"file"},{"name":"restore.json","type":"file"},{"name":"role.json","type":"file"},{"name":"rpop.json","type":"file"},{"name":"rpoplpush.json","type":"file"},{"name":"rpush.json","type":"file"},{"name":"rpushx.json","type":"file"},{"name":"sadd.json","type":"file"},{"name":"save.json","type":"file"},{"name":"scan.json","type":"file"},{"name":"scard.json","type":"file"},{"name":"script-debug.json","type":"file"},{"name":"script-exists.json","type":"file"},{"name":"script-flush.json","type":"file"},{"name":"script-help.json","type":"file"},{"name":"script-kill.json","type":"file"},{"name":"script-load.json","type":"file"},{"name":"script.json","type":"file"},{"name":"sdiff.json","type":"file"},{"name":"sdiffstore.json","type":"file"},{"name":"select.json","type":"file"},{"name":"sentinel-ckquorum.json","type":"file"},{"name":"sentinel-config.json","type":"file"},{"name":"sentinel-debug.json","type":"file"},{"name":"sentinel-failover.json","type":"file"},{"name":"sentinel-flushconfig.json","type":"file"},{"name":"sentinel-get-master-addr-by-name.json","type":"file"},{"name":"sentinel-help.json","type":"file"},{"name":"sentinel-info-cache.json","type":"file"},{"name":"sentinel-is-master-down-by-addr.json","type":"file"},{"name":"sentinel-master.json","type":"file"},{"name":"sentinel-masters.json","type":"file"},{"name":"sentinel-monitor.json","type":"file"},{"name":"sentinel-myid.json","type":"file"},{"name":"sentinel-pending-scripts.json","type":"file"},{"name":"sentinel-remove.json","type":"file"},{"name":"sentinel-replicas.json","type":"file"},{"name":"sentinel-reset.json","type":"file"},{"name":"sentinel-sentinels.json","type":"file"},{"name":"sentinel-set.json","type":"file"},{"name":"sentinel-simulate-failure.json","type":"file"},{"name":"sentinel-slaves.json","type":"file"},{"name":"sentinel.json","type":"file"},{"name":"set.json","type":"file"},{"name":"setbit.json","type":"file"},{"name":"setex.json","type":"file"},{"name":"setnx.json","type":"file"},{"name":"setrange.json","type":"file"},{"name":"sflush.json","type":"file"},{"name":"shutdown.json","type":"file"},{"name":"sinter.json","type":"file"},{"name":"sintercard.json","type":"file"},{"name":"sinterstore.json","type":"file"},{"name":"sismember.json","type":"file"},{"name":"slaveof.json","type":"file"},{"name":"slowlog-get.json","type":"file"},{"name":"slowlog-help.json","type":"file"},{"name":"slowlog-len.json","type":"file"},{"name":"slowlog-reset.json","type":"file"},{"name":"slowlog.json","type":"file"},{"name":"smembers.json","type":"file"},{"name":"smismember.json","type":"file"},{"name":"smove.json","type":"file"},{"name":"sort.json","type":"file"},{"name":"sort_ro.json","type":"file"},{"name":"spop.json","type":"file"},{"name":"spublish.json","type":"file"},{"name":"srandmember.json","type":"file"},{"name":"srem.json","type":"file"},{"name":"sscan.json","type":"file"},{"name":"ssubscribe.json","type":"file"},{"name":"strlen.json","type":"file"},{"name":"subscribe.json","type":"file"},{"name":"substr.json","type":"file"},{"name":"sunion.json","type":"file"},{"name":"sunionstore.json","type":"file"},{"name":"sunsubscribe.json","type":"file"},{"name":"swapdb.json","type":"file"},{"name":"sync.json","type":"file"},{"name":"time.json","type":"file"},{"name":"touch.json","type":"file"},{"name":"trimslots.json","type":"file"},{"name":"ttl.json","type":"file"},{"name":"type.json","type":"file"},{"name":"unlink.json","type":"file"},{"name":"unsubscribe.json","type":"file"},{"name":"unwatch.json","type":"file"},{"name":"wait.json","type":"file"},{"name":"waitaof.json","type":"file"},{"name":"watch.json","type":"file"},{"name":"xack.json","type":"file"},{"name":"xackdel.json","type":"file"},{"name":"xadd.json","type":"file"},{"name":"xautoclaim.json","type":"file"},{"name":"xcfgset.json","type":"file"},{"name":"xclaim.json","type":"file"},{"name":"xdel.json","type":"file"},{"name":"xdelex.json","type":"file"},{"name":"xgroup-create.json","type":"file"},{"name":"xgroup-createconsumer.json","type":"file"},{"name":"xgroup-delconsumer.json","type":"file"},{"name":"xgroup-destroy.json","type":"file"},{"name":"xgroup-help.json","type":"file"},{"name":"xgroup-setid.json","type":"file"},{"name":"xgroup.json","type":"file"},{"name":"xidmprecord.json","type":"file"},{"name":"xinfo-consumers.json","type":"file"},{"name":"xinfo-groups.json","type":"file"},{"name":"xinfo-help.json","type":"file"},{"name":"xinfo-stream.json","type":"file"},{"name":"xinfo.json","type":"file"},{"name":"xlen.json","type":"file"},{"name":"xnack.json","type":"file"},{"name":"xpending.json","type":"file"},{"name":"xrange.json","type":"file"},{"name":"xread.json","type":"file"},{"name":"xreadgroup.json","type":"file"},{"name":"xrevrange.json","type":"file"},{"name":"xsetid.json","type":"file"},{"name":"xtrim.json","type":"file"},{"name":"zadd.json","type":"file"},{"name":"zcard.json","type":"file"},{"name":"zcount.json","type":"file"},{"name":"zdiff.json","type":"file"},{"name":"zdiffstore.json","type":"file"},{"name":"zincrby.json","type":"file"},{"name":"zinter.json","type":"file"},{"name":"zintercard.json","type":"file"},{"name":"zinterstore.json","type":"file"},{"name":"zlexcount.json","type":"file"},{"name":"zmpop.json","type":"file"},{"name":"zmscore.json","type":"file"},{"name":"zpopmax.json","type":"file"},{"name":"zpopmin.json","type":"file"},{"name":"zrandmember.json","type":"file"},{"name":"zrange.json","type":"file"},{"name":"zrangebylex.json","type":"file"},{"name":"zrangebyscore.json","type":"file"},{"name":"zrangestore.json","type":"file"},{"name":"zrank.json","type":"file"},{"name":"zrem.json","type":"file"},{"name":"zremrangebylex.json","type":"file"},{"name":"zremrangebyrank.json","type":"file"},{"name":"zremrangebyscore.json","type":"file"},{"name":"zrevrange.json","type":"file"},{"name":"zrevrangebylex.json","type":"file"},{"name":"zrevrangebyscore.json","type":"file"},{"name":"zrevrank.json","type":"file"},{"name":"zscan.json","type":"file"},{"name":"zscore.json","type":"file"},{"name":"zunion.json","type":"file"},{"name":"zunionstore.json","type":"file"}] diff --git a/plugins/catalog/testdata/redis-contents-src-commands-8.8-rc1.json b/plugins/catalog/testdata/redis-contents-src-commands-8.8-rc1.json new file mode 100644 index 0000000..d269361 --- /dev/null +++ b/plugins/catalog/testdata/redis-contents-src-commands-8.8-rc1.json @@ -0,0 +1 @@ +[{"name":"README.md","type":"file"},{"name":"acl-cat.json","type":"file"},{"name":"acl-deluser.json","type":"file"},{"name":"acl-dryrun.json","type":"file"},{"name":"acl-genpass.json","type":"file"},{"name":"acl-getuser.json","type":"file"},{"name":"acl-help.json","type":"file"},{"name":"acl-list.json","type":"file"},{"name":"acl-load.json","type":"file"},{"name":"acl-log.json","type":"file"},{"name":"acl-save.json","type":"file"},{"name":"acl-setuser.json","type":"file"},{"name":"acl-users.json","type":"file"},{"name":"acl-whoami.json","type":"file"},{"name":"acl.json","type":"file"},{"name":"append.json","type":"file"},{"name":"arcount.json","type":"file"},{"name":"ardel.json","type":"file"},{"name":"ardelrange.json","type":"file"},{"name":"arget.json","type":"file"},{"name":"argetrange.json","type":"file"},{"name":"argrep.json","type":"file"},{"name":"arinfo.json","type":"file"},{"name":"arinsert.json","type":"file"},{"name":"arlastitems.json","type":"file"},{"name":"arlen.json","type":"file"},{"name":"armget.json","type":"file"},{"name":"armset.json","type":"file"},{"name":"arnext.json","type":"file"},{"name":"arop.json","type":"file"},{"name":"arring.json","type":"file"},{"name":"arscan.json","type":"file"},{"name":"arseek.json","type":"file"},{"name":"arset.json","type":"file"},{"name":"asking.json","type":"file"},{"name":"auth.json","type":"file"},{"name":"bgrewriteaof.json","type":"file"},{"name":"bgsave.json","type":"file"},{"name":"bitcount.json","type":"file"},{"name":"bitfield.json","type":"file"},{"name":"bitfield_ro.json","type":"file"},{"name":"bitop.json","type":"file"},{"name":"bitpos.json","type":"file"},{"name":"blmove.json","type":"file"},{"name":"blmpop.json","type":"file"},{"name":"blpop.json","type":"file"},{"name":"brpop.json","type":"file"},{"name":"brpoplpush.json","type":"file"},{"name":"bzmpop.json","type":"file"},{"name":"bzpopmax.json","type":"file"},{"name":"bzpopmin.json","type":"file"},{"name":"client-caching.json","type":"file"},{"name":"client-getname.json","type":"file"},{"name":"client-getredir.json","type":"file"},{"name":"client-help.json","type":"file"},{"name":"client-id.json","type":"file"},{"name":"client-info.json","type":"file"},{"name":"client-kill.json","type":"file"},{"name":"client-list.json","type":"file"},{"name":"client-no-evict.json","type":"file"},{"name":"client-no-touch.json","type":"file"},{"name":"client-pause.json","type":"file"},{"name":"client-reply.json","type":"file"},{"name":"client-setinfo.json","type":"file"},{"name":"client-setname.json","type":"file"},{"name":"client-tracking.json","type":"file"},{"name":"client-trackinginfo.json","type":"file"},{"name":"client-unblock.json","type":"file"},{"name":"client-unpause.json","type":"file"},{"name":"client.json","type":"file"},{"name":"cluster-addslots.json","type":"file"},{"name":"cluster-addslotsrange.json","type":"file"},{"name":"cluster-bumpepoch.json","type":"file"},{"name":"cluster-count-failure-reports.json","type":"file"},{"name":"cluster-countkeysinslot.json","type":"file"},{"name":"cluster-delslots.json","type":"file"},{"name":"cluster-delslotsrange.json","type":"file"},{"name":"cluster-failover.json","type":"file"},{"name":"cluster-flushslots.json","type":"file"},{"name":"cluster-forget.json","type":"file"},{"name":"cluster-getkeysinslot.json","type":"file"},{"name":"cluster-help.json","type":"file"},{"name":"cluster-info.json","type":"file"},{"name":"cluster-keyslot.json","type":"file"},{"name":"cluster-links.json","type":"file"},{"name":"cluster-meet.json","type":"file"},{"name":"cluster-migration.json","type":"file"},{"name":"cluster-myid.json","type":"file"},{"name":"cluster-myshardid.json","type":"file"},{"name":"cluster-nodes.json","type":"file"},{"name":"cluster-replicas.json","type":"file"},{"name":"cluster-replicate.json","type":"file"},{"name":"cluster-reset.json","type":"file"},{"name":"cluster-saveconfig.json","type":"file"},{"name":"cluster-set-config-epoch.json","type":"file"},{"name":"cluster-setslot.json","type":"file"},{"name":"cluster-shards.json","type":"file"},{"name":"cluster-slaves.json","type":"file"},{"name":"cluster-slot-stats.json","type":"file"},{"name":"cluster-slots.json","type":"file"},{"name":"cluster-syncslots.json","type":"file"},{"name":"cluster.json","type":"file"},{"name":"command-count.json","type":"file"},{"name":"command-docs.json","type":"file"},{"name":"command-getkeys.json","type":"file"},{"name":"command-getkeysandflags.json","type":"file"},{"name":"command-help.json","type":"file"},{"name":"command-info.json","type":"file"},{"name":"command-list.json","type":"file"},{"name":"command.json","type":"file"},{"name":"config-get.json","type":"file"},{"name":"config-help.json","type":"file"},{"name":"config-resetstat.json","type":"file"},{"name":"config-rewrite.json","type":"file"},{"name":"config-set.json","type":"file"},{"name":"config.json","type":"file"},{"name":"copy.json","type":"file"},{"name":"dbsize.json","type":"file"},{"name":"debug.json","type":"file"},{"name":"decr.json","type":"file"},{"name":"decrby.json","type":"file"},{"name":"del.json","type":"file"},{"name":"delex.json","type":"file"},{"name":"digest.json","type":"file"},{"name":"discard.json","type":"file"},{"name":"dump.json","type":"file"},{"name":"echo.json","type":"file"},{"name":"eval.json","type":"file"},{"name":"eval_ro.json","type":"file"},{"name":"evalsha.json","type":"file"},{"name":"evalsha_ro.json","type":"file"},{"name":"exec.json","type":"file"},{"name":"exists.json","type":"file"},{"name":"expire.json","type":"file"},{"name":"expireat.json","type":"file"},{"name":"expiretime.json","type":"file"},{"name":"failover.json","type":"file"},{"name":"fcall.json","type":"file"},{"name":"fcall_ro.json","type":"file"},{"name":"flushall.json","type":"file"},{"name":"flushdb.json","type":"file"},{"name":"function-delete.json","type":"file"},{"name":"function-dump.json","type":"file"},{"name":"function-flush.json","type":"file"},{"name":"function-help.json","type":"file"},{"name":"function-kill.json","type":"file"},{"name":"function-list.json","type":"file"},{"name":"function-load.json","type":"file"},{"name":"function-restore.json","type":"file"},{"name":"function-stats.json","type":"file"},{"name":"function.json","type":"file"},{"name":"geoadd.json","type":"file"},{"name":"geodist.json","type":"file"},{"name":"geohash.json","type":"file"},{"name":"geopos.json","type":"file"},{"name":"georadius.json","type":"file"},{"name":"georadius_ro.json","type":"file"},{"name":"georadiusbymember.json","type":"file"},{"name":"georadiusbymember_ro.json","type":"file"},{"name":"geosearch.json","type":"file"},{"name":"geosearchstore.json","type":"file"},{"name":"get.json","type":"file"},{"name":"getbit.json","type":"file"},{"name":"getdel.json","type":"file"},{"name":"getex.json","type":"file"},{"name":"getrange.json","type":"file"},{"name":"getset.json","type":"file"},{"name":"hdel.json","type":"file"},{"name":"hello.json","type":"file"},{"name":"hexists.json","type":"file"},{"name":"hexpire.json","type":"file"},{"name":"hexpireat.json","type":"file"},{"name":"hexpiretime.json","type":"file"},{"name":"hget.json","type":"file"},{"name":"hgetall.json","type":"file"},{"name":"hgetdel.json","type":"file"},{"name":"hgetex.json","type":"file"},{"name":"hincrby.json","type":"file"},{"name":"hincrbyfloat.json","type":"file"},{"name":"hkeys.json","type":"file"},{"name":"hlen.json","type":"file"},{"name":"hmget.json","type":"file"},{"name":"hmset.json","type":"file"},{"name":"hotkeys-get.json","type":"file"},{"name":"hotkeys-help.json","type":"file"},{"name":"hotkeys-reset.json","type":"file"},{"name":"hotkeys-start.json","type":"file"},{"name":"hotkeys-stop.json","type":"file"},{"name":"hotkeys.json","type":"file"},{"name":"hpersist.json","type":"file"},{"name":"hpexpire.json","type":"file"},{"name":"hpexpireat.json","type":"file"},{"name":"hpexpiretime.json","type":"file"},{"name":"hpttl.json","type":"file"},{"name":"hrandfield.json","type":"file"},{"name":"hscan.json","type":"file"},{"name":"hset.json","type":"file"},{"name":"hsetex.json","type":"file"},{"name":"hsetnx.json","type":"file"},{"name":"hstrlen.json","type":"file"},{"name":"httl.json","type":"file"},{"name":"hvals.json","type":"file"},{"name":"incr.json","type":"file"},{"name":"incrby.json","type":"file"},{"name":"incrbyfloat.json","type":"file"},{"name":"increx.json","type":"file"},{"name":"info.json","type":"file"},{"name":"keys.json","type":"file"},{"name":"lastsave.json","type":"file"},{"name":"latency-doctor.json","type":"file"},{"name":"latency-graph.json","type":"file"},{"name":"latency-help.json","type":"file"},{"name":"latency-histogram.json","type":"file"},{"name":"latency-history.json","type":"file"},{"name":"latency-latest.json","type":"file"},{"name":"latency-reset.json","type":"file"},{"name":"latency.json","type":"file"},{"name":"lcs.json","type":"file"},{"name":"lindex.json","type":"file"},{"name":"linsert.json","type":"file"},{"name":"llen.json","type":"file"},{"name":"lmove.json","type":"file"},{"name":"lmpop.json","type":"file"},{"name":"lolwut.json","type":"file"},{"name":"lpop.json","type":"file"},{"name":"lpos.json","type":"file"},{"name":"lpush.json","type":"file"},{"name":"lpushx.json","type":"file"},{"name":"lrange.json","type":"file"},{"name":"lrem.json","type":"file"},{"name":"lset.json","type":"file"},{"name":"ltrim.json","type":"file"},{"name":"memory-doctor.json","type":"file"},{"name":"memory-help.json","type":"file"},{"name":"memory-malloc-stats.json","type":"file"},{"name":"memory-purge.json","type":"file"},{"name":"memory-stats.json","type":"file"},{"name":"memory-usage.json","type":"file"},{"name":"memory.json","type":"file"},{"name":"mget.json","type":"file"},{"name":"migrate.json","type":"file"},{"name":"module-help.json","type":"file"},{"name":"module-list.json","type":"file"},{"name":"module-load.json","type":"file"},{"name":"module-loadex.json","type":"file"},{"name":"module-unload.json","type":"file"},{"name":"module.json","type":"file"},{"name":"monitor.json","type":"file"},{"name":"move.json","type":"file"},{"name":"mset.json","type":"file"},{"name":"msetex.json","type":"file"},{"name":"msetnx.json","type":"file"},{"name":"multi.json","type":"file"},{"name":"object-encoding.json","type":"file"},{"name":"object-freq.json","type":"file"},{"name":"object-help.json","type":"file"},{"name":"object-idletime.json","type":"file"},{"name":"object-refcount.json","type":"file"},{"name":"object.json","type":"file"},{"name":"persist.json","type":"file"},{"name":"pexpire.json","type":"file"},{"name":"pexpireat.json","type":"file"},{"name":"pexpiretime.json","type":"file"},{"name":"pfadd.json","type":"file"},{"name":"pfcount.json","type":"file"},{"name":"pfdebug.json","type":"file"},{"name":"pfmerge.json","type":"file"},{"name":"pfselftest.json","type":"file"},{"name":"ping.json","type":"file"},{"name":"psetex.json","type":"file"},{"name":"psubscribe.json","type":"file"},{"name":"psync.json","type":"file"},{"name":"pttl.json","type":"file"},{"name":"publish.json","type":"file"},{"name":"pubsub-channels.json","type":"file"},{"name":"pubsub-help.json","type":"file"},{"name":"pubsub-numpat.json","type":"file"},{"name":"pubsub-numsub.json","type":"file"},{"name":"pubsub-shardchannels.json","type":"file"},{"name":"pubsub-shardnumsub.json","type":"file"},{"name":"pubsub.json","type":"file"},{"name":"punsubscribe.json","type":"file"},{"name":"quit.json","type":"file"},{"name":"randomkey.json","type":"file"},{"name":"readonly.json","type":"file"},{"name":"readwrite.json","type":"file"},{"name":"rename.json","type":"file"},{"name":"renamenx.json","type":"file"},{"name":"replconf.json","type":"file"},{"name":"replicaof.json","type":"file"},{"name":"reset.json","type":"file"},{"name":"restore-asking.json","type":"file"},{"name":"restore.json","type":"file"},{"name":"role.json","type":"file"},{"name":"rpop.json","type":"file"},{"name":"rpoplpush.json","type":"file"},{"name":"rpush.json","type":"file"},{"name":"rpushx.json","type":"file"},{"name":"sadd.json","type":"file"},{"name":"save.json","type":"file"},{"name":"scan.json","type":"file"},{"name":"scard.json","type":"file"},{"name":"script-debug.json","type":"file"},{"name":"script-exists.json","type":"file"},{"name":"script-flush.json","type":"file"},{"name":"script-help.json","type":"file"},{"name":"script-kill.json","type":"file"},{"name":"script-load.json","type":"file"},{"name":"script.json","type":"file"},{"name":"sdiff.json","type":"file"},{"name":"sdiffstore.json","type":"file"},{"name":"select.json","type":"file"},{"name":"sentinel-ckquorum.json","type":"file"},{"name":"sentinel-config.json","type":"file"},{"name":"sentinel-debug.json","type":"file"},{"name":"sentinel-failover.json","type":"file"},{"name":"sentinel-flushconfig.json","type":"file"},{"name":"sentinel-get-master-addr-by-name.json","type":"file"},{"name":"sentinel-help.json","type":"file"},{"name":"sentinel-info-cache.json","type":"file"},{"name":"sentinel-is-master-down-by-addr.json","type":"file"},{"name":"sentinel-master.json","type":"file"},{"name":"sentinel-masters.json","type":"file"},{"name":"sentinel-monitor.json","type":"file"},{"name":"sentinel-myid.json","type":"file"},{"name":"sentinel-pending-scripts.json","type":"file"},{"name":"sentinel-remove.json","type":"file"},{"name":"sentinel-replicas.json","type":"file"},{"name":"sentinel-reset.json","type":"file"},{"name":"sentinel-sentinels.json","type":"file"},{"name":"sentinel-set.json","type":"file"},{"name":"sentinel-simulate-failure.json","type":"file"},{"name":"sentinel-slaves.json","type":"file"},{"name":"sentinel.json","type":"file"},{"name":"set.json","type":"file"},{"name":"setbit.json","type":"file"},{"name":"setex.json","type":"file"},{"name":"setnx.json","type":"file"},{"name":"setrange.json","type":"file"},{"name":"sflush.json","type":"file"},{"name":"shutdown.json","type":"file"},{"name":"sinter.json","type":"file"},{"name":"sintercard.json","type":"file"},{"name":"sinterstore.json","type":"file"},{"name":"sismember.json","type":"file"},{"name":"slaveof.json","type":"file"},{"name":"slowlog-get.json","type":"file"},{"name":"slowlog-help.json","type":"file"},{"name":"slowlog-len.json","type":"file"},{"name":"slowlog-reset.json","type":"file"},{"name":"slowlog.json","type":"file"},{"name":"smembers.json","type":"file"},{"name":"smismember.json","type":"file"},{"name":"smove.json","type":"file"},{"name":"sort.json","type":"file"},{"name":"sort_ro.json","type":"file"},{"name":"spop.json","type":"file"},{"name":"spublish.json","type":"file"},{"name":"srandmember.json","type":"file"},{"name":"srem.json","type":"file"},{"name":"sscan.json","type":"file"},{"name":"ssubscribe.json","type":"file"},{"name":"strlen.json","type":"file"},{"name":"subscribe.json","type":"file"},{"name":"substr.json","type":"file"},{"name":"sunion.json","type":"file"},{"name":"sunionstore.json","type":"file"},{"name":"sunsubscribe.json","type":"file"},{"name":"swapdb.json","type":"file"},{"name":"sync.json","type":"file"},{"name":"time.json","type":"file"},{"name":"touch.json","type":"file"},{"name":"trimslots.json","type":"file"},{"name":"ttl.json","type":"file"},{"name":"type.json","type":"file"},{"name":"unlink.json","type":"file"},{"name":"unsubscribe.json","type":"file"},{"name":"unwatch.json","type":"file"},{"name":"wait.json","type":"file"},{"name":"waitaof.json","type":"file"},{"name":"watch.json","type":"file"},{"name":"xack.json","type":"file"},{"name":"xackdel.json","type":"file"},{"name":"xadd.json","type":"file"},{"name":"xautoclaim.json","type":"file"},{"name":"xcfgset.json","type":"file"},{"name":"xclaim.json","type":"file"},{"name":"xdel.json","type":"file"},{"name":"xdelex.json","type":"file"},{"name":"xgroup-create.json","type":"file"},{"name":"xgroup-createconsumer.json","type":"file"},{"name":"xgroup-delconsumer.json","type":"file"},{"name":"xgroup-destroy.json","type":"file"},{"name":"xgroup-help.json","type":"file"},{"name":"xgroup-setid.json","type":"file"},{"name":"xgroup.json","type":"file"},{"name":"xidmprecord.json","type":"file"},{"name":"xinfo-consumers.json","type":"file"},{"name":"xinfo-groups.json","type":"file"},{"name":"xinfo-help.json","type":"file"},{"name":"xinfo-stream.json","type":"file"},{"name":"xinfo.json","type":"file"},{"name":"xlen.json","type":"file"},{"name":"xnack.json","type":"file"},{"name":"xpending.json","type":"file"},{"name":"xrange.json","type":"file"},{"name":"xread.json","type":"file"},{"name":"xreadgroup.json","type":"file"},{"name":"xrevrange.json","type":"file"},{"name":"xsetid.json","type":"file"},{"name":"xtrim.json","type":"file"},{"name":"zadd.json","type":"file"},{"name":"zcard.json","type":"file"},{"name":"zcount.json","type":"file"},{"name":"zdiff.json","type":"file"},{"name":"zdiffstore.json","type":"file"},{"name":"zincrby.json","type":"file"},{"name":"zinter.json","type":"file"},{"name":"zintercard.json","type":"file"},{"name":"zinterstore.json","type":"file"},{"name":"zlexcount.json","type":"file"},{"name":"zmpop.json","type":"file"},{"name":"zmscore.json","type":"file"},{"name":"zpopmax.json","type":"file"},{"name":"zpopmin.json","type":"file"},{"name":"zrandmember.json","type":"file"},{"name":"zrange.json","type":"file"},{"name":"zrangebylex.json","type":"file"},{"name":"zrangebyscore.json","type":"file"},{"name":"zrangestore.json","type":"file"},{"name":"zrank.json","type":"file"},{"name":"zrem.json","type":"file"},{"name":"zremrangebylex.json","type":"file"},{"name":"zremrangebyrank.json","type":"file"},{"name":"zremrangebyscore.json","type":"file"},{"name":"zrevrange.json","type":"file"},{"name":"zrevrangebylex.json","type":"file"},{"name":"zrevrangebyscore.json","type":"file"},{"name":"zrevrank.json","type":"file"},{"name":"zscan.json","type":"file"},{"name":"zscore.json","type":"file"},{"name":"zunion.json","type":"file"},{"name":"zunionstore.json","type":"file"}] diff --git a/plugins/catalog/testdata/redis-contents-src-commands-8.8.0.json b/plugins/catalog/testdata/redis-contents-src-commands-8.8.0.json new file mode 100644 index 0000000..d269361 --- /dev/null +++ b/plugins/catalog/testdata/redis-contents-src-commands-8.8.0.json @@ -0,0 +1 @@ +[{"name":"README.md","type":"file"},{"name":"acl-cat.json","type":"file"},{"name":"acl-deluser.json","type":"file"},{"name":"acl-dryrun.json","type":"file"},{"name":"acl-genpass.json","type":"file"},{"name":"acl-getuser.json","type":"file"},{"name":"acl-help.json","type":"file"},{"name":"acl-list.json","type":"file"},{"name":"acl-load.json","type":"file"},{"name":"acl-log.json","type":"file"},{"name":"acl-save.json","type":"file"},{"name":"acl-setuser.json","type":"file"},{"name":"acl-users.json","type":"file"},{"name":"acl-whoami.json","type":"file"},{"name":"acl.json","type":"file"},{"name":"append.json","type":"file"},{"name":"arcount.json","type":"file"},{"name":"ardel.json","type":"file"},{"name":"ardelrange.json","type":"file"},{"name":"arget.json","type":"file"},{"name":"argetrange.json","type":"file"},{"name":"argrep.json","type":"file"},{"name":"arinfo.json","type":"file"},{"name":"arinsert.json","type":"file"},{"name":"arlastitems.json","type":"file"},{"name":"arlen.json","type":"file"},{"name":"armget.json","type":"file"},{"name":"armset.json","type":"file"},{"name":"arnext.json","type":"file"},{"name":"arop.json","type":"file"},{"name":"arring.json","type":"file"},{"name":"arscan.json","type":"file"},{"name":"arseek.json","type":"file"},{"name":"arset.json","type":"file"},{"name":"asking.json","type":"file"},{"name":"auth.json","type":"file"},{"name":"bgrewriteaof.json","type":"file"},{"name":"bgsave.json","type":"file"},{"name":"bitcount.json","type":"file"},{"name":"bitfield.json","type":"file"},{"name":"bitfield_ro.json","type":"file"},{"name":"bitop.json","type":"file"},{"name":"bitpos.json","type":"file"},{"name":"blmove.json","type":"file"},{"name":"blmpop.json","type":"file"},{"name":"blpop.json","type":"file"},{"name":"brpop.json","type":"file"},{"name":"brpoplpush.json","type":"file"},{"name":"bzmpop.json","type":"file"},{"name":"bzpopmax.json","type":"file"},{"name":"bzpopmin.json","type":"file"},{"name":"client-caching.json","type":"file"},{"name":"client-getname.json","type":"file"},{"name":"client-getredir.json","type":"file"},{"name":"client-help.json","type":"file"},{"name":"client-id.json","type":"file"},{"name":"client-info.json","type":"file"},{"name":"client-kill.json","type":"file"},{"name":"client-list.json","type":"file"},{"name":"client-no-evict.json","type":"file"},{"name":"client-no-touch.json","type":"file"},{"name":"client-pause.json","type":"file"},{"name":"client-reply.json","type":"file"},{"name":"client-setinfo.json","type":"file"},{"name":"client-setname.json","type":"file"},{"name":"client-tracking.json","type":"file"},{"name":"client-trackinginfo.json","type":"file"},{"name":"client-unblock.json","type":"file"},{"name":"client-unpause.json","type":"file"},{"name":"client.json","type":"file"},{"name":"cluster-addslots.json","type":"file"},{"name":"cluster-addslotsrange.json","type":"file"},{"name":"cluster-bumpepoch.json","type":"file"},{"name":"cluster-count-failure-reports.json","type":"file"},{"name":"cluster-countkeysinslot.json","type":"file"},{"name":"cluster-delslots.json","type":"file"},{"name":"cluster-delslotsrange.json","type":"file"},{"name":"cluster-failover.json","type":"file"},{"name":"cluster-flushslots.json","type":"file"},{"name":"cluster-forget.json","type":"file"},{"name":"cluster-getkeysinslot.json","type":"file"},{"name":"cluster-help.json","type":"file"},{"name":"cluster-info.json","type":"file"},{"name":"cluster-keyslot.json","type":"file"},{"name":"cluster-links.json","type":"file"},{"name":"cluster-meet.json","type":"file"},{"name":"cluster-migration.json","type":"file"},{"name":"cluster-myid.json","type":"file"},{"name":"cluster-myshardid.json","type":"file"},{"name":"cluster-nodes.json","type":"file"},{"name":"cluster-replicas.json","type":"file"},{"name":"cluster-replicate.json","type":"file"},{"name":"cluster-reset.json","type":"file"},{"name":"cluster-saveconfig.json","type":"file"},{"name":"cluster-set-config-epoch.json","type":"file"},{"name":"cluster-setslot.json","type":"file"},{"name":"cluster-shards.json","type":"file"},{"name":"cluster-slaves.json","type":"file"},{"name":"cluster-slot-stats.json","type":"file"},{"name":"cluster-slots.json","type":"file"},{"name":"cluster-syncslots.json","type":"file"},{"name":"cluster.json","type":"file"},{"name":"command-count.json","type":"file"},{"name":"command-docs.json","type":"file"},{"name":"command-getkeys.json","type":"file"},{"name":"command-getkeysandflags.json","type":"file"},{"name":"command-help.json","type":"file"},{"name":"command-info.json","type":"file"},{"name":"command-list.json","type":"file"},{"name":"command.json","type":"file"},{"name":"config-get.json","type":"file"},{"name":"config-help.json","type":"file"},{"name":"config-resetstat.json","type":"file"},{"name":"config-rewrite.json","type":"file"},{"name":"config-set.json","type":"file"},{"name":"config.json","type":"file"},{"name":"copy.json","type":"file"},{"name":"dbsize.json","type":"file"},{"name":"debug.json","type":"file"},{"name":"decr.json","type":"file"},{"name":"decrby.json","type":"file"},{"name":"del.json","type":"file"},{"name":"delex.json","type":"file"},{"name":"digest.json","type":"file"},{"name":"discard.json","type":"file"},{"name":"dump.json","type":"file"},{"name":"echo.json","type":"file"},{"name":"eval.json","type":"file"},{"name":"eval_ro.json","type":"file"},{"name":"evalsha.json","type":"file"},{"name":"evalsha_ro.json","type":"file"},{"name":"exec.json","type":"file"},{"name":"exists.json","type":"file"},{"name":"expire.json","type":"file"},{"name":"expireat.json","type":"file"},{"name":"expiretime.json","type":"file"},{"name":"failover.json","type":"file"},{"name":"fcall.json","type":"file"},{"name":"fcall_ro.json","type":"file"},{"name":"flushall.json","type":"file"},{"name":"flushdb.json","type":"file"},{"name":"function-delete.json","type":"file"},{"name":"function-dump.json","type":"file"},{"name":"function-flush.json","type":"file"},{"name":"function-help.json","type":"file"},{"name":"function-kill.json","type":"file"},{"name":"function-list.json","type":"file"},{"name":"function-load.json","type":"file"},{"name":"function-restore.json","type":"file"},{"name":"function-stats.json","type":"file"},{"name":"function.json","type":"file"},{"name":"geoadd.json","type":"file"},{"name":"geodist.json","type":"file"},{"name":"geohash.json","type":"file"},{"name":"geopos.json","type":"file"},{"name":"georadius.json","type":"file"},{"name":"georadius_ro.json","type":"file"},{"name":"georadiusbymember.json","type":"file"},{"name":"georadiusbymember_ro.json","type":"file"},{"name":"geosearch.json","type":"file"},{"name":"geosearchstore.json","type":"file"},{"name":"get.json","type":"file"},{"name":"getbit.json","type":"file"},{"name":"getdel.json","type":"file"},{"name":"getex.json","type":"file"},{"name":"getrange.json","type":"file"},{"name":"getset.json","type":"file"},{"name":"hdel.json","type":"file"},{"name":"hello.json","type":"file"},{"name":"hexists.json","type":"file"},{"name":"hexpire.json","type":"file"},{"name":"hexpireat.json","type":"file"},{"name":"hexpiretime.json","type":"file"},{"name":"hget.json","type":"file"},{"name":"hgetall.json","type":"file"},{"name":"hgetdel.json","type":"file"},{"name":"hgetex.json","type":"file"},{"name":"hincrby.json","type":"file"},{"name":"hincrbyfloat.json","type":"file"},{"name":"hkeys.json","type":"file"},{"name":"hlen.json","type":"file"},{"name":"hmget.json","type":"file"},{"name":"hmset.json","type":"file"},{"name":"hotkeys-get.json","type":"file"},{"name":"hotkeys-help.json","type":"file"},{"name":"hotkeys-reset.json","type":"file"},{"name":"hotkeys-start.json","type":"file"},{"name":"hotkeys-stop.json","type":"file"},{"name":"hotkeys.json","type":"file"},{"name":"hpersist.json","type":"file"},{"name":"hpexpire.json","type":"file"},{"name":"hpexpireat.json","type":"file"},{"name":"hpexpiretime.json","type":"file"},{"name":"hpttl.json","type":"file"},{"name":"hrandfield.json","type":"file"},{"name":"hscan.json","type":"file"},{"name":"hset.json","type":"file"},{"name":"hsetex.json","type":"file"},{"name":"hsetnx.json","type":"file"},{"name":"hstrlen.json","type":"file"},{"name":"httl.json","type":"file"},{"name":"hvals.json","type":"file"},{"name":"incr.json","type":"file"},{"name":"incrby.json","type":"file"},{"name":"incrbyfloat.json","type":"file"},{"name":"increx.json","type":"file"},{"name":"info.json","type":"file"},{"name":"keys.json","type":"file"},{"name":"lastsave.json","type":"file"},{"name":"latency-doctor.json","type":"file"},{"name":"latency-graph.json","type":"file"},{"name":"latency-help.json","type":"file"},{"name":"latency-histogram.json","type":"file"},{"name":"latency-history.json","type":"file"},{"name":"latency-latest.json","type":"file"},{"name":"latency-reset.json","type":"file"},{"name":"latency.json","type":"file"},{"name":"lcs.json","type":"file"},{"name":"lindex.json","type":"file"},{"name":"linsert.json","type":"file"},{"name":"llen.json","type":"file"},{"name":"lmove.json","type":"file"},{"name":"lmpop.json","type":"file"},{"name":"lolwut.json","type":"file"},{"name":"lpop.json","type":"file"},{"name":"lpos.json","type":"file"},{"name":"lpush.json","type":"file"},{"name":"lpushx.json","type":"file"},{"name":"lrange.json","type":"file"},{"name":"lrem.json","type":"file"},{"name":"lset.json","type":"file"},{"name":"ltrim.json","type":"file"},{"name":"memory-doctor.json","type":"file"},{"name":"memory-help.json","type":"file"},{"name":"memory-malloc-stats.json","type":"file"},{"name":"memory-purge.json","type":"file"},{"name":"memory-stats.json","type":"file"},{"name":"memory-usage.json","type":"file"},{"name":"memory.json","type":"file"},{"name":"mget.json","type":"file"},{"name":"migrate.json","type":"file"},{"name":"module-help.json","type":"file"},{"name":"module-list.json","type":"file"},{"name":"module-load.json","type":"file"},{"name":"module-loadex.json","type":"file"},{"name":"module-unload.json","type":"file"},{"name":"module.json","type":"file"},{"name":"monitor.json","type":"file"},{"name":"move.json","type":"file"},{"name":"mset.json","type":"file"},{"name":"msetex.json","type":"file"},{"name":"msetnx.json","type":"file"},{"name":"multi.json","type":"file"},{"name":"object-encoding.json","type":"file"},{"name":"object-freq.json","type":"file"},{"name":"object-help.json","type":"file"},{"name":"object-idletime.json","type":"file"},{"name":"object-refcount.json","type":"file"},{"name":"object.json","type":"file"},{"name":"persist.json","type":"file"},{"name":"pexpire.json","type":"file"},{"name":"pexpireat.json","type":"file"},{"name":"pexpiretime.json","type":"file"},{"name":"pfadd.json","type":"file"},{"name":"pfcount.json","type":"file"},{"name":"pfdebug.json","type":"file"},{"name":"pfmerge.json","type":"file"},{"name":"pfselftest.json","type":"file"},{"name":"ping.json","type":"file"},{"name":"psetex.json","type":"file"},{"name":"psubscribe.json","type":"file"},{"name":"psync.json","type":"file"},{"name":"pttl.json","type":"file"},{"name":"publish.json","type":"file"},{"name":"pubsub-channels.json","type":"file"},{"name":"pubsub-help.json","type":"file"},{"name":"pubsub-numpat.json","type":"file"},{"name":"pubsub-numsub.json","type":"file"},{"name":"pubsub-shardchannels.json","type":"file"},{"name":"pubsub-shardnumsub.json","type":"file"},{"name":"pubsub.json","type":"file"},{"name":"punsubscribe.json","type":"file"},{"name":"quit.json","type":"file"},{"name":"randomkey.json","type":"file"},{"name":"readonly.json","type":"file"},{"name":"readwrite.json","type":"file"},{"name":"rename.json","type":"file"},{"name":"renamenx.json","type":"file"},{"name":"replconf.json","type":"file"},{"name":"replicaof.json","type":"file"},{"name":"reset.json","type":"file"},{"name":"restore-asking.json","type":"file"},{"name":"restore.json","type":"file"},{"name":"role.json","type":"file"},{"name":"rpop.json","type":"file"},{"name":"rpoplpush.json","type":"file"},{"name":"rpush.json","type":"file"},{"name":"rpushx.json","type":"file"},{"name":"sadd.json","type":"file"},{"name":"save.json","type":"file"},{"name":"scan.json","type":"file"},{"name":"scard.json","type":"file"},{"name":"script-debug.json","type":"file"},{"name":"script-exists.json","type":"file"},{"name":"script-flush.json","type":"file"},{"name":"script-help.json","type":"file"},{"name":"script-kill.json","type":"file"},{"name":"script-load.json","type":"file"},{"name":"script.json","type":"file"},{"name":"sdiff.json","type":"file"},{"name":"sdiffstore.json","type":"file"},{"name":"select.json","type":"file"},{"name":"sentinel-ckquorum.json","type":"file"},{"name":"sentinel-config.json","type":"file"},{"name":"sentinel-debug.json","type":"file"},{"name":"sentinel-failover.json","type":"file"},{"name":"sentinel-flushconfig.json","type":"file"},{"name":"sentinel-get-master-addr-by-name.json","type":"file"},{"name":"sentinel-help.json","type":"file"},{"name":"sentinel-info-cache.json","type":"file"},{"name":"sentinel-is-master-down-by-addr.json","type":"file"},{"name":"sentinel-master.json","type":"file"},{"name":"sentinel-masters.json","type":"file"},{"name":"sentinel-monitor.json","type":"file"},{"name":"sentinel-myid.json","type":"file"},{"name":"sentinel-pending-scripts.json","type":"file"},{"name":"sentinel-remove.json","type":"file"},{"name":"sentinel-replicas.json","type":"file"},{"name":"sentinel-reset.json","type":"file"},{"name":"sentinel-sentinels.json","type":"file"},{"name":"sentinel-set.json","type":"file"},{"name":"sentinel-simulate-failure.json","type":"file"},{"name":"sentinel-slaves.json","type":"file"},{"name":"sentinel.json","type":"file"},{"name":"set.json","type":"file"},{"name":"setbit.json","type":"file"},{"name":"setex.json","type":"file"},{"name":"setnx.json","type":"file"},{"name":"setrange.json","type":"file"},{"name":"sflush.json","type":"file"},{"name":"shutdown.json","type":"file"},{"name":"sinter.json","type":"file"},{"name":"sintercard.json","type":"file"},{"name":"sinterstore.json","type":"file"},{"name":"sismember.json","type":"file"},{"name":"slaveof.json","type":"file"},{"name":"slowlog-get.json","type":"file"},{"name":"slowlog-help.json","type":"file"},{"name":"slowlog-len.json","type":"file"},{"name":"slowlog-reset.json","type":"file"},{"name":"slowlog.json","type":"file"},{"name":"smembers.json","type":"file"},{"name":"smismember.json","type":"file"},{"name":"smove.json","type":"file"},{"name":"sort.json","type":"file"},{"name":"sort_ro.json","type":"file"},{"name":"spop.json","type":"file"},{"name":"spublish.json","type":"file"},{"name":"srandmember.json","type":"file"},{"name":"srem.json","type":"file"},{"name":"sscan.json","type":"file"},{"name":"ssubscribe.json","type":"file"},{"name":"strlen.json","type":"file"},{"name":"subscribe.json","type":"file"},{"name":"substr.json","type":"file"},{"name":"sunion.json","type":"file"},{"name":"sunionstore.json","type":"file"},{"name":"sunsubscribe.json","type":"file"},{"name":"swapdb.json","type":"file"},{"name":"sync.json","type":"file"},{"name":"time.json","type":"file"},{"name":"touch.json","type":"file"},{"name":"trimslots.json","type":"file"},{"name":"ttl.json","type":"file"},{"name":"type.json","type":"file"},{"name":"unlink.json","type":"file"},{"name":"unsubscribe.json","type":"file"},{"name":"unwatch.json","type":"file"},{"name":"wait.json","type":"file"},{"name":"waitaof.json","type":"file"},{"name":"watch.json","type":"file"},{"name":"xack.json","type":"file"},{"name":"xackdel.json","type":"file"},{"name":"xadd.json","type":"file"},{"name":"xautoclaim.json","type":"file"},{"name":"xcfgset.json","type":"file"},{"name":"xclaim.json","type":"file"},{"name":"xdel.json","type":"file"},{"name":"xdelex.json","type":"file"},{"name":"xgroup-create.json","type":"file"},{"name":"xgroup-createconsumer.json","type":"file"},{"name":"xgroup-delconsumer.json","type":"file"},{"name":"xgroup-destroy.json","type":"file"},{"name":"xgroup-help.json","type":"file"},{"name":"xgroup-setid.json","type":"file"},{"name":"xgroup.json","type":"file"},{"name":"xidmprecord.json","type":"file"},{"name":"xinfo-consumers.json","type":"file"},{"name":"xinfo-groups.json","type":"file"},{"name":"xinfo-help.json","type":"file"},{"name":"xinfo-stream.json","type":"file"},{"name":"xinfo.json","type":"file"},{"name":"xlen.json","type":"file"},{"name":"xnack.json","type":"file"},{"name":"xpending.json","type":"file"},{"name":"xrange.json","type":"file"},{"name":"xread.json","type":"file"},{"name":"xreadgroup.json","type":"file"},{"name":"xrevrange.json","type":"file"},{"name":"xsetid.json","type":"file"},{"name":"xtrim.json","type":"file"},{"name":"zadd.json","type":"file"},{"name":"zcard.json","type":"file"},{"name":"zcount.json","type":"file"},{"name":"zdiff.json","type":"file"},{"name":"zdiffstore.json","type":"file"},{"name":"zincrby.json","type":"file"},{"name":"zinter.json","type":"file"},{"name":"zintercard.json","type":"file"},{"name":"zinterstore.json","type":"file"},{"name":"zlexcount.json","type":"file"},{"name":"zmpop.json","type":"file"},{"name":"zmscore.json","type":"file"},{"name":"zpopmax.json","type":"file"},{"name":"zpopmin.json","type":"file"},{"name":"zrandmember.json","type":"file"},{"name":"zrange.json","type":"file"},{"name":"zrangebylex.json","type":"file"},{"name":"zrangebyscore.json","type":"file"},{"name":"zrangestore.json","type":"file"},{"name":"zrank.json","type":"file"},{"name":"zrem.json","type":"file"},{"name":"zremrangebylex.json","type":"file"},{"name":"zremrangebyrank.json","type":"file"},{"name":"zremrangebyscore.json","type":"file"},{"name":"zrevrange.json","type":"file"},{"name":"zrevrangebylex.json","type":"file"},{"name":"zrevrangebyscore.json","type":"file"},{"name":"zrevrank.json","type":"file"},{"name":"zscan.json","type":"file"},{"name":"zscore.json","type":"file"},{"name":"zunion.json","type":"file"},{"name":"zunionstore.json","type":"file"}] diff --git a/plugins/catalog/testdata/redis-doc-06f3598.json b/plugins/catalog/testdata/redis-doc-06f3598.json deleted file mode 100644 index 08e93d1..0000000 --- a/plugins/catalog/testdata/redis-doc-06f3598.json +++ /dev/null @@ -1,92 +0,0 @@ -{ - "FUNCTION LOAD": { - "acl_categories": [ - "@write", - "@slow", - "@scripting" - ], - "arguments": [ - { - "name": "engine-name", - "type": "string" - }, - { - "name": "library-name", - "type": "string" - }, - { - "name": "replace", - "optional": true, - "token": "REPLACE", - "type": "pure-token" - }, - { - "name": "library-description", - "optional": true, - "token": "DESC", - "type": "string" - }, - { - "name": "function-code", - "type": "string" - } - ], - "arity": -5, - "command_flags": [ - "write", - "denyoom", - "noscript" - ], - "complexity": "O(1) (considering compilation time is redundant)", - "group": "scripting", - "hints": [ - "request_policy:all_shards", - "response_policy:all_succeeded" - ], - "since": "7.0.0", - "summary": "Create a function with the given arguments (name, code, description)" - }, - "GET": { - "acl_categories": [ - "@read", - "@string", - "@fast" - ], - "arguments": [ - { - "key_spec_index": 0, - "name": "key", - "type": "key" - } - ], - "arity": 2, - "command_flags": [ - "readonly", - "fast" - ], - "complexity": "O(1)", - "group": "string", - "key_specs": [ - { - "RO": true, - "access": true, - "begin_search": { - "spec": { - "index": 1 - }, - "type": "index" - }, - "find_keys": { - "spec": { - "keystep": 1, - "lastkey": 0, - "limit": 0 - }, - "type": "range" - } - } - ], - "since": "1.0.0", - "summary": "Get the value of a key" - } -} \ No newline at end of file diff --git a/plugins/catalog/testdata/redis-doc-cc0427b.json b/plugins/catalog/testdata/redis-doc-cc0427b.json deleted file mode 100644 index 53fd757..0000000 --- a/plugins/catalog/testdata/redis-doc-cc0427b.json +++ /dev/null @@ -1,112 +0,0 @@ -{ - "FUNCTION CREATE": { - "acl_categories": [ - "@write", - "@slow", - "@scripting" - ], - "arguments": [ - { - "name": "engine-name", - "type": "string" - }, - { - "name": "function-name", - "type": "string" - }, - { - "name": "replace", - "optional": true, - "token": "REPLACE", - "type": "pure-token" - }, - { - "name": "function-description", - "optional": true, - "token": "DESC", - "type": "string" - }, - { - "name": "function-code", - "type": "string" - } - ], - "arity": -5, - "command_flags": [ - "write", - "noscript" - ], - "complexity": "O(1) (considering compilation time is redundant)", - "group": "scripting", - "since": "7.0.0", - "summary": "Create a function with the given arguments (name, code, description)" - }, - "FUNCTION INFO": { - "acl_categories": [ - "@slow", - "@scripting" - ], - "arguments": [ - { - "name": "function-name", - "type": "string" - }, - { - "name": "withcode", - "optional": true, - "token": "WITHCODE", - "type": "pure-token" - } - ], - "arity": -3, - "command_flags": [ - "noscript" - ], - "complexity": "O(1)", - "group": "scripting", - "since": "7.0.0", - "summary": "Return information about a function by function name" - }, - "GET": { - "acl_categories": [ - "@read", - "@string", - "@fast" - ], - "arguments": [ - { - "key_spec_index": 0, - "name": "key", - "type": "key" - } - ], - "arity": 2, - "command_flags": [ - "readonly", - "fast" - ], - "complexity": "O(1)", - "group": "string", - "key_specs": [ - { - "begin_search": { - "spec": { - "index": 1 - }, - "type": "index" - }, - "find_keys": { - "spec": { - "keystep": 1, - "lastkey": 0, - "limit": 0 - }, - "type": "range" - }, - "read": true - } - ], - "since": "1.0.0", - "summary": "Get the value of a key" - } -} \ No newline at end of file diff --git a/plugins/catalog/testdata/redis-releases-excerpt.json b/plugins/catalog/testdata/redis-releases-excerpt.json new file mode 100644 index 0000000..51c8948 --- /dev/null +++ b/plugins/catalog/testdata/redis-releases-excerpt.json @@ -0,0 +1,7 @@ +[ + {"tag_name": "8.0.1", "draft": false, "prerelease": false, "published_at": "2025-05-13T10:00:00Z", "html_url": "https://github.com/redis/redis/releases/tag/8.0.1"}, + {"tag_name": "7.2.10", "draft": false, "prerelease": false, "published_at": "2025-07-06T10:00:00Z", "html_url": "https://github.com/redis/redis/releases/tag/7.2.10"}, + {"tag_name": "8.0-rc1", "draft": false, "prerelease": true, "published_at": "2025-04-01T10:00:00Z", "html_url": "https://github.com/redis/redis/releases/tag/8.0-rc1"}, + {"tag_name": "8.0.0", "draft": false, "prerelease": false, "published_at": "2025-05-02T10:00:00Z", "html_url": "https://github.com/redis/redis/releases/tag/8.0.0"}, + {"tag_name": "6.2.20", "draft": false, "prerelease": false, "published_at": "2025-07-06T09:00:00Z", "html_url": "https://github.com/redis/redis/releases/tag/6.2.20"} +] diff --git a/plugins/changelog/changelog.go b/plugins/changelog/changelog.go index 90a8a63..f267ce5 100644 --- a/plugins/changelog/changelog.go +++ b/plugins/changelog/changelog.go @@ -98,12 +98,6 @@ var Urllib3 = File{ Repo: "urllib3/urllib3", Path: "CHANGES.rst", } -// The releases the golden files pin. -var ( - Textual0860 = Textual.At("0.86.0") - Urllib3200 = Urllib3.At("2.0.0") -) - // URL is the changelog as it was at the (pinned) tag: its own provenance. func (f File) URL() string { return fmt.Sprintf("https://raw.githubusercontent.com/%s/%s/%s", f.Repo, f.Tag, f.Path) diff --git a/plugins/changelog/pinned_test.go b/plugins/changelog/pinned_test.go new file mode 100644 index 0000000..f048a7b --- /dev/null +++ b/plugins/changelog/pinned_test.go @@ -0,0 +1,8 @@ +package changelog + +// The releases the golden files pin. Only a test names a release: the +// registered sources list theirs from PyPI. +var ( + Textual0860 = Textual.At("0.86.0") + Urllib3200 = Urllib3.At("2.0.0") +) diff --git a/plugins/migrationguide/golden_test.go b/plugins/migrationguide/golden_test.go index 7612269..164eed6 100644 --- a/plugins/migrationguide/golden_test.go +++ b/plugins/migrationguide/golden_test.go @@ -12,7 +12,7 @@ import ( // The guide at tag v1.0.0 (saved 2026-10-17) in, every event out: the pair // from 0.75.0, the release before on PyPI. func TestGolden(t *testing.T) { - kittest.Golden(t, "testdata/golden/anthropic-1.0.0.json", anthropicV1(t, sdkguide.AnthropicV1)) + kittest.Golden(t, "testdata/golden/anthropic-1.0.0.json", anthropicV1(t, anthropicGuideV1)) } // anthropicV1 is g's pair 0.75.0 -> 1.0.0 over the saved v1.0.0 guide, as @@ -20,7 +20,7 @@ func TestGolden(t *testing.T) { // it has no guide, and nothing is fetched for it. func anthropicV1(t *testing.T, g sdkguide.Guide, more ...kittest.Pages) []event.Event { t.Helper() - pages := kittest.Pages{sdkguide.AnthropicV1.URL(): "sdkguide/testdata/anthropic-MIGRATION-v1.0.0.md"} + pages := kittest.Pages{anthropicGuideV1.URL(): "sdkguide/testdata/anthropic-MIGRATION-v1.0.0.md"} for _, m := range more { for k, v := range m { pages[k] = v @@ -29,3 +29,7 @@ func anthropicV1(t *testing.T, g sdkguide.Guide, more ...kittest.Pages) []event. return kittest.Versions(t, kittest.Env(t, pages), Plugin{Guide: g}, plugin.Version{ID: "0.75.0", Ref: "v0.75.0"}, plugin.Version{ID: "1.0.0", Ref: "v1.0.0"}) } + +// anthropicGuideV1 is anthropic-sdk-python's guide pinned to 1.0.0: what the +// golden pins. Only a test names a release. +var anthropicGuideV1 = sdkguide.Anthropic.At(1) diff --git a/plugins/migrationguide/members/export_test.go b/plugins/migrationguide/members/export_test.go index 8667a92..b5dbb04 100644 --- a/plugins/migrationguide/members/export_test.go +++ b/plugins/migrationguide/members/export_test.go @@ -7,5 +7,6 @@ var ( SoleName = soleName ) -func (g Guide) Tag() string { return g.tag() } +func (g Guide) TagOf(release string) string { return g.tagOf(release) } +func (g Guide) CommitsURL(major int) string { return g.commitsURL(major) } func (g Guide) AbsoluteLinks(s string) string { return g.absoluteLinks(s) } diff --git a/plugins/migrationguide/members/golden_test.go b/plugins/migrationguide/members/golden_test.go index b76686b..e28bb60 100644 --- a/plugins/migrationguide/members/golden_test.go +++ b/plugins/migrationguide/members/golden_test.go @@ -6,6 +6,7 @@ import ( "github.com/patch-it-dev/patch-it-plugins/core/event" "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" "github.com/patch-it-dev/patch-it-plugins/core/plugin" + "github.com/patch-it-dev/patch-it-plugins/core/versions" "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide" . "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide/members" // the reader under test @@ -14,16 +15,35 @@ import ( // The guide at tag v2.0.0 (saved 2026-11-04) in, every event out: the pair // from 1.26.4, the release before on PyPI. func TestGolden(t *testing.T) { - got := release(t, NumPy2, "testdata/numpy_2_0_migration_guide-v2.0.0.rst", "1.26.4") + got := release(t, NumPy, "testdata/numpy_2_0_migration_guide-v2.0.0.rst", "1.26.4", "2.0.0") kittest.Golden(t, "../testdata/golden/numpy-2.0.0.json", got) } -// release is the pair previous -> the release g documents, over the guide -// saved as file, as patch-it's hosted ingestion service extracts it. -// previous isn't the guide's release: it has no guide, and nothing is -// fetched for it. -func release(t *testing.T, g Guide, file, previous string) []event.Event { +// release is the pair previous -> rel, the first release of a major, over +// the guide saved as file, as patch-it's hosted ingestion service extracts +// it. previous isn't a major's first release: it has no guide, and nothing +// is fetched for it. +func release(t *testing.T, g Guide, file, previous, rel string) []event.Event { t.Helper() - env := kittest.Env(t, kittest.Pages{g.URL(): file}) - return kittest.Versions(t, env, migrationguide.Plugin{Guide: g}, plugin.Version{ID: previous}, plugin.Version{ID: g.Release}) + return kittest.Versions(t, guideEnv(t, g, file, rel), migrationguide.Plugin{Guide: g}, plugin.Version{ID: previous}, plugin.Version{ID: rel}) +} + +// newrelicCommit is the docs-website commit New Relic's saved release note +// was fetched at, and newrelicCommits GitHub's answer naming it as the +// newest commit that changed the note. +const ( + newrelicCommit = "f0b4f817bf9a7b76a78e26609369a8a7ce764c8e" + newrelicCommits = "testdata/github-commits-python-agent-110000.json" +) + +// guideEnv serves file as g's guide for rel: at rel's tag, or (Untagged) at +// the commit GitHub names for it. +func guideEnv(t *testing.T, g Guide, file, rel string) plugin.Env { + t.Helper() + major := versions.Major(rel) + pages := kittest.Pages{g.RawURL(g.TagOf(rel), major): file} + if g.Untagged { + pages = kittest.Pages{g.CommitsURL(major): newrelicCommits, g.RawURL(newrelicCommit, major): file} + } + return kittest.Env(t, pages) } diff --git a/plugins/migrationguide/members/members.go b/plugins/migrationguide/members/members.go index 033b05f..7e029af 100644 --- a/plugins/migrationguide/members/members.go +++ b/plugins/migrationguide/members/members.go @@ -2,9 +2,12 @@ // that removed members of its top-level module, read from the release's own // migration guide at its tag: change event v2's `package_release` subject. // The kind (plugins/migrationguide) reads the guide and calls Read; this -// package knows where the guide is and how its table reads. NumPy 2.0 first: its guide lists about 60 members of the main `np` -// namespace that were removed, each with a migration guideline, and code using -// one raises AttributeError on NumPy 2 (checked 2026-11-04 at tag v2.0.0). +// package knows where the guide is and how its table reads. A guide is read +// at the first release of each major (X.0.0), listed from PyPI: nothing in +// the code names a release. NumPy first: its 2.0 guide lists about 60 +// members of the main `np` namespace that were removed, each with a +// migration guideline, and code using one raises AttributeError on NumPy 2 +// (checked 2026-11-04 at tag v2.0.0). // // A row whose guideline is exactly one replacement in the module ("Use // “np.float64“ instead.") becomes a `renamed_symbol` with that replacement: @@ -24,33 +27,40 @@ import ( "context" "fmt" "log" + "net/url" "regexp" "slices" + "strconv" "strings" "time" "github.com/patch-it-dev/patch-it-plugins/core/event" + "github.com/patch-it-dev/patch-it-plugins/core/github" "github.com/patch-it-dev/patch-it-plugins/core/plugin" "github.com/patch-it-dev/patch-it-plugins/core/versions" ) -// Guide is one package's guide to one release. +// Guide is one package's guide to each of its majors. type Guide struct { API string // the source id the events carry: "numpy/numpy" Package string // the PyPI name: "numpy" Module string // how the guide writes the module in a replacement: "np" - Release string // "2.0.0" Repo string // owner/name on GitHub - Path string // the guide's path in the repo at the release tag + // Path is the guide's path in the repo for a major, "{major}" standing + // for the major's number and "{prev}" for the one before: + // "doc/source/numpy_{major}_0_migration_guide.rst" is + // doc/source/numpy_2_0_migration_guide.rst for 2.0.0. + Path string Section string // the heading the table is under // TagPrefix makes a release's git tag: TagPrefix + version ("" is "v": - // v2.0.0; PostHog's is "posthog-v"). The guide is read at Release's tag. + // v2.0.0; PostHog's is "posthog-v"). A major's guide is read at the tag + // of its first release. TagPrefix string - // DocsRef, when the guide isn't in the package's own repo but in a docs - // repo with no release tags (New Relic's release notes), is the commit - // of Repo the guide is read at. - DocsRef string + // Untagged is a guide that isn't in the package's own repo but in a docs + // repo with no release tags (New Relic's release notes): it is read at + // the newest commit that changed its path, looked up when it's read. + Untagged bool // Format is how the table is written: FormatRST (the default) or // FormatMarkdown. Format Format @@ -111,13 +121,8 @@ const ( FormatMarkdown Format = "markdown" ) -func (g Guide) tag() string { return g.tagOf(g.Release) } - -// tagOf is the git ref a release of the package is read at. +// tagOf is the git tag of a release of the package. func (g Guide) tagOf(release string) string { - if g.DocsRef != "" { - return g.DocsRef - } if g.TagPrefix != "" { return g.TagPrefix + release } @@ -138,21 +143,33 @@ func (g Guide) header() string { return "removed member" } -// NumPy2 is NumPy's 2.0 migration guide, "Main namespace" table. -var NumPy2 = Guide{ +// NumPy is NumPy's migration guide to a major, "Main namespace" table +// (doc/source/numpy_2_0_migration_guide.rst at v2.0.0, checked 2026-11-04; +// no other major has one yet, checked 2026-11-20). +var NumPy = Guide{ API: "numpy/numpy", Package: "numpy", Module: "np", - Release: "2.0.0", Repo: "numpy/numpy", - Path: "doc/source/numpy_2_0_migration_guide.rst", + Path: "doc/source/numpy_{major}_0_migration_guide.rst", Section: "Main namespace", Effect: "code using it raises AttributeError", } -// URL is the guide as it was at the release tag: its own provenance. -func (g Guide) URL() string { - return fmt.Sprintf("https://raw.githubusercontent.com/%s/%s/%s", g.Repo, g.tag(), g.Path) +// PathAt is the guide's path for a major. +func (g Guide) PathAt(major int) string { + return strings.NewReplacer("{major}", strconv.Itoa(major), "{prev}", strconv.Itoa(major-1)).Replace(g.Path) +} + +// commitsURL lists the newest commit that changed a major's guide. +func (g Guide) commitsURL(major int) string { + return fmt.Sprintf("%s/repos/%s/commits?path=%s&per_page=1", github.API, g.Repo, url.QueryEscape(g.PathAt(major))) +} + +// RawURL is the guide for a major at a git ref (a tag or a commit): its own +// provenance, as it never changes. +func (g Guide) RawURL(ref string, major int) string { + return fmt.Sprintf("%s/%s/%s/%s", github.Raw, g.Repo, ref, g.PathAt(major)) } // Removal is one removed member and the guide's guideline for it. @@ -245,10 +262,13 @@ func parseRST(page []byte, g Guide) ([]Removal, error) { // Slug is the source id the events carry: "numpy/numpy". func (g Guide) Slug() string { return g.API } -// Releases is every final release of the package on PyPI, oldest first, -// each with the ref its guide would be read at. +// Releases is every final release of the package on PyPI, yanked ones +// included, oldest first, each with its tag. A yanked release stays: it can +// be the one a guide documents (New Relic's 11.0.0, yanked for a +// server-side configuration issue), and a pin on a later one still crosses +// it. func (g Guide) Releases(ctx context.Context, env plugin.Env) ([]plugin.Version, error) { - vs, err := versions.PyPIReleases(ctx, env.Get, g.Package) + vs, err := versions.PyPIReleasesWithYanked(ctx, env.Get, g.Package) if err != nil { return nil, err } @@ -258,34 +278,44 @@ func (g Guide) Releases(ctx context.Context, env plugin.Env) ([]plugin.Version, return vs, nil } -// GuideURL is the guide when v is the release it documents; any other -// release has no guide (""). -func (g Guide) GuideURL(v plugin.Version) string { - if v.ID != g.Release { - return "" +// GuideURL is the guide for v's major when v is its first release (X.0.0), +// at v's tag or, Untagged, at the newest commit that changed the guide's +// path; any other release has no guide (""). A major whose guide's path has +// no commit has nothing to read (plugin.ErrNothingToRead). +func (g Guide) GuideURL(ctx context.Context, env plugin.Env, v plugin.Version) (string, error) { + if !versions.FirstOfMajor(v.ID) { + return "", nil + } + major := versions.Major(v.ID) + if !g.Untagged { + return g.RawURL(g.tagOf(v.ID), major), nil + } + sha, err := github.LatestCommit(ctx, env.Get, g.commitsURL(major)) + if err != nil { + return "", fmt.Errorf("the commit %s's guide for %s is read at: %w", g.Package, v.ID, err) } - return g.URL() + return g.RawURL(sha, major), nil } -// Read is an event per removed member in the guide, with previous_version -// from's release. -func (g Guide) Read(page []byte, from, _ plugin.Version, now time.Time) (events []event.Event, rejected []error, err error) { +// Read is an event per removed member in the guide to's release documents, +// read from sourceURL, with previous_version from's release. +func (g Guide) Read(page []byte, sourceURL string, from, to plugin.Version, now time.Time) (events []event.Event, rejected []error, err error) { removals, err := Parse(page, g) if err != nil { return nil, nil, err } for _, r := range removals { if r.Dropped != "" { - log.Printf("%s %s: dropped %q: %s", g.Package, g.Release, r.Member, r.Dropped) + log.Printf("%s %s: dropped %q: %s", g.Package, to.ID, r.Member, r.Dropped) continue } subject := event.Subject{ Type: event.SubjectPackageRelease, Ecosystem: "pypi", Package: g.Package, Change: event.PackageRemovedSymbol, Symbols: []string{r.Member}, } - desc := fmt.Sprintf("`%s` was removed in %s %s.", r.Member, g.Package, g.Release) + desc := fmt.Sprintf("`%s` was removed in %s %s.", r.Member, g.Package, to.ID) if g.Effect != "" { - desc = fmt.Sprintf("%s.%s was removed in %s %s: %s.", g.Module, r.Member, g.Package, g.Release, g.Effect) + desc = fmt.Sprintf("%s.%s was removed in %s %s: %s.", g.Module, r.Member, g.Package, to.ID, g.Effect) } if r.Replacement != "" && !g.NewReplacements && (g.DropIns == nil || slices.Contains(g.DropIns, r.Member)) { subject.Change, subject.Replacement = event.PackageRenamedSymbol, r.Replacement @@ -293,13 +323,13 @@ func (g Guide) Read(page []byte, from, _ plugin.Version, now time.Time) (events e := event.Event{ API: g.API, PreviousVersion: from.ID, - Version: g.Release, + Version: to.ID, ChangeType: event.ChangeTypeBreaking, Breaking: true, Subject: subject, Description: desc, - MigrationHint: fmt.Sprintf("%s (%s's %s for %s)", g.absoluteLinks(r.Guideline), g.Package, g.doc(), g.Release), - SourceURL: g.URL(), + MigrationHint: fmt.Sprintf("%s (%s's %s for %s)", g.absoluteLinks(r.Guideline), g.Package, g.doc(), to.ID), + SourceURL: sourceURL, SourceExcerpt: r.Excerpt, Confidence: 1.0, DetectedAt: now, diff --git a/plugins/migrationguide/members/members_test.go b/plugins/migrationguide/members/members_test.go index 7237856..c568650 100644 --- a/plugins/migrationguide/members/members_test.go +++ b/plugins/migrationguide/members/members_test.go @@ -18,7 +18,7 @@ func guide(t *testing.T) []byte { func byMember(t *testing.T) map[string]Removal { t.Helper() - rs, err := Parse(guide(t), NumPy2) + rs, err := Parse(guide(t), NumPy) if err != nil { t.Fatal(err) } @@ -71,10 +71,7 @@ func TestOnlyOnePlainReplacementInNpIsARename(t *testing.T) { func TestTheGuideStoresOneEventPerMemberAndARerunNothing(t *testing.T) { // The guide at the v2.0.0 tag, and nothing else; kittest extracts the // pair again and fails on anything new. - if NumPy2.URL() != "https://raw.githubusercontent.com/numpy/numpy/v2.0.0/doc/source/numpy_2_0_migration_guide.rst" { - t.Fatalf("the guide is read at %s, not the v2.0.0 tag", NumPy2.URL()) - } - events := release(t, NumPy2, "testdata/numpy_2_0_migration_guide-v2.0.0.rst", "1.26.4") + events := release(t, NumPy, "testdata/numpy_2_0_migration_guide-v2.0.0.rst", "1.26.4", "2.0.0") if len(events) != 56 { t.Fatalf("%d events, want 56", len(events)) } diff --git a/plugins/migrationguide/members/newrelic.go b/plugins/migrationguide/members/newrelic.go index a4bc4fb..13bfff3 100644 --- a/plugins/migrationguide/members/newrelic.go +++ b/plugins/migrationguide/members/newrelic.go @@ -1,16 +1,19 @@ package members -// NewRelic11 is New Relic's release note for the Python agent 11.0.0 (the -// `newrelic` package on PyPI), in newrelic/docs-website at commit -// f0b4f817bf9a7b76a78e26609369a8a7ce764c8e: that repo has no tags, so the -// commit stands in for one. Its "Removed features" section's first table, -// | Legacy API | Replacement API |: "The following APIs have been removed". -// Checked 2026-11-19. +// NewRelic is New Relic's release note for each major of the Python agent +// (the `newrelic` package on PyPI), in newrelic/docs-website as +// python-agent-0000.mdx (python-agent-110000.mdx for 11.0.0; 9.0.0 +// to 13.0.0 are there, checked 2026-11-20). That repo has no tags, so the +// newest commit that changed the note stands in for one (Untagged). Its +// "Removed features" section's first table, | Legacy API | Replacement API |: +// "The following APIs have been removed". A note without that section has +// nothing to read. 11.0.0's, at commit f0b4f817 (checked 2026-11-19), is +// the one described below. // // 11.0.0 is yanked on PyPI ("Issues with server-side configuration"); // 11.0.1 has the same public API (newrelic/agent.py and newrelic/api/log.py // are byte-identical at v11.0.0 and v11.0.1). The version stays 11.0.0, the -// release that made the change. +// release that made the change: Releases keeps yanked releases. // // Names are kept as code writes them after `import newrelic`: the table // writes them bare, and Paths gives each its module. Every row was checked @@ -61,18 +64,21 @@ package members // 7 events. The section's second table, | Legacy Setting | Replacement // Setting |, lists configuration settings (newrelic.ini keys), not members // of the package: only the section's first table is read, so it never is. -var NewRelic11 = Guide{ - API: "newrelic/python-agent", - Package: "newrelic", - Module: "newrelic", - Release: "11.0.0", - DocsRef: "f0b4f817bf9a7b76a78e26609369a8a7ce764c8e", - Repo: "newrelic/docs-website", - Path: "src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx", - Section: "Removed features", - Format: FormatMarkdown, - Header: "Legacy API", - Doc: "release notes", +// +// Paths and DropIns were checked against 11.0.0's table. A later major's +// rows with one replacement are removed_symbol unless listed in DropIns, so +// a new note is read conservatively. +var NewRelic = Guide{ + API: "newrelic/python-agent", + Package: "newrelic", + Module: "newrelic", + Untagged: true, + Repo: "newrelic/docs-website", + Path: "src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-{major}0000.mdx", + Section: "Removed features", + Format: FormatMarkdown, + Header: "Legacy API", + Doc: "release notes", // The cells link to docs.newrelic.com by path ("/docs/agents/…"). LinkBase: "https://docs.newrelic.com", Paths: map[string]string{ diff --git a/plugins/migrationguide/members/newrelic_test.go b/plugins/migrationguide/members/newrelic_test.go index 6cd0c2c..4be8e3e 100644 --- a/plugins/migrationguide/members/newrelic_test.go +++ b/plugins/migrationguide/members/newrelic_test.go @@ -19,7 +19,7 @@ import ( const newrelicSource = "testdata/python-agent-110000-f0b4f817.mdx" func TestNewRelicRegistersItself(t *testing.T) { - kittest.Registered(t, migrationguide.Plugin{Guide: NewRelic11}) + kittest.Registered(t, migrationguide.Plugin{Guide: NewRelic}) } // The golden test: the saved excerpt in, every event out. @@ -81,7 +81,7 @@ func TestNewRelicEachRowOfTheTable(t *testing.T) { } // Every DropIns entry is a member the table removes: a typo would quietly // turn its rename into a removal. - for _, d := range NewRelic11.DropIns { + for _, d := range NewRelic.DropIns { if got[d].change != event.PackageRenamedSymbol { t.Errorf("DropIns %q: not a rename (%+v)", d, got[d]) } @@ -101,7 +101,7 @@ func TestNewRelicDropsWhatIsNotARemovedMember(t *testing.T) { page := string(kittest.Read(t, newrelicSource)) // The lambda row: read, and dropped. - rs, err := Parse([]byte(page), NewRelic11) + rs, err := Parse([]byte(page), NewRelic) if err != nil { t.Fatal(err) } @@ -119,7 +119,7 @@ func TestNewRelicDropsWhatIsNotARemovedMember(t *testing.T) { if asList == page { t.Fatal("no lambda row in the saved release note") } - if names := readNames(t, asList, NewRelic11); !slices.Contains(names, "lambda_handler") || !slices.Contains(names, "LambdaHandlerWrapper") { + if names := readNames(t, asList, NewRelic); !slices.Contains(names, "lambda_handler") || !slices.Contains(names, "LambdaHandlerWrapper") { t.Errorf("with \"and\", the lambda row reads as %v: its drop proves nothing", names) } @@ -132,7 +132,7 @@ func TestNewRelicDropsWhatIsNotARemovedMember(t *testing.T) { if start < 0 || end < start { t.Fatal("the saved release note's shape changed") } - g := NewRelic11 + g := NewRelic g.Header = "Legacy Setting" settings, err := Parse([]byte(page[:start]+page[end:]), g) if err != nil { @@ -190,12 +190,12 @@ func TestDropInsLimitsRenames(t *testing.T) { "| `old_a` | [`new_a`](/a) |", "| `old_b` | `new_b` |", }, "\n") - g := Guide{API: "acme/sdk", Package: "acme", Module: "acme", Release: "2.0.0", Repo: "acme/acme", Path: "MIGRATION.md", + g := Guide{API: "acme/sdk", Package: "acme", Module: "acme", Repo: "acme/acme", Path: "MIGRATION.md", Section: "Removed", Format: FormatMarkdown, Header: "Removed", Paths: map[string]string{"old_a": "mod.old_a", "new_a": "mod.new_a"}} run := func(g Guide) map[string]string { out := map[string]string{} - for _, e := range release(t, g, writeTemp(t, page), "1.0.0") { + for _, e := range release(t, g, writeTemp(t, page), "1.9.0", "2.0.0") { out[e.Subject.Symbols[0]] = string(e.Subject.Change) + " " + e.Subject.Replacement } return out @@ -237,7 +237,7 @@ func readNames(t *testing.T, page string, g Guide) []string { // the saved excerpt. func newrelicIngest(t *testing.T) []event.Event { t.Helper() - return release(t, NewRelic11, newrelicSource, "10.17.0") + return release(t, NewRelic, newrelicSource, "10.17.0", "11.0.0") } // The hint is shown in a pull request or an issue, where a site-relative link diff --git a/plugins/migrationguide/members/posthog.go b/plugins/migrationguide/members/posthog.go index c22c1f3..162271e 100644 --- a/plugins/migrationguide/members/posthog.go +++ b/plugins/migrationguide/members/posthog.go @@ -1,7 +1,9 @@ package members -// PostHog8 is the posthog Python SDK's guide to 8.0.0, -// docs/migration-7.x-to-8.0.md at tag posthog-v8.0.0 (commit +// PostHog is the posthog Python SDK's guide to a major, +// docs/migration-{prev}.x-to-{major}.0.md at the major's first tag. The one +// there is so far (checked 2026-11-20) is 8.0.0's, docs/migration-7.x-to-8.0.md +// at tag posthog-v8.0.0 (commit // 6edff41425188056e48f6119457dc9bc0669ca99), and its "Fix removed APIs" // table: "8.x.x removes these options and APIs". The guide isn't in the repo // at posthog-v7.91.4, the release before, and is unchanged at posthog-v8.0.2. @@ -55,14 +57,18 @@ package members // 7 events. The guide's other tables (endpoints, AI lane arguments, error // fields, retries, dropped events, options, and "Rename deprecated settings", // whose old names still work) aren't under the heading, so they're never read. -var PostHog8 = Guide{ +// +// Paths, EnvVars and StillWork were checked against 8.0.0's table; a later +// major's names that aren't in them are read as the table writes them, and +// NewReplacements keeps every row with one replacement a removed_symbol (no +// rename the client would apply), so a new guide is read conservatively. +var PostHog = Guide{ API: "posthog/python-sdk", Package: "posthog", Module: "posthog", - Release: "8.0.0", TagPrefix: "posthog-v", Repo: "PostHog/posthog-python", - Path: "docs/migration-7.x-to-8.0.md", + Path: "docs/migration-{prev}.x-to-{major}.0.md", Section: "Fix removed APIs", Format: FormatMarkdown, Header: "Removed", @@ -76,6 +82,7 @@ var PostHog8 = Guide{ StillWork: map[string]string{ "capture_mode": `the guide's "Rename deprecated settings" table: posthog.capture_mode still works or has no effect in 8.x.x`, }, - // Every replacement in the table is new in 8.0.0. + // Every replacement in 8.0.0's table is new in 8.0.0; for a later major, + // a rename isn't known to be a drop-in until someone checks. NewReplacements: true, } diff --git a/plugins/migrationguide/members/posthog_test.go b/plugins/migrationguide/members/posthog_test.go index a140ae3..229ab76 100644 --- a/plugins/migrationguide/members/posthog_test.go +++ b/plugins/migrationguide/members/posthog_test.go @@ -18,7 +18,7 @@ import ( const posthogSource = "testdata/migration-7.x-to-8.0-posthog-v8.0.0.md" func TestPostHogRegistersItself(t *testing.T) { - kittest.Registered(t, migrationguide.Plugin{Guide: PostHog8}) + kittest.Registered(t, migrationguide.Plugin{Guide: PostHog}) } // The golden test: the saved guide in, every event out. @@ -85,7 +85,7 @@ func TestPostHogDropsWhatIsNotARemovedMember(t *testing.T) { // The table's own rows: an environment variable, an argument value, and // two rows of prose (a parameter, a dependency). With the rules off, each // is a row of the table, with names in code spans. - rs, err := Parse(kittest.Read(t, posthogSource), PostHog8) + rs, err := Parse(kittest.Read(t, posthogSource), PostHog) if err != nil { t.Fatal(err) } @@ -131,7 +131,7 @@ func TestPostHogDropsWhatIsNotARemovedMember(t *testing.T) { {"Update error handling", "Field", "drops"}, {"Move to event options", "Option", "cookieless_mode"}, } { - g := PostHog8 + g := PostHog g.Section, g.Header = other.section, other.header rs, err := Parse(kittest.Read(t, posthogSource), g) if err != nil { @@ -243,5 +243,5 @@ func TestMarkdownTable(t *testing.T) { // the saved guide. func posthogIngest(t *testing.T) []event.Event { t.Helper() - return release(t, PostHog8, posthogSource, "7.91.4") + return release(t, PostHog, posthogSource, "7.91.4", "8.0.0") } diff --git a/plugins/migrationguide/members/registered_test.go b/plugins/migrationguide/members/registered_test.go index 750b03f..d405937 100644 --- a/plugins/migrationguide/members/registered_test.go +++ b/plugins/migrationguide/members/registered_test.go @@ -10,5 +10,5 @@ import ( ) func TestRegistersItself(t *testing.T) { - kittest.Registered(t, migrationguide.Plugin{Guide: NumPy2}) + kittest.Registered(t, migrationguide.Plugin{Guide: NumPy}) } diff --git a/plugins/migrationguide/members/testdata/README.md b/plugins/migrationguide/members/testdata/README.md index 12bc3cf..f28767c 100644 --- a/plugins/migrationguide/members/testdata/README.md +++ b/plugins/migrationguide/members/testdata/README.md @@ -8,3 +8,5 @@ The golden files, `../../testdata/golden/{numpy-2.0.0,posthog-8.0.0,newrelic-11. | `migration-7.x-to-8.0-posthog-v8.0.0.md` | https://github.com/PostHog/posthog-python/blob/posthog-v8.0.0/docs/migration-7.x-to-8.0.md (commit 6edff41425188056e48f6119457dc9bc0669ca99) | 2026-11-19 | MIT (the repo's LICENSE is the MIT text, with two copyright lines, so GitHub's detector says NOASSERTION; PyPI says MIT), kept whole, byte for byte | "8.x.x removes these options and APIs:" (Fix removed APIs), with rows such as "\| `CaptureV1Error` \| `CaptureError` \|" | | `python-agent-110000-f0b4f817.mdx` | https://github.com/newrelic/docs-website/blob/f0b4f817bf9a7b76a78e26609369a8a7ce764c8e/src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx (the repo has no tags; the file's latest commit) | 2026-11-19 | Excerpt for testing; © New Relic, CC BY-NC-SA 4.0. Kept: the "## Removed features" heading, the bullets that introduce its two tables, the "Legacy API" table and the "Legacy Setting" table (lines 30-31 and 36-66 of 136), every line unchanged. Left out: the front matter, "Notes", the Python 3.7 bullet, and the "Deprecated features", "New features", "Bug fixes" and "Support statement" sections. The plugin finds the same 8 rows and 7 events in the excerpt as in the full file | "The following APIs have been removed:", with rows such as "\| `record_exception` \| [`notice_error()`](/docs/agents/python-agent/python-agent-api/notice_error) \|" | | `pypi-numpy-excerpt.json` | https://pypi.org/pypi/numpy/json (shape only) | written for the test, 2026-11-20 | not a saved copy: four releases in the shape of PyPI's JSON API (`releases` → files with `upload_time_iso_8601`, `yanked`), dates approximate, a pre-release among them | for the version-listing test only (ListVersions, consecutive pairs); no golden reads it | +| `github-commits-python-agent-110000.json` | https://api.github.com/repos/newrelic/docs-website/commits?path=src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx&per_page=1 (shape only) | written for the test, 2026-11-20 | not a saved copy: GitHub's commit list cut to the one field read (`sha`), naming the commit the note above was fetched at | for the guide's ref: the newest commit that changed the note | +| `github-commits-none.json` | the same request for a major with no note (shape only) | written for the test, 2026-11-20 | GitHub's answer for a path no commit changed: an empty list | for the "no guide, nothing to read" test | diff --git a/plugins/migrationguide/members/testdata/github-commits-none.json b/plugins/migrationguide/members/testdata/github-commits-none.json new file mode 100644 index 0000000..fe51488 --- /dev/null +++ b/plugins/migrationguide/members/testdata/github-commits-none.json @@ -0,0 +1 @@ +[] diff --git a/plugins/migrationguide/members/testdata/github-commits-python-agent-110000.json b/plugins/migrationguide/members/testdata/github-commits-python-agent-110000.json new file mode 100644 index 0000000..c6b44e0 --- /dev/null +++ b/plugins/migrationguide/members/testdata/github-commits-python-agent-110000.json @@ -0,0 +1 @@ +[{"sha": "f0b4f817bf9a7b76a78e26609369a8a7ce764c8e"}] diff --git a/plugins/migrationguide/members/versions_test.go b/plugins/migrationguide/members/versions_test.go index 1665e9a..42ac3cf 100644 --- a/plugins/migrationguide/members/versions_test.go +++ b/plugins/migrationguide/members/versions_test.go @@ -2,11 +2,14 @@ package members_test import ( "context" + "errors" "fmt" "strings" "testing" + "github.com/patch-it-dev/patch-it-plugins/core/fetch" "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" + "github.com/patch-it-dev/patch-it-plugins/core/plugin" "github.com/patch-it-dev/patch-it-plugins/core/versions" "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide" @@ -18,15 +21,15 @@ import ( func TestOnlyTheGuidesReleaseHasEvents(t *testing.T) { env := kittest.Env(t, kittest.Pages{ "https://pypi.org/pypi/numpy/json": "testdata/pypi-numpy-excerpt.json", - NumPy2.URL(): "testdata/numpy_2_0_migration_guide-v2.0.0.rst", + NumPy.RawURL("v2.0.0", 2): "testdata/numpy_2_0_migration_guide-v2.0.0.rst", }) - p := migrationguide.Plugin{Guide: NumPy2} + p := migrationguide.Plugin{Guide: NumPy} ctx := context.Background() vs, err := p.ListVersions(ctx, env) if err != nil { t.Fatal(err) } - pinned := release(t, NumPy2, "testdata/numpy_2_0_migration_guide-v2.0.0.rst", "1.26.4") + pinned := release(t, NumPy, "testdata/numpy_2_0_migration_guide-v2.0.0.rst", "1.26.4", "2.0.0") var got []string for _, pair := range versions.Pairs(vs) { from, err := p.ReadAt(ctx, env, pair[0]) @@ -54,11 +57,41 @@ func TestOnlyTheGuidesReleaseHasEvents(t *testing.T) { } } -// Each release's ref follows the guide's tag shape. -func TestTagsFollowTheGuide(t *testing.T) { - for g, want := range map[*Guide]string{&NumPy2: "v2.0.0", &PostHog8: "posthog-v8.0.0", &NewRelic11: "f0b4f817bf9a7b76a78e26609369a8a7ce764c8e"} { - if got := g.Tag(); got != want { - t.Errorf("%s: tag %q, want %q", g.Package, got, want) +// Each guide is read where its package publishes it: at the major's first +// tag (TagPrefix + version), or, for a docs repo with no tags, at the newest +// commit that changed the major's note. +func TestEachGuideIsReadWhereItsPublished(t *testing.T) { + ctx := context.Background() + for _, c := range []struct { + g Guide + rel string + want string + }{ + {NumPy, "2.0.0", "https://raw.githubusercontent.com/numpy/numpy/v2.0.0/doc/source/numpy_2_0_migration_guide.rst"}, + {PostHog, "8.0.0", "https://raw.githubusercontent.com/PostHog/posthog-python/posthog-v8.0.0/docs/migration-7.x-to-8.0.md"}, + {NewRelic, "11.0.0", "https://raw.githubusercontent.com/newrelic/docs-website/" + newrelicCommit + "/src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx"}, + } { + got, err := c.g.GuideURL(ctx, guideEnv(t, c.g, "testdata/README.md", c.rel), plugin.Version{ID: c.rel}) + if err != nil || got != c.want { + t.Errorf("%s %s: %q, %v; want %q", c.g.Package, c.rel, got, err, c.want) + } + if got, err := c.g.GuideURL(ctx, plugin.Env{}, plugin.Version{ID: c.rel[:len(c.rel)-1] + "1"}); got != "" || err != nil { + t.Errorf("%s: a release that isn't a major's first has no guide: %q, %v", c.g.Package, got, err) } } } + +// A major with no guide has nothing to read: a 404 at its tag, or (docs +// repo) no commit ever changed its note's path. The pair is skipped, not +// failed, and not a release without changes. +func TestAMajorWithNoGuideHasNothingToRead(t *testing.T) { + ctx := context.Background() + env := kittest.Env(t, kittest.Pages{NewRelic.CommitsURL(14): "testdata/github-commits-none.json"}) + if _, err := (migrationguide.Plugin{Guide: NewRelic}).ReadAt(ctx, env, plugin.Version{ID: "14.0.0"}); !errors.Is(err, plugin.ErrNothingToRead) { + t.Errorf("no commit for the note: %v, want plugin.ErrNothingToRead", err) + } + notFound := plugin.Env{Get: func(context.Context, string) ([]byte, error) { return nil, &fetch.StatusError{StatusCode: 404} }} + if _, err := (migrationguide.Plugin{Guide: NumPy}).ReadAt(ctx, notFound, plugin.Version{ID: "3.0.0"}); !errors.Is(err, plugin.ErrNothingToRead) { + t.Errorf("no guide at the tag: %v, want plugin.ErrNothingToRead", err) + } +} diff --git a/plugins/migrationguide/migrationguide.go b/plugins/migrationguide/migrationguide.go index df864b6..fa95a49 100644 --- a/plugins/migrationguide/migrationguide.go +++ b/plugins/migrationguide/migrationguide.go @@ -13,10 +13,12 @@ package migrationguide import ( "context" + "errors" "fmt" "time" "github.com/patch-it-dev/patch-it-plugins/core/event" + "github.com/patch-it-dev/patch-it-plugins/core/fetch" "github.com/patch-it-dev/patch-it-plugins/core/plugin" "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide/members" "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide/sdkguide" @@ -37,30 +39,30 @@ func init() { ID: "numpy", Name: "NumPy", Category: plugin.CategoryPackages, Homepage: "https://numpy.org", Sources: []plugin.Source{{ ID: "numpy", Layer: plugin.LayerPackage, Page: "providers/numpy.md", - Watches: "Members removed or renamed in the main namespace in NumPy 2.0", - URLs: []string{"https://github.com/numpy/numpy/blob/v2.0.0/doc/source/numpy_2_0_migration_guide.rst"}, + Watches: "Members a new major removes or renames in the main namespace, from that major's migration guide at its first tag", + URLs: []string{"https://numpy.org/devdocs/numpy_2_0_migration_guide.html", "https://pypi.org/project/numpy/"}, Packages: []string{"pypi:numpy"}, - Plugin: Plugin{Guide: members.NumPy2}, + Plugin: Plugin{Guide: members.NumPy}, }}, }) plugin.RegisterProvider(plugin.Provider{ ID: "posthog", Name: "PostHog", Category: plugin.CategoryAnalytics, Homepage: "https://posthog.com", Sources: []plugin.Source{{ ID: "python-sdk", Layer: plugin.LayerSDK, Page: "providers/posthog.md", - Watches: "Members removed in the posthog Python SDK 8.0.0", - URLs: []string{"https://github.com/PostHog/posthog-python/blob/posthog-v8.0.0/docs/migration-7.x-to-8.0.md"}, + Watches: "Members a new major of the posthog Python SDK removes, from its migration guide in docs/ at the major's first tag", + URLs: []string{"https://github.com/PostHog/posthog-python/tree/main/docs", "https://pypi.org/project/posthog/"}, Packages: []string{"pypi:posthog"}, - Plugin: Plugin{Guide: members.PostHog8}, + Plugin: Plugin{Guide: members.PostHog}, }}, }) plugin.RegisterProvider(plugin.Provider{ ID: "newrelic", Name: "New Relic", Category: plugin.CategoryMonitoring, Homepage: "https://newrelic.com", Sources: []plugin.Source{{ ID: "python-agent", Layer: plugin.LayerSDK, Page: "providers/newrelic.md", - Watches: "Members removed in the New Relic Python agent 11.0.0", - URLs: []string{"https://github.com/newrelic/docs-website/blob/f0b4f817bf9a7b76a78e26609369a8a7ce764c8e/src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx"}, + Watches: "Members a new major of the New Relic Python agent removes, from the major's release notes (Removed features)", + URLs: []string{"https://docs.newrelic.com/docs/release-notes/agent-release-notes/python-release-notes/", "https://pypi.org/project/newrelic/"}, Packages: []string{"pypi:newrelic"}, - Plugin: Plugin{Guide: members.NewRelic11}, + Plugin: Plugin{Guide: members.NewRelic}, }}, }) } @@ -74,13 +76,13 @@ type Guide interface { // Releases are the versions, oldest first, each with the ref its guide // would be read at. Releases(ctx context.Context, env plugin.Env) ([]plugin.Version, error) - // GuideURL is where the guide is at v, pinned to v's tag, or "" when v - // has no guide (a release that isn't a new major). - GuideURL(v plugin.Version) string - // Read turns the guide, as read at to, into events with + // GuideURL is where the guide is at v, pinned to v's tag (or a commit), + // or "" when v has no guide (a release that isn't a new major). + GuideURL(ctx context.Context, env plugin.Env, v plugin.Version) (string, error) + // Read turns the guide, as read at to from sourceURL, into events with // previous_version from, and the rows that failed to become events. err // is a guide it can't read. - Read(page []byte, from, to plugin.Version, now time.Time) (events []event.Event, rejected []error, err error) + Read(page []byte, sourceURL string, from, to plugin.Version, now time.Time) (events []event.Event, rejected []error, err error) } // Plugin reads one source's migration guide. @@ -96,13 +98,22 @@ func (p Plugin) ListVersions(ctx context.Context, env plugin.Env) ([]plugin.Vers } // ReadAt fetches the guide at v; a release with no guide reads as nothing (a -// snapshot with no content). +// snapshot with no content). A new major whose guide isn't there (a 404 at +// its tag) has nothing to read: plugin.ErrNothingToRead, so the pair is +// kept as skipped, not as a failure, nor as a release with no changes. func (p Plugin) ReadAt(ctx context.Context, env plugin.Env, v plugin.Version) (plugin.Snapshot, error) { - url := p.Guide.GuideURL(v) + url, err := p.Guide.GuideURL(ctx, env, v) + if err != nil { + return plugin.Snapshot{}, err + } if url == "" { return plugin.Snapshot{Version: v}, nil } page, err := env.Get(ctx, url) + var se *fetch.StatusError + if errors.As(err, &se) && se.StatusCode == 404 { + return plugin.Snapshot{}, fmt.Errorf("no guide at %s: %w", url, plugin.ErrNothingToRead) + } if err != nil { return plugin.Snapshot{}, fmt.Errorf("fetching %s: %w", url, err) } @@ -115,7 +126,7 @@ func (p Plugin) Extract(_ context.Context, env plugin.Env, from, to plugin.Snaps if to.Content == nil { return plugin.Result{}, nil } - events, rejected, err := p.Guide.Read(to.Content, from.Version, to.Version, env.Now().UTC()) + events, rejected, err := p.Guide.Read(to.Content, to.SourceURL, from.Version, to.Version, env.Now().UTC()) if err != nil { return plugin.Result{}, fmt.Errorf("reading %s: %w", to.SourceURL, err) } diff --git a/plugins/migrationguide/migrationguide_test.go b/plugins/migrationguide/migrationguide_test.go index 4b7badc..c193d15 100644 --- a/plugins/migrationguide/migrationguide_test.go +++ b/plugins/migrationguide/migrationguide_test.go @@ -3,15 +3,13 @@ package migrationguide import ( "strings" "testing" - - "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide/sdkguide" ) func TestAMigrationGuideStoresOneEventPerRemovedParameter(t *testing.T) { // Only the v1.0.0 tag is saved: fetching anything else fails the test, and // kittest's second extract of the pair must store nothing new. var params []string - for _, e := range anthropicV1(t, sdkguide.AnthropicV1) { + for _, e := range anthropicV1(t, anthropicGuideV1) { params = append(params, e.Subject.Parameter) } if strings.Join(params, ",") != "temperature,top_p,top_k" { diff --git a/plugins/migrationguide/registered_test.go b/plugins/migrationguide/registered_test.go index acd1ca5..3b659bb 100644 --- a/plugins/migrationguide/registered_test.go +++ b/plugins/migrationguide/registered_test.go @@ -4,9 +4,8 @@ import ( "testing" "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" - "github.com/patch-it-dev/patch-it-plugins/plugins/migrationguide/sdkguide" ) func TestRegistersItself(t *testing.T) { - kittest.Registered(t, Plugin{Guide: sdkguide.AnthropicV1}) + kittest.Registered(t, Plugin{Guide: anthropicGuideV1}) } diff --git a/plugins/migrationguide/sdkguide/pinned_test.go b/plugins/migrationguide/sdkguide/pinned_test.go new file mode 100644 index 0000000..f914705 --- /dev/null +++ b/plugins/migrationguide/sdkguide/pinned_test.go @@ -0,0 +1,5 @@ +package sdkguide + +// AnthropicV1 is anthropic-sdk-python's guide to 1.0.0: what the tests pin. +// Only a test names a release. +var AnthropicV1 = Anthropic.At(1) diff --git a/plugins/migrationguide/sdkguide/sdkguide.go b/plugins/migrationguide/sdkguide/sdkguide.go index ddf9219..cc02580 100644 --- a/plugins/migrationguide/sdkguide/sdkguide.go +++ b/plugins/migrationguide/sdkguide/sdkguide.go @@ -47,9 +47,6 @@ var Anthropic = Guide{ Symbols: []string{"messages.create", "messages.stream", "messages.parse"}, } -// AnthropicV1 is anthropic-sdk-python's guide to 1.0.0: what the golden pins. -var AnthropicV1 = Anthropic.At(1) - // At is g pinned to one major. func (g Guide) At(major int) Guide { g.Major = major diff --git a/plugins/migrationguide/sdkguide/versions.go b/plugins/migrationguide/sdkguide/versions.go index 20aa99e..7a7f5fe 100644 --- a/plugins/migrationguide/sdkguide/versions.go +++ b/plugins/migrationguide/sdkguide/versions.go @@ -2,7 +2,6 @@ package sdkguide import ( "context" - "fmt" "time" "github.com/patch-it-dev/patch-it-plugins/core/event" @@ -34,16 +33,17 @@ func (g Guide) Releases(ctx context.Context, env plugin.Env) ([]plugin.Version, // GuideURL is the guide at v's tag when v is the first release of its major // (X.0.0): only a new major has a guide to read. Any other release has none // (""). -func (g Guide) GuideURL(v plugin.Version) string { - if !FirstOfMajor(v.ID) { - return "" +func (g Guide) GuideURL(_ context.Context, _ plugin.Env, v plugin.Version) (string, error) { + if !versions.FirstOfMajor(v.ID) { + return "", nil } - return g.At(versions.Major(v.ID)).URL() + return g.At(versions.Major(v.ID)).URL(), nil } // Read is an event per parameter the to major removed, read from its -// guide, with previous_version from's release. -func (g Guide) Read(page []byte, from, to plugin.Version, now time.Time) (_ []event.Event, rejected []error, err error) { +// guide (at the major's tag: sourceURL), with previous_version from's +// release. +func (g Guide) Read(page []byte, _ string, from, to plugin.Version, now time.Time) (_ []event.Event, rejected []error, err error) { g = g.At(versions.Major(to.ID)) removals, err := Parse(page, g) if err != nil { @@ -52,9 +52,3 @@ func (g Guide) Read(page []byte, from, to plugin.Version, now time.Time) (_ []ev events, errs := Events(g, removals, from.ID, now) return events, errs, nil } - -// FirstOfMajor is true for X.0.0, the release a major's guide is tagged at. -func FirstOfMajor(v string) bool { - m := versions.Major(v) - return m > 0 && v == fmt.Sprintf("%d.0.0", m) -} diff --git a/plugins/migrationguide/versions_test.go b/plugins/migrationguide/versions_test.go index 7a10faf..9a39cd5 100644 --- a/plugins/migrationguide/versions_test.go +++ b/plugins/migrationguide/versions_test.go @@ -17,7 +17,7 @@ import ( func TestOnlyANewMajorHasAGuide(t *testing.T) { env := kittest.Env(t, kittest.Pages{ "https://pypi.org/pypi/anthropic/json": "testdata/pypi-anthropic-excerpt.json", - sdkguide.AnthropicV1.URL(): "sdkguide/testdata/anthropic-MIGRATION-v1.0.0.md", + anthropicGuideV1.URL(): "sdkguide/testdata/anthropic-MIGRATION-v1.0.0.md", }) p := Plugin{Guide: sdkguide.Anthropic} ctx := context.Background() diff --git a/plugins/notices/eol/eol.go b/plugins/notices/eol/eol.go index b4cc78b..4c9d852 100644 --- a/plugins/notices/eol/eol.go +++ b/plugins/notices/eol/eol.go @@ -10,14 +10,15 @@ // says what the plugin actually saw. // // Salesforce's docs site is the one difference from the other notices -// readers: it answers 403 to a plain GET (checked 2026-11-20, including with -// a browser User-Agent), so a direct read of the live page fails every time. The -// Wayback Machine's own save-page-now request succeeds against it anyway, -// and its capture parses to the same findings the live page would (checked -// the same day), so the kind falls back to a fresh snapshot on a 401 or 403 -// (ArchiveWhenBlocked), +// readers: it blocks a plain GET, with 403 (checked 2026-11-20, including +// with a browser User-Agent) or, from its CDN (AkamaiNetStorage), 503 +// (checked 2026-11-21), so a direct read of the live page fails every time. +// The Wayback Machine's own crawler reads it anyway (its capture of +// 2026-11-20 parses to the same findings the live page would), so the kind +// falls back to a fresh snapshot on those statuses (ArchiveWhenBlocked), // used directly as both the content and its own citation, kit.Cite's // double-check skipped: there is no separate live read left to agree with. +// A snapshot that can't be taken, or holds no table, fails the run. // // Unlike retirements (one named model per row) and feed (an RSS or Atom // entry), a row here names a whole range of version numbers and no @@ -191,10 +192,10 @@ func (pg Page) Find(page []byte) (kit.Notices, error) { return Read(fs), err } -// ArchiveWhenBlocked is on: Salesforce's docs site answers 403 to a plain -// GET, so the kind reads a fresh Wayback Machine snapshot instead (see the -// package comment). -func (Page) ArchiveWhenBlocked() bool { return true } +// ArchiveWhenBlocked is the statuses Salesforce's docs site blocks a plain +// GET with (401 and 403; 503 from its CDN), so the kind reads a fresh +// Wayback Machine snapshot instead (see the package comment). +func (Page) ArchiveWhenBlocked() []int { return []int{401, 403, 503} } // Events are an event per version number a row retires or deprecates, // citing citeURL, with previous as previous_version (each is an diff --git a/plugins/notices/eol_test.go b/plugins/notices/eol_test.go index 53558e4..f0135a4 100644 --- a/plugins/notices/eol_test.go +++ b/plugins/notices/eol_test.go @@ -2,11 +2,13 @@ package notices import ( "context" + "errors" "fmt" "testing" "time" "github.com/patch-it-dev/patch-it-plugins/core/fetch" + "github.com/patch-it-dev/patch-it-plugins/core/kit" "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" "github.com/patch-it-dev/patch-it-plugins/core/plugin" "github.com/patch-it-dev/patch-it-plugins/plugins/notices/eol" @@ -60,12 +62,12 @@ func TestDropsAStillSupportedBand(t *testing.T) { } } -// eol.Salesforce's docs site answers 403 to a plain GET; the live page is never -// reachable through env.Get. Read must fall back to the Wayback Machine's own -// fetch and use its snapshot directly, not fail outright. 401 falls back the -// same way. +// eol.Salesforce's docs site answers 403 to a plain GET, or 503 from its CDN; +// the live page is never reachable through env.Get. Read must fall back to +// the Wayback Machine's own fetch and use its snapshot directly, not fail +// outright. 401 falls back the same way. func TestFallsBackToTheArchiveWhenTheLiveFetchIsBlocked(t *testing.T) { - for _, code := range []int{401, 403} { + for _, code := range []int{401, 403, 503} { t.Run(fmt.Sprint(code), func(t *testing.T) { saved := kittest.Pages{eol.Salesforce.URL: "eol/testdata/salesforce-api-rest-eol-2026-10-31.html"} archive := &kittest.Archive{T: t, Pages: saved} @@ -97,10 +99,10 @@ func TestFallsBackToTheArchiveWhenTheLiveFetchIsBlocked(t *testing.T) { } // A real failure (not the provider blocking a plain fetch) must stay a -// failure: falling back to the archive for a timeout or a 5xx would hide it -// as a real page. +// failure: falling back to the archive for a timeout, a moved page or a 5xx +// the reader doesn't name would hide it as a real page. func TestDoesNotFallBackOnATransientError(t *testing.T) { - for _, code := range []int{404, 429, 503} { + for _, code := range []int{404, 429, 500, 502} { t.Run(fmt.Sprint(code), func(t *testing.T) { env := plugin.Env{ Get: func(context.Context, string) ([]byte, error) { @@ -117,3 +119,37 @@ func TestDoesNotFallBackOnATransientError(t *testing.T) { }) } } + +// A blocked page that the archive can't capture, or whose capture holds no +// table (a block page saved in its place), fails the read: the run records +// an error, never "nothing changed" and never a skip. +func TestABlockedPageTheArchiveCantReadIsAFailedRun(t *testing.T) { + blocked := plugin.Env{ + Get: func(context.Context, string) ([]byte, error) { + return nil, &fetch.StatusError{URL: eol.Salesforce.URL, StatusCode: 403} + }, + Now: func() time.Time { return kittest.Clock }, + } + last := plugin.Snapshot{Version: plugin.Version{ID: "2026-11-01T00:00:00Z"}, Content: []byte("
"), CompareHash: "x"} + for name, archive := range map[string]kit.Archiver{ + "no snapshot": failingArchive{}, + "a block page": blockPage{}, + } { + _, err := Plugin{Page: eol.Salesforce, Archiver: archive}.Read(context.Background(), blocked, last) + if err == nil || errors.Is(err, plugin.ErrNothingToRead) { + t.Errorf("%s: %v, want a failure that isn't plugin.ErrNothingToRead", name, err) + } + } +} + +type failingArchive struct{} + +func (failingArchive) Snapshot(context.Context, string) (string, []byte, error) { + return "", nil, errors.New("the Wayback Machine didn't snapshot it") +} + +type blockPage struct{} + +func (blockPage) Snapshot(_ context.Context, u string) (string, []byte, error) { + return "https://web.archive.org/web/20261121000000/" + u, []byte("Access Denied"), nil +} diff --git a/plugins/notices/google_test.go b/plugins/notices/google_test.go new file mode 100644 index 0000000..7ea3e49 --- /dev/null +++ b/plugins/notices/google_test.go @@ -0,0 +1,94 @@ +package notices + +import ( + "os" + "strings" + "testing" + + "github.com/patch-it-dev/patch-it-plugins/core/kit/kittest" + "github.com/patch-it-dev/patch-it-plugins/plugins/notices/retire" +) + +// section is the saved page from start up to end (to the end of the page +// when end is ""), as a page of its own. +func section(t *testing.T, file, start, end string) string { + t.Helper() + b, err := os.ReadFile(file) + if err != nil { + t.Fatal(err) + } + s := string(b) + i := strings.Index(s, start) + if i < 0 { + t.Fatalf("%s: the saved page's shape changed", file) + } + if end == "" { + return s[i:] + } + j := strings.Index(s[i+1:], end) + if j < 0 { + t.Fatalf("%s: the saved page's shape changed", file) + } + return s[i : i+1+j] +} + +// readGoogle is a first read of page, served as content, through the kind. +func readGoogle(t *testing.T, page retire.Page, content string) int { + t.Helper() + f := t.TempDir() + "/page" + if err := os.WriteFile(f, []byte(content), 0o644); err != nil { + t.Fatal(err) + } + saved := kittest.Pages{page.URL: f} + return len(kittest.Page(t, kittest.Env(t, saved), Plugin{Page: page, Archiver: &kittest.Archive{T: t, Pages: saved}})) +} + +// The pinned drop test for the Gemini API page: the Gemini 4 models (no +// shutdown date announced) and the managed agents, whose deprecated table +// has real dates but names agents, not models, next to the two Gemini 3 +// models shut down already. Only those two are events; the agents' table +// renamed to "Model" would give two more, so the header is what keeps it +// out. +func TestGeminiDropsModelsWithNoDateAndAgents(t *testing.T) { + const file = "retire/testdata/gemini-deprecations.md" + current := section(t, file, "## Gemini 4 models", "## Gemini 3 models") + retired := section(t, file, "### Deprecated models {% id=\"gemini-3-deprecated-models\" %}", "## Gemini 2.5 Pro models") + agents := section(t, file, "## Managed agents", "") + if n := readGoogle(t, retire.Gemini, current+retired+agents); n != 2 { + t.Errorf("%d events, want the 2 shut-down Gemini 3 models only", n) + } + if _, err := retire.Parse(retire.Gemini.Format.Pipes([]byte(agents)), retire.Gemini.Keep); err == nil { + t.Error("the agents' tables read as retirements") + } + asModels := strings.ReplaceAll(agents, " * Agent\n", " * Model\n") + if rs, err := retire.Parse(retire.Gemini.Format.Pipes([]byte(asModels)), retire.Gemini.Keep); err != nil || len(rs) != 2 { + t.Errorf("the agents' table with a Model header: %d, %v; the drop proves nothing", len(rs), err) + } +} + +// The pinned drop test for Vertex AI: a GA model's "June 28, 2027 or +// later" is how long it's kept at least, not a retirement. The Gemini image +// models' table has four such rows and one dated retirement +// (gemini-2.5-flash-image, March 15, 2027): one event. The same table with +// the dates plain would give five. +func TestVertexDropsAMinimumLifetime(t *testing.T) { + ga := section(t, "retire/testdata/vertex-model-versions.html", `

0 { + rows = append(rows, cur) + cur = nil + } + } + for _, line := range strings.Split(strings.ReplaceAll(string(page), "\r\n", "\n"), "\n") { + t := strings.TrimSpace(line) + switch { + case !in && strings.HasPrefix(t, "#"): + if m := markdocHeading.FindStringSubmatch(t); m != nil { + out = append(out, m[1]) + } + case !in && t == "{% table %}": + in, rows, cur = true, nil, nil + case in && t == "{% /table %}": + flush() + out = append(out, pipeTable(rows)...) + in = false + case in && t == "---": + flush() + case in && strings.HasPrefix(t, "*"): + cur = append(cur, strings.TrimSpace(markdocCell.FindStringSubmatch(line)[1])) + case in && t != "" && len(cur) > 0: + // A cell's text continued on the next line. + cur[len(cur)-1] += " " + t + } + } + return []byte(strings.Join(out, "\n") + "\n") +} + +var ( + htmlTable = regexp.MustCompile(`(?is)]*>(.*?)|]*>(.*?)`) + htmlRow = regexp.MustCompile(`(?is)]*>(.*?)`) + htmlCell = regexp.MustCompile(`(?is)]*>(.*?)`) + htmlCode = regexp.MustCompile(`(?is)]*>(.*?)`) + htmlTag = regexp.MustCompile(`<[^>]+>`) + htmlNewline = regexp.MustCompile(`\s+`) +) + +// htmlPipes reads an HTML page's tables into pipe tables, each under the +// heading above it; becomes a code span, every other tag goes. +func htmlPipes(page []byte) []byte { + var out []string + for _, m := range htmlTable.FindAllStringSubmatch(string(page), -1) { + if m[1] != "" { + level, _ := strconv.Atoi(m[1]) + out = append(out, strings.Repeat("#", level)+" "+htmlText(m[2])) + continue + } + var rows [][]string + for _, r := range htmlRow.FindAllStringSubmatch(m[3], -1) { + var row []string + for _, c := range htmlCell.FindAllStringSubmatch(r[1], -1) { + row = append(row, htmlText(htmlCode.ReplaceAllString(c[1], "`$1`"))) + } + if len(row) > 0 { + rows = append(rows, row) + } + } + out = append(out, pipeTable(rows)...) + } + return []byte(strings.Join(out, "\n") + "\n") +} + +func htmlText(s string) string { + return strings.TrimSpace(htmlNewline.ReplaceAllString(html.UnescapeString(htmlTag.ReplaceAllString(s, " ")), " ")) +} + +// pipeTable writes rows (the first the header) as a Markdown pipe table, +// escaping a pipe inside a cell. +func pipeTable(rows [][]string) []string { + if len(rows) == 0 { + return nil + } + line := func(cells []string) string { + esc := make([]string, len(cells)) + for i, c := range cells { + esc[i] = strings.ReplaceAll(c, "|", `\|`) + } + return "| " + strings.Join(esc, " | ") + " |" + } + out := []string{"", line(rows[0]), "|" + strings.Repeat(" --- |", len(rows[0]))} + for _, r := range rows[1:] { + out = append(out, line(r)) + } + return append(out, "") +} diff --git a/plugins/notices/retire/notices.go b/plugins/notices/retire/notices.go index 637239a..9b941b8 100644 --- a/plugins/notices/retire/notices.go +++ b/plugins/notices/retire/notices.go @@ -23,7 +23,7 @@ func (p Page) PageURL() string { return p.URL } // Find reads every retirement on the page. func (p Page) Find(page []byte) (kit.Notices, error) { - rs, err := Parse(page, p.Keep) + rs, err := Parse(p.Format.Pipes(page), p.Keep) return Retirements(rs), err } diff --git a/plugins/notices/retire/providers.go b/plugins/notices/retire/providers.go index 61fbc03..882cdf0 100644 --- a/plugins/notices/retire/providers.go +++ b/plugins/notices/retire/providers.go @@ -1,6 +1,9 @@ package retire -import "strings" +import ( + "regexp" + "strings" +) // OpenAI's deprecations page (checked 2026-10-13). Its tables cover every // kind of model; these events are for the text models the Chat Completions @@ -46,3 +49,40 @@ func openAIText(name string) bool { } return false } + +// googleModel is a model id as code sends it, nothing around it: a cell +// with a footnote mark ("textembedding-gecko@003 *") isn't read. +var googleModel = regexp.MustCompile(`^[a-z0-9][a-z0-9.@_-]*$`) + +// Gemini is the Gemini API's deprecations page (ai.google.dev, served by +// aistudio.google.com as markdown, checked 2026-11-21): one Markdoc table per +// model family, | Model | Release date | Shutdown date | Recommended +// replacement |, current models with "No shutdown date announced", shut-down +// ones under "Deprecated models". Every model there is one code names in a +// request (text, image, video, audio, embedding: all through the same SDK); +// the managed agents' tables name an agent, not a model, and are skipped. +// Google says its dates are the earliest a model may be shut down. +var Gemini = Page{ + API: "google/gemini-models", + Provider: "google", + Vendor: "Google", + URL: "https://aistudio.google.com/docs/deprecations", + Format: FormatMarkdoc, + Keep: googleModel.MatchString, + Earliest: true, +} + +// Vertex is Google Cloud's Vertex AI model versions page (checked +// 2026-11-21): HTML tables of | Model ID | Release date | Retirement date | +// Replacement model ID | (or Recommended upgrade). A GA model's date is a +// minimum lifetime ("October 13, 2027 or later", "No sooner than May 20, +// 2028"), not a notice, and isn't read as a date; a retired or retiring +// model's is a plain date ("June 30, 2026"). +var Vertex = Page{ + API: "google/vertex-model-retirements", + Provider: "google", + Vendor: "Google", + URL: "https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + Format: FormatHTML, + Keep: googleModel.MatchString, +} diff --git a/plugins/notices/retire/retire.go b/plugins/notices/retire/retire.go index f934b18..16d383a 100644 --- a/plugins/notices/retire/retire.go +++ b/plugins/notices/retire/retire.go @@ -3,11 +3,16 @@ // OpenAPI differ. There is no spec to diff, only the provider's own table of // shutdown date, model and named replacement, so this reads the table. // -// Both providers serve the page as markdown at its URL plus ".md" (checked -// 2026-10-13), and both write each announcement as a table whose first column -// is the date the model stops working. The event cites a Wayback Machine -// snapshot of that markdown (kit/), never the live page: the contract -// requires a source that can't change under the event. +// A page is a Markdown pipe table (OpenAI's and Anthropic's pages, served as +// markdown at their URL plus ".md", checked 2026-10-13), a Markdoc table +// (Google's Gemini API page, {% table %} with one "* cell" per line, checked +// 2026-11-21), or an HTML table (Google Cloud's Vertex AI model versions, +// checked 2026-11-21). The last two are read into pipe rows first, with +// their headings, so one parser reads every page. A table is a retirement +// table when it has a shutdown or retirement date column, a model column and +// a replacement column, in any order. The event cites a Wayback Machine +// snapshot of the page (kit/), never the live page: the contract requires a +// source that can't change under the event. package retire import ( @@ -25,12 +30,28 @@ type Page struct { API string // the source id the events carry: "openai/models" Provider string // the model subject's provider: "openai" Vendor string // for sentences: "OpenAI" - URL string // the page as markdown + URL string // the page, as markdown or HTML + // Format is how the page writes its tables: Markdown pipe tables (the + // default), Markdoc or HTML. + Format Format // Keep says whether a model name belongs to this source: the operations // above take text models, not image, audio or embedding ones. Keep func(name string) bool + // Earliest says the page's dates are the earliest a model may be shut + // down, not the day it is (Google's Gemini API page): the description + // says so. + Earliest bool } +// Format is how a page writes its tables. +type Format string + +const ( + FormatMarkdown Format = "" + FormatMarkdoc Format = "markdoc" + FormatHTML Format = "html" +) + // Retirement is one model name the provider stops serving on Date, with the // replacement it names. An alias gets its own Retirement, with the row it // came from. @@ -47,6 +68,18 @@ var ( ticked = regexp.MustCompile("`([^`]+)`") ) +// Pipes is the page's tables as Markdown pipe tables, each under the +// heading above it: the page itself when it's Markdown. +func (f Format) Pipes(page []byte) []byte { + switch f { + case FormatMarkdoc: + return markdocPipes(page) + case FormatHTML: + return htmlPipes(page) + } + return page +} + var dateLayouts = []string{"January 2, 2006", "Jan 2, 2006", "2006-01-02"} // Parse reads every retirement table on the page. A model listed more than @@ -57,6 +90,7 @@ var dateLayouts = []string{"January 2, 2006", "Jan 2, 2006", "2006-01-02"} // points at a model that no longer works. func Parse(page []byte, keep func(string) bool) ([]Retirement, error) { lines := strings.Split(strings.ReplaceAll(string(page), "\r\n", "\n"), "\n") + headerAt := 0 var out []Retirement seen := map[string]bool{} heading := "" @@ -67,23 +101,31 @@ func Parse(page []byte, keep func(string) bool) ([]Retirement, error) { continue } header := cells(line) - if len(header) < 3 || !dateHeader.MatchString(header[0]) { + when := -1 + for c, h := range header { + if dateHeader.MatchString(h) { + when = c + break + } + } + if len(header) < 3 || when < 0 { continue } - model, repl := column(header, "model"), column(header, "replacement", "substitute") - if model < 0 || repl < 0 { - continue // an endpoint ("System") or a training-price table: no model to replace + model, repl := column(header, "model"), column(header, "replacement", "substitute", "upgrade") + if model < 0 || repl < 0 || model == repl { + continue // an endpoint ("System"), an agent or a training-price table: no model to replace } + headerAt = i i++ // the |---| row for i+1 < len(lines) && strings.HasPrefix(strings.TrimSpace(lines[i+1]), "|") { i++ row := strings.TrimSpace(lines[i]) c := cells(row) - if len(c) <= model || len(c) <= repl { + if len(c) <= model || len(c) <= repl || len(c) <= when { return nil, fmt.Errorf("a short row under %q: %s", heading, row) } names := ticked.FindAllStringSubmatch(c[model], -1) - date, err := parseDate(c[0]) + date, err := parseDate(c[when]) if err != nil { // "To be announced": not a retirement yet, and the newer word on // these names, so an older row's date for them doesn't count. @@ -92,7 +134,7 @@ func Parse(page []byte, keep func(string) bool) ([]Retirement, error) { } continue } - excerpt := strings.Join([]string{heading, strings.TrimSpace(lines[headerLine(lines, i)]), row}, "\n") + excerpt := strings.Join([]string{heading, strings.TrimSpace(lines[headerAt]), row}, "\n") for _, m := range names { name := m[1] if seen[name] || !keep(name) { @@ -110,14 +152,6 @@ func Parse(page []byte, keep func(string) bool) ([]Retirement, error) { return out, nil } -// headerLine walks back from a row to its table's header. -func headerLine(lines []string, i int) int { - for i > 0 && strings.HasPrefix(strings.TrimSpace(lines[i-1]), "|") { - i-- - } - return i -} - // follow replaces a replacement that is itself retired with its own // replacement, recording the hops: gpt-3.5-turbo-0613's named replacement is // gpt-3.5-turbo, which shuts down on 2026-10-23 for gpt-5.6-terra. @@ -173,8 +207,8 @@ func cells(row string) []string { } func column(header []string, words ...string) int { - for i, h := range header { - for _, w := range words { + for _, w := range words { + for i, h := range header { if strings.Contains(strings.ToLower(h), w) { return i } @@ -211,7 +245,7 @@ func Events(p Page, rs []Retirement, sourceURL string, now time.Time) ([]event.E ChangeType: event.ChangeTypeBreaking, Breaking: true, Subject: subject, - Description: fmt.Sprintf("Model %q is shut down on %s: %s requests naming it fail from that date.", r.Model, r.Date, p.Vendor), + Description: describe(p, r), MigrationHint: h, SourceURL: sourceURL, SourceExcerpt: r.Excerpt, @@ -227,6 +261,13 @@ func Events(p Page, rs []Retirement, sourceURL string, now time.Time) ([]event.E return events, errs } +func describe(p Page, r Retirement) string { + if p.Earliest { + return fmt.Sprintf("Model %q can be shut down from %s, the earliest date %s gives: %s requests naming it fail once it is.", r.Model, r.Date, p.Vendor, p.Vendor) + } + return fmt.Sprintf("Model %q is shut down on %s: %s requests naming it fail from that date.", r.Model, r.Date, p.Vendor) +} + // replacement is the one model the provider names, when its replacement cell // is exactly one model name: not none, not several, not a model with a // setting (`gpt-5.6-sol` (`reasoning.mode: pro`)). The patch-it client opens @@ -242,6 +283,9 @@ func replacement(cell string) string { func hint(vendor string, r Retirement) string { repl := strings.TrimSpace(r.Replacement) + if repl == "" { + return fmt.Sprintf("%s names no replacement model.", vendor) + } if First(repl) == "" { return fmt.Sprintf("%s names no replacement model: %s", vendor, repl) } diff --git a/plugins/notices/retire/testdata/README.md b/plugins/notices/retire/testdata/README.md index b4c3b47..05a2b3c 100644 --- a/plugins/notices/retire/testdata/README.md +++ b/plugins/notices/retire/testdata/README.md @@ -2,7 +2,7 @@ The two providers' deprecations pages, as markdown (each page's URL plus `.md`). `retire`'s tests and the `openai-models` / `anthropic-models` golden tests (`plugins/notices`) read them. -**License:** excerpts for testing; © OpenAI and © Anthropic respectively. Not covered by this repo's license. +**License:** excerpts for testing; © OpenAI and © Anthropic respectively. Not covered by this repo's license. Google's two pages are © Google, CC BY 4.0 (Google's developer documentation). **Trimmed.** Each file keeps the page title and, for every retirement table that names at least one model the plugin keeps (text models code sends), the section heading above it and the whole table, copied unchanged. Prose, notice-period policy, endpoint tables and tables of only image, audio or embedding models were left out. `retire.Parse` returns exactly the same retirements from the trimmed and the full pages, so the golden files didn't change. @@ -10,3 +10,5 @@ The two providers' deprecations pages, as markdown (each page's URL plus `.md`). |---|---|---|---| | `openai-deprecations.md` | https://developers.openai.com/api/docs/deprecations.md | 2026-10-13 | "\| October 23, 2026 \| `gpt-4-0613` \\\| `gpt-4`, … \| `gpt-5.6-sol` \|" | | `anthropic-deprecations.md` | https://platform.claude.com/docs/en/about-claude/model-deprecations.md | 2026-10-13 | "\| November 30, 2026 \| `claude-sonnet-4-5-20250929` \| `claude-sonnet-5-5` \|" | +| `gemini-deprecations.md` | https://aistudio.google.com/docs/deprecations (where https://ai.google.dev/gemini-api/docs/deprecations redirects; served as Markdown). Kept whole, byte for byte | 2026-11-21 | "\| `gemini-2.0-flash` \| February 5, 2025 \| June 1, 2026 \| `gemini-3.6-flash` \|", as Markdoc `* cell` lines | +| `vertex-model-versions.html` | https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions. Excerpt: every `

`/`

` line and every line of every `` (982 of 10,074 lines), unchanged; scripts, navigation and prose left out. `retire.Parse` finds the same 39 retirements in the excerpt as in the full page | 2026-11-21 | "<td>June 30, 2026</td>" in the "Retired models" table | diff --git a/plugins/notices/retire/testdata/gemini-deprecations.md b/plugins/notices/retire/testdata/gemini-deprecations.md new file mode 100644 index 0000000..f28aefe --- /dev/null +++ b/plugins/notices/retire/testdata/gemini-deprecations.md @@ -0,0 +1,1001 @@ +> ## AI Agent Context +> - Full documentation index: https://aistudio.google.com/llms.txt +> - Gemini Docs MCP server (consistent live info): https://gemini-api-docs-mcp.dev +> - Coding agent skills & setup guide: https://aistudio.google.com/docs/coding-agents.md + +# Gemini deprecations + +This page lists the known deprecation schedules for [stable +(GA)](/docs/models#stable) and [preview](/docs/models#preview) models and for +managed agents in the Gemini API. A "**deprecation**" is the announcement that +we no longer provide support for a model, and that it will be "**shut down**" in +the near future. Once a model is "**shutdown**", it is completely turned off, and +the endpoint is no longer available. + +Deprecation announcements are made on the [Release notes](/docs/changelog) page, +and the announced earliest shutdown dates are tracked on this page. To pick an upgrade target for your workload, see [Choosing a model](/docs/choosing-a-model#upgrade-paths). +Already-shutdown models and agents are listed under the **Deprecated models** +and **Deprecated agents** sections. + +{% callout type="note" %} + Note: The **shutdown dates listed in the table indicate the *earliest possible + dates* on which a model might be retired**. We will communicate the exact + shutdown date to users with advance notice to ensure a smooth transition to a + replacement model. + +{% /callout %} + +## Gemini 4 models {% id="gemini-4-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-4-neon` + * November 18, 2026 + * No shutdown date announced + * + + --- + + * `gemini-4-hydrogen` + * November 12, 2026 + * No shutdown date announced + * + + --- + + * `gemini-4-carbon` + * November 10, 2026 + * No shutdown date announced + * + + --- + + * `gemini-4-argon` + * October 13, 2026 + * No shutdown date announced + * +{% /table %} + +## Gemini 3 models {% id="gemini-3-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3.8-flash-tts` + * September 22, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.8-flash-lite-tts` + * September 22, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.8-live` + * September 15, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.8-live-extended-thinking` + * September 15, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.8-flash` + * September 2, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.7-flash` + * August 13, 2026 + * N/A + * `gemini-3.8-flash` (`gemini-3.7-flash` is no longer available in Google AI Studio; the endpoint is not shutting down and automatically routes API requests to `gemini-3.8-flash`) + + --- + + * `gemini-3.6-flash` + * July 21, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.5-flash-lite` + * July 21, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.5-flash` + * May 19, 2026 + * N/A + * `gemini-3.6-flash` (`gemini-3.5-flash` is no longer available in Google AI Studio; the endpoint is not shutting down and automatically routes API requests to `gemini-3.6-flash`) + + --- + + * `gemini-3.1-flash-lite` + * May 7, 2026 + * May 7, 2027 + * `gemini-3.5-flash-lite` +{% /table %} + +### Preview models {% id="gemini-3-preview-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3.1-flash-tts-preview` + * February 26, 2026 + * December 18, 2026 + * `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` + + --- + + * `gemini-3.1-pro-preview` + * February 19, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3-flash-preview` + * December 17, 2025 + * No shutdown date announced + * `gemini-3.6-flash` +{% /table %} + +### Deprecated models {% id="gemini-3-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3-pro-preview` + * November 18, 2025 + * March 9, 2026 + * `gemini-3.1-pro-preview` + + --- + + * `gemini-3.1-flash-lite-preview` + * March 3, 2026 + * May 25, 2026 + * `gemini-3.1-flash-lite` +{% /table %} + +## Gemini 2.5 Pro models {% id="gemini-2.5-pro-models" %} + +{% callout type="caution" %} + `gemini-2.5-pro` is deprecated and is no longer available to select in Google AI + Studio. Access through the API is limited to existing users who have actively + used it in the past. Effective December 1, 2026, all API requests to + `gemini-2.5-pro` will automatically route to + [`gemini-3.8-flash`](/docs/models/gemini-3.8-flash) and be billed at + [Gemini 3.8 Flash rates](/docs/pricing#gemini-3.8-flash). Review the breaking + API changes in the + [Gemini 3.8 Flash migration guide](/docs/whats-new-gemini-3.8#migrate-to-gemini-3-8-flash) + before December 1, 2026. + +{% /callout %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-2.5-pro` + * June 17, 2025 + * December 1, 2026 + * `gemini-3.8-flash` (`gemini-2.5-pro` is no longer available in Google AI Studio; effective December 1, 2026, API requests to `gemini-2.5-pro` will automatically route to `gemini-3.8-flash`) +{% /table %} + +### Deprecated models {% id="gemini-2.5-pro-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-2.5-computer-use-preview-10-2025` + * October 7, 2025 + * July 28, 2026 + * `gemini-3.8-flash` + + --- + + * `gemini-2.5-pro-preview-03-25` + * March 3, 2025 + * December 2, 2025 + * `gemini-3.8-flash` + + --- + + * `gemini-2.5-pro-preview-05-06` + * May 6, 2025 + * December 2, 2025 + * `gemini-3.8-flash` + + --- + + * `gemini-2.5-pro-preview-06-05` + * June 5, 2025 + * December 2, 2025 + * `gemini-3.8-flash` +{% /table %} + +## Gemini 2.5 Flash models {% id="gemini-2.5-flash-models" %} + +{% callout type="caution" %} + `gemini-2.5-flash` is deprecated and is no longer available to select in Google + AI Studio. Effective December 1, 2026, all API requests to `gemini-2.5-flash` + will automatically route to + [`gemini-3.5-flash-lite`](/docs/models/gemini-3.5-flash-lite) and be billed at + [Gemini 3.5 Flash-Lite rates](/docs/pricing#gemini-3.5-flash-lite). Review the + breaking API changes in the + [Gemini 3.5 Flash-Lite migration guide](/docs/whats-new-gemini-3.6#migrate-to-gemini-3-5-flash-lite) + before December 1, 2026. Access to the 2.5 models is limited to users who have + actively used them in the past. `gemini-2.5-flash-lite` is not deprecated and + remains available through the API until further notice. + +{% /callout %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-2.5-flash` + * June 17, 2025 + * December 1, 2026 + * `gemini-3.5-flash-lite` (`gemini-2.5-flash` is no longer available in Google AI Studio; effective December 1, 2026, API requests to `gemini-2.5-flash` will automatically route to `gemini-3.5-flash-lite`) + + --- + + * `gemini-2.5-flash-lite` + * July 22, 2025 + * No shutdown date announced + * +{% /table %} + +### Deprecated models {% id="gemini-2.5-flash-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-2.5-flash-lite-preview-09-2025` + * September 25, 2025 + * March 31, 2026 + * `gemini-3.1-flash-lite` + + --- + + * `gemini-2.5-flash-preview-05-20` + * May 20, 2025 + * November 18, 2025 + * `gemini-3.6-flash` + + --- + + * `gemini-2.5-flash-preview-09-2025` + * September 25, 2025 + * February 17, 2026 + * `gemini-3.6-flash` +{% /table %} + +## Gemini 2.0 models {% id="gemini-2.0-models" %} + +### Deprecated models {% id="gemini-2.0-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-2.0-flash` + * February 5, 2025 + * June 1, 2026 + * `gemini-3.6-flash` + + --- + + * `gemini-2.0-flash-001` + * February 5, 2025 + * June 1, 2026 + * `gemini-3.6-flash` + + --- + + * `gemini-2.0-flash-lite` + * February 25, 2025 + * June 1, 2026 + * `gemini-3.1-flash-lite` + + --- + + * `gemini-2.0-flash-lite-001` + * February 25, 2025 + * June 1, 2026 + * `gemini-3.1-flash-lite` + + --- + + * `gemini-2.0-flash-lite-preview` + * February 5, 2025 + * December 9, 2025 + * `gemini-3.1-flash-lite` + + --- + + * `gemini-2.0-flash-lite-preview-02-05` + * February 5, 2025 + * December 9, 2025 + * `gemini-3.1-flash-lite` +{% /table %} + +## Live API models {% id="live-api-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3.8-live` + * September 15, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.8-live-extended-thinking` + * September 15, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.5-transcribe-live` + * August 2026 + * No shutdown date announced + * +{% /table %} + +### Preview models {% id="live-api-preview-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3.5-live-translate-preview` + * June 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.1-flash-live-preview` + * March 11, 2026 + * No shutdown date announced + * `gemini-3.8-live` + + --- + + * `gemini-2.5-flash-native-audio-preview-12-2025` + * December 12, 2025 + * March 31, 2027 + * `gemini-3.8-live` +{% /table %} + +### Deprecated models {% id="live-api-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-live-2.5-flash-preview` + * June 17, 2025 + * December 9, 2025 + * `gemini-3.8-live` + + --- + + * `gemini-2.0-flash-live-001` + * April 9, 2025 + * December 9, 2025 + * `gemini-3.8-live` +{% /table %} + +## Audio models {% id="audio-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3.5-transcribe` + * August 2026 + * No shutdown date announced + * +{% /table %} + +### Preview models {% id="audio-preview-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-2.5-flash-preview-tts` + * May 20, 2025 + * December 18, 2026 + * `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` + + --- + + * `gemini-2.5-pro-preview-tts` + * May 20, 2025 + * December 18, 2026 + * `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` +{% /table %} + +## Embedding models {% id="embedding-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-embedding-2` + * April 22, 2026 + * No shutdown date announced + * + + --- + + * `gemini-embedding-001` + * July 14, 2025 + * May 14, 2028 + * `gemini-embedding-2` +{% /table %} + +### Deprecated models {% id="embedding-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-embedding-2-preview` + * March 10, 2026 + * November 6, 2026 + * `gemini-embedding-2` (effective November 6, 2026, API requests to `gemini-embedding-2-preview` route to `gemini-embedding-2`) + + --- + + * `text-embedding-004` + * April 9, 2024 + * January 14, 2026 + * `gemini-embedding-2` + + --- + + * `embedding-001` + * April 9, 2024 + * October 30, 2025 + * `gemini-embedding-2` + + --- + + * `embedding-gecko-001` + * + * October 30, 2025 + * `gemini-embedding-2` + + --- + + * `gemini-embedding-exp` + * + * October 30, 2025 + * `gemini-embedding-2` + + --- + + * `gemini-embedding-exp-03-07` + * + * October 30, 2025 + * `gemini-embedding-2` +{% /table %} + +## Nano Banana models {% id="nano-banana-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-nano-banana-2.1` + * October 6, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.1-flash-lite-image` + * June 30, 2026 + * No shutdown date announced + * + + --- + + * `gemini-3.1-flash-image` + * May 28, 2026 + * No shutdown date announced + * `gemini-nano-banana-2.1` + + --- + + * `gemini-3-pro-image` + * May 28, 2026 + * No shutdown date announced + * + + --- + + * `gemini-2.5-flash-image` + * October 2, 2025 + * March 15, 2027 + * `gemini-3.1-flash-lite-image` +{% /table %} + +### Deprecated models {% id="nano-banana-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-3.1-flash-image-preview` + * February 26, 2026 + * June 25, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `gemini-3-pro-image-preview` + * November 20, 2025 + * June 25, 2026 + * `gemini-3-pro-image` + + --- + + * `gemini-2.5-flash-image-preview` + * May 7, 2025 + * January 15, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `gemini-2.0-flash-preview-image-generation` + * May 7, 2025 + * November 14, 2025 + * `gemini-nano-banana-2.1` +{% /table %} + +## Imagen models {% id="imagen-models" %} + +### Deprecated models {% id="imagen-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `imagen-4.0-generate-001` + * June 24, 2025 + * August 17, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `imagen-4.0-ultra-generate-001` + * June 24, 2025 + * August 17, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `imagen-4.0-fast-generate-001` + * June 24, 2025 + * August 17, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `imagen-4.0-generate-preview-06-06` + * June 24, 2025 + * February 17, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `imagen-4.0-ultra-generate-preview-06-06` + * June 24, 2025 + * February 17, 2026 + * `gemini-nano-banana-2.1` + + --- + + * `imagen-3.0-generate-002` + * February 6, 2025 + * November 10, 2025 + * `gemini-nano-banana-2.1` +{% /table %} + +## Veo models {% id="veo-models" %} + +### Deprecated models {% id="veo-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `veo-3.1-lite-generate-preview` + * March 31, 2026 + * October 22, 2026 + * `gemini-omni-1.2-flash` + + --- + + * `veo-3.1-generate-preview` + * October 15, 2025 + * October 22, 2026 + * `gemini-omni-1.2-flash` + + --- + + * `veo-3.1-fast-generate-preview` + * October 15, 2025 + * October 22, 2026 + * `gemini-omni-1.2-flash` + + --- + + * `veo-3.0-generate-001` + * September 9, 2025 + * June 30, 2026 + * `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) + + --- + + * `veo-3.0-fast-generate-001` + * September 9, 2025 + * June 30, 2026 + * `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) + + --- + + * `veo-2.0-generate-001` + * April 9, 2025 + * June 30, 2026 + * `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) + + --- + + * `veo-3.0-generate-preview` + * July 31, 2025 + * November 12, 2025 + * `gemini-omni-1.2-flash` + + --- + + * `veo-3.0-fast-generate-preview` + * July 31, 2025 + * November 12, 2025 + * `gemini-omni-1.2-flash` +{% /table %} + +## Gemini Omni Flash models {% id="gemini-omni-flash-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-omni-1.2-flash` + * November 5, 2026 + * No shutdown date announced + * + + --- + + * `gemini-omni-1.1-flash` + * August 27, 2026 + * December 3, 2026 + * `gemini-omni-1.2-flash` (Effective December 3, 2026, the endpoint is + automatically routing API requests to + `gemini-omni-1.2-flash`) +{% /table %} + +### Deprecated models {% id="gemini-omni-flash-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-omni-flash-preview` + * June 30, 2026 + * October 22, 2026 + * `gemini-omni-1.2-flash` +{% /table %} + +## Genie models {% id="genie-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * [`genie-4`](/docs/models/genie-4) + * November 19, 2026 + * No shutdown date announced + * +{% /table %} + +## Lyria models {% id="lyria-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `lyria-3.5` + * September 3, 2026 + * No shutdown date announced + * +{% /table %} + +### Preview models {% id="lyria-preview-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `lyria-3-clip-preview` + * March 25, 2026 + * No shutdown date announced + * + + --- + + * `lyria-3-pro-preview` + * March 25, 2026 + * No shutdown date announced + * `lyria-3.5` + + --- + + * `lyria-realtime-exp` + * May 20, 2025 + * No shutdown date announced + * +{% /table %} + +## Robotics models {% id="robotics-models" %} + +### Preview models {% id="robotics-preview-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-robotics-er-2-preview` + * July 30, 2026 + * No shutdown date announced + * + + --- + + * `gemini-robotics-er-2-streaming-preview` + * July 30, 2026 + * No shutdown date announced + * +{% /table %} + +### Deprecated models {% id="robotics-deprecated-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `gemini-robotics-er-1.6-preview` + * April 14, 2026 + * August 31, 2026 + * `gemini-robotics-er-2-preview` + + --- + + * `gemini-robotics-er-1.5-preview` + * September 25, 2025 + * April 30, 2026 + * `gemini-robotics-er-2-preview` +{% /table %} + +## Gemini Decision models {% id="gemini-decision-models" %} + +{% table %} + * Model + * Release date + * Shutdown date + * Recommended replacement + + --- + + * [`gemini-decision-1`](/docs/models/gemini-decision-1) + * November 11, 2026 + * No shutdown date announced + * +{% /table %} + +## Managed agents {% id="managed-agents" %} + +### Preview agents {% id="managed-agents-preview-agents" %} + +{% table %} + * Agent + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `antigravity-preview-09-2026` + * September 17, 2026 + * No shutdown date announced + * + + --- + + * `deep-research-preview-04-2026` + * April 21, 2026 + * No shutdown date announced + * + + --- + + * `deep-research-max-preview-04-2026` + * April 21, 2026 + * No shutdown date announced + * +{% /table %} + +### Deprecated agents {% id="managed-agents-deprecated-agents" %} + +{% table %} + * Agent + * Release date + * Shutdown date + * Recommended replacement + + --- + + * `deep-research-pro-preview-12-2025` + * December 11, 2025 + * October 23, 2026 + * `deep-research-preview-04-2026` + + --- + + * `antigravity-preview-05-2026` + * May 19, 2026 + * October 5, 2026 + * `antigravity-preview-09-2026` +{% /table %} + diff --git a/plugins/notices/retire/testdata/vertex-model-versions.html b/plugins/notices/retire/testdata/vertex-model-versions.html new file mode 100644 index 0000000..ff7398c --- /dev/null +++ b/plugins/notices/retire/testdata/vertex-model-versions.html @@ -0,0 +1,982 @@ +

Latest available models

+

Models available for at least 12 months after release

+

Gemini models

+

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateReplacement model ID
+ + gemini-4-argon + + October 13, 2026 + + October 13, 2027 or later + + + +
+ + gemini-3.8-live + + September 24, 2026 + + September 25, 2027 or later + + + +
+ + gemini-3.8-flash + + September 2, 2026 + + September 2, 2027 or later + + + +
+ + gemini-3.5-flash-lite + + July 21, 2026 + + July 21, 2027 or later + + + +
+ + gemini-3.5-flash + + May 19, 2026 + + May 19, 2027 or later + + + +
+ + gemini-3.1-flash-lite + + May 7, 2026 + + May 7, 2027 or later + + + +
+ + gemini-2.5-pro + + June 17, 2025 + + October 20, 2026 + + + + + gemini-3.8-flash or + gemini-3.5-flash + +
+ + gemini-2.5-flash + + June 17, 2025 + + October 20, 2026 + + + + + gemini-3.8-flash or + gemini-3.5-flash-lite + +
+ + gemini-2.5-flash-lite + + July 22, 2025 + + October 20, 2026 + + + + + gemini-3.8-flash or + gemini-3.5-flash-lite or Gemma 4 + +
+ + gemini-live-2.5-flash-native-audio + + December 12, 2025 + + December 13, 2026 + + + + + gemini-3.8-live + +
+

Gemini image models

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateReplacement model ID
+ + gemini-3.1-flash-lite-image + + June 23, 2026 + + June 28, 2027 or later + + + +
+ + gemini-3-pro-image + + May 28, 2026 + + May 28, 2027 or later + + + +
+ + gemini-3.1-flash-image + + May 28, 2026 + + May 28, 2027 or later + + + +
+ + gemini-2.5-flash-image + + October 2, 2025 + + March 15, 2027 + + + + + gemini-3.1-flash-lite-image + +
+

Gemini Omni models

+ + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateReplacement model ID
+ + gemini-omni-1.2-flash + + November 5, 2026 + + November 5, 2027 or later + + + +
+

Veo models

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateReplacement model ID
+ + veo-3.1-generate-001 + + November 17, 2025 + + May 4, 2027 or later + + + + + gemini-omni-1.2-flash + +
+ + veo-3.1-fast-generate-001 + + November 17, 2025 + + May 4, 2027 or later + + + + + gemini-omni-1.2-flash + +
+

Embeddings models

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateReplacement model ID
gemini-embedding-2April 22, 2026
gemini-embedding-001May 20, 2025No sooner than May 20, 2028
text-embedding-005November 18, 2024April 1, 2027
text-embedding-004May 14, 2024April 1, 2027
text-multilingual-embedding-002May 14, 2024April 1, 2027
multimodalembedding@001February 12, 2024April 1, 2027

+

Models available for shorter availability periods

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateReplacement model ID
+ + gemini-4-neon + + November 18, 2026 + + No retirement date announced + + + +
+ + gemini-4-hydrogen + + November 12, 2026 + + No retirement date announced + + + +
+ + gemini-4-carbon + + November 10, 2026 + + No retirement date announced + + + +
+ + gemini-4-carbon-cyber-permissive + + November 10, 2026 + + No retirement date announced + + + +
+ + gemini-4-argon-cyber-permissive + + October 13, 2026 + + No retirement date announced + + + +
+ + gemini-3.8-flash-cyber + + September 16, 2026 + + No retirement date announced + + + +
+ + gemini-3.7-flash + + August 13, 2026 + + January 28, 2027 + + + + + gemini-4-hydrogen + +
+ + gemini-3.6-flash + + July 21, 2026 + + January 28, 2027 + + + + + gemini-4-hydrogen + +
+ + gemini-nano-banana-2.1 + + October 6, 2026 + + No retirement date announced + + + +
+

Retired models

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Model IDRelease dateRetirement dateRecommended upgrade
veo-3.0-generate-001July 29, 2025June 30, 2026veo-3.1-generate-001
veo-3.0-fast-generate-001July 29, 2025June 30, 2026veo-3.1-fast-generate-001
veo-2.0-generate-001May 27, 2025June 30, 2026veo-3.1-generate-001
imagen-4.0-generate-001August 14, 2025June 30, 2026gemini-2.5-flash-image
imagen-4.0-ultra-generate-001August 14, 2025June 30, 2026gemini-2.5-flash-image
imagen-3.0-generate-002January 29, 2025June 30, 2026gemini-2.5-flash-image
imagen-3.0-generate-001December 10, 2024June 30, 2026gemini-2.5-flash-image
imagegeneration@006March 27, 2024June 30, 2026gemini-2.5-flash-image
imagegeneration@005November 22, 2023June 30, 2026gemini-2.5-flash-image
imagegeneration@004June 30, 2026gemini-2.5-flash-image
imagegeneration@003June 30, 2026gemini-2.5-flash-image
imagegeneration@002August 17, 2023June 30, 2026gemini-2.5-flash-image
gemini-2.0-flashFebruary 5, 2025June 1, 2026gemini-3.5-flash-lite
gemini-2.0-flash-liteFebruary 25, 2025June 1, 2026gemini-3.5-flash-lite
gemini-1.5-pro-001May 24, 2024May 24, 2025gemini-2.5-flash
gemini-1.5-pro-002September 24, 2024September 24, 2025gemini-2.5-flash
gemini-1.5-flash-001May 24, 2024May 24, 2025gemini-2.5-flash-lite
gemini-1.5-flash-002September 24, 2024September 24, 2025gemini-2.5-flash-lite
textembedding-gecko@003*December 12, 2023May 24, 2025gemini-embedding-001
textembedding-gecko-multilingual@001November 2, 2023May 24, 2025gemini-embedding-001
gemini-1.0-pro-001February 15, 2024April 21, 2025gemini-2.5-flash
gemini-1.0-pro-002April 9, 2024April 21, 2025gemini-2.5-flash
gemini-1.0-pro-vision-001February 15, 2024April 21, 2025gemini-2.5-flash
text-bisonMay 2023April 21, 2025gemini-2.5-flash-lite
chat-bisonMay 2023April 21, 2025gemini-2.5-flash-lite
code-geckoMay 2023April 21, 2025gemini-2.5-flash-lite
textembedding-gecko@002November 2, 2023April 21, 2025gemini-embedding-001
textembedding-gecko@001June 7, 2023April 21, 2025gemini-embedding-001
imagetextJune 7, 2023September 24, 2025gemini-2.5-flash-image
+

Migrate to a latest available model

+

What's next

+ + + + diff --git a/plugins/notices/retirements_golden_test.go b/plugins/notices/retirements_golden_test.go index 1bfaa74..28b3d25 100644 --- a/plugins/notices/retirements_golden_test.go +++ b/plugins/notices/retirements_golden_test.go @@ -8,13 +8,16 @@ import ( "github.com/patch-it-dev/patch-it-plugins/plugins/notices/retire" ) -// Both providers' saved pages (2026-10-13) in, every event out. The archive +// Each provider's saved page (OpenAI's and Anthropic's 2026-10-13, Google's +// 2026-11-21) in, every event out. The archive // serves the same copy as the snapshot, so the events cite it; a second read // of the unchanged page asks for no snapshot. func TestRetirementsGolden(t *testing.T) { for file, page := range map[string]retire.Page{ - "openai-deprecations.md": retire.OpenAI, - "anthropic-deprecations.md": retire.Anthropic, + "openai-deprecations.md": retire.OpenAI, + "anthropic-deprecations.md": retire.Anthropic, + "gemini-deprecations.md": retire.Gemini, + "vertex-model-versions.html": retire.Vertex, } { t.Run(page.API, func(t *testing.T) { saved := kittest.Pages{page.URL: "retire/testdata/" + file} diff --git a/plugins/notices/retirements_registered_test.go b/plugins/notices/retirements_registered_test.go index 42cee34..7d020eb 100644 --- a/plugins/notices/retirements_registered_test.go +++ b/plugins/notices/retirements_registered_test.go @@ -8,7 +8,7 @@ import ( ) func TestRetirementsRegisterThemselves(t *testing.T) { - for _, p := range []retire.Page{retire.OpenAI, retire.Anthropic} { + for _, p := range []retire.Page{retire.OpenAI, retire.Anthropic, retire.Gemini, retire.Vertex} { kittest.Registered(t, Plugin{Page: p}) } } diff --git a/plugins/notices/testdata/golden/google-gemini-models.json b/plugins/notices/testdata/golden/google-gemini-models.json new file mode 100644 index 0000000..99aaa17 --- /dev/null +++ b/plugins/notices/testdata/golden/google-gemini-models.json @@ -0,0 +1,1072 @@ +[ + { + "id": 1, + "fingerprint": "sha256:caea2393099a2cf5bdbb0fbc226f25dfe2dfce8afb3267eec5faf86162821f2c", + "api": "google/gemini-models", + "version": "2027-05-07", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3.1-flash-lite", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-3.1-flash-lite\" can be shut down from 2027-05-07, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "## Gemini 3 models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-3.1-flash-lite` | May 7, 2026 | May 7, 2027 | `gemini-3.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 2, + "fingerprint": "sha256:8858145e5f4653df2466841a60dc2868c6f426c5af9150f55afc1fda77513773", + "api": "google/gemini-models", + "version": "2026-12-18", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3.1-flash-tts-preview" + }, + "description": "Model \"gemini-3.1-flash-tts-preview\" can be shut down from 2026-12-18, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Preview models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-3.1-flash-tts-preview` | February 26, 2026 | December 18, 2026 | `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 3, + "fingerprint": "sha256:0cac57f7a4434d25aae59532745358c6f44758d0c4ddf897a2927a170b6dbf28", + "api": "google/gemini-models", + "version": "2026-03-09", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3-pro-preview", + "replacement": "gemini-3.1-pro-preview" + }, + "description": "Model \"gemini-3-pro-preview\" can be shut down from 2026-03-09, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.1-pro-preview` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-3-pro-preview` | November 18, 2025 | March 9, 2026 | `gemini-3.1-pro-preview` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 4, + "fingerprint": "sha256:3f4158206697b71cbe0dbbe74a52310d52e6f44033349189349d8d8128e59336", + "api": "google/gemini-models", + "version": "2026-05-25", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3.1-flash-lite-preview", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-3.1-flash-lite-preview\" can be shut down from 2026-05-25, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-3.1-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-3.1-flash-lite-preview` | March 3, 2026 | May 25, 2026 | `gemini-3.1-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 5, + "fingerprint": "sha256:871f6f3d545e0f3bf03421077213fe06548c79e9e8ddf9954d79b95e15adc17d", + "api": "google/gemini-models", + "version": "2026-12-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-pro" + }, + "description": "Model \"gemini-2.5-pro\" can be shut down from 2026-12-01, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash` (`gemini-2.5-pro` is no longer available in Google AI Studio; effective December 1, 2026, API requests to `gemini-2.5-pro` will automatically route to `gemini-3.8-flash`) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "## Gemini 2.5 Pro models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-pro` | June 17, 2025 | December 1, 2026 | `gemini-3.8-flash` (`gemini-2.5-pro` is no longer available in Google AI Studio; effective December 1, 2026, API requests to `gemini-2.5-pro` will automatically route to `gemini-3.8-flash`) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 6, + "fingerprint": "sha256:c02264b3e06bca3097caafa91d4a6dada49368e16d087f58ff1debbffc121a43", + "api": "google/gemini-models", + "version": "2026-07-28", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-computer-use-preview-10-2025", + "replacement": "gemini-3.8-flash" + }, + "description": "Model \"gemini-2.5-computer-use-preview-10-2025\" can be shut down from 2026-07-28, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-computer-use-preview-10-2025` | October 7, 2025 | July 28, 2026 | `gemini-3.8-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 7, + "fingerprint": "sha256:2adc7a8dfc6a692ee12da231f25be750326a077e9b3cd26aa82764f23aa6acd2", + "api": "google/gemini-models", + "version": "2025-12-02", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-pro-preview-03-25", + "replacement": "gemini-3.8-flash" + }, + "description": "Model \"gemini-2.5-pro-preview-03-25\" can be shut down from 2025-12-02, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-pro-preview-03-25` | March 3, 2025 | December 2, 2025 | `gemini-3.8-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 8, + "fingerprint": "sha256:b225c413ec1d91b929eb2d7124814f928b9b04e18a9f08611c5fbfcf08e0a0e0", + "api": "google/gemini-models", + "version": "2025-12-02", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-pro-preview-05-06", + "replacement": "gemini-3.8-flash" + }, + "description": "Model \"gemini-2.5-pro-preview-05-06\" can be shut down from 2025-12-02, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-pro-preview-05-06` | May 6, 2025 | December 2, 2025 | `gemini-3.8-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 9, + "fingerprint": "sha256:4c2be4641bb22e1ae2d4c3b95da03ca363cd5e488a394cca4bc001f8915a835b", + "api": "google/gemini-models", + "version": "2025-12-02", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-pro-preview-06-05", + "replacement": "gemini-3.8-flash" + }, + "description": "Model \"gemini-2.5-pro-preview-06-05\" can be shut down from 2025-12-02, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-pro-preview-06-05` | June 5, 2025 | December 2, 2025 | `gemini-3.8-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 10, + "fingerprint": "sha256:60b751f9d3e759c519bbcabec3139c1de457129e71ed1ed966711f60af5374e1", + "api": "google/gemini-models", + "version": "2026-12-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash" + }, + "description": "Model \"gemini-2.5-flash\" can be shut down from 2026-12-01, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` (`gemini-2.5-flash` is no longer available in Google AI Studio; effective December 1, 2026, API requests to `gemini-2.5-flash` will automatically route to `gemini-3.5-flash-lite`) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "## Gemini 2.5 Flash models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash` | June 17, 2025 | December 1, 2026 | `gemini-3.5-flash-lite` (`gemini-2.5-flash` is no longer available in Google AI Studio; effective December 1, 2026, API requests to `gemini-2.5-flash` will automatically route to `gemini-3.5-flash-lite`) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 11, + "fingerprint": "sha256:b6d458a69ba2b51781274669929bebda33e4bebcf1927c1f63e23022386b265a", + "api": "google/gemini-models", + "version": "2026-03-31", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-lite-preview-09-2025", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.5-flash-lite-preview-09-2025\" can be shut down from 2026-03-31, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-3.1-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-lite-preview-09-2025` | September 25, 2025 | March 31, 2026 | `gemini-3.1-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 12, + "fingerprint": "sha256:b81dc7696b0da57fbd358d29f47d03a65f8ae9260049cf302d1bd6b4a7098bf3", + "api": "google/gemini-models", + "version": "2025-11-18", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-preview-05-20", + "replacement": "gemini-3.6-flash" + }, + "description": "Model \"gemini-2.5-flash-preview-05-20\" can be shut down from 2025-11-18, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.6-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-preview-05-20` | May 20, 2025 | November 18, 2025 | `gemini-3.6-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 13, + "fingerprint": "sha256:8571eb750e46025a2b5ae4d0d645c01e1db00df8ffaa3ffae4a10a1f163d96b6", + "api": "google/gemini-models", + "version": "2026-02-17", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-preview-09-2025", + "replacement": "gemini-3.6-flash" + }, + "description": "Model \"gemini-2.5-flash-preview-09-2025\" can be shut down from 2026-02-17, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.6-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-preview-09-2025` | September 25, 2025 | February 17, 2026 | `gemini-3.6-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 14, + "fingerprint": "sha256:856205baa026aae1af080949fbba2a7272d91ad3467927e12bc533e6d318fe3e", + "api": "google/gemini-models", + "version": "2026-06-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash", + "replacement": "gemini-3.6-flash" + }, + "description": "Model \"gemini-2.0-flash\" can be shut down from 2026-06-01, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.6-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash` | February 5, 2025 | June 1, 2026 | `gemini-3.6-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 15, + "fingerprint": "sha256:83b2140ac7dce78acb6a4338e680fefed3069e978f060b707b965b078746b345", + "api": "google/gemini-models", + "version": "2026-06-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-001", + "replacement": "gemini-3.6-flash" + }, + "description": "Model \"gemini-2.0-flash-001\" can be shut down from 2026-06-01, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.6-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-001` | February 5, 2025 | June 1, 2026 | `gemini-3.6-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 16, + "fingerprint": "sha256:606afbea818c0aa70a918ce8a161373fc742c491a4c591180ce32e582e7271a6", + "api": "google/gemini-models", + "version": "2026-06-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-lite", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.0-flash-lite\" can be shut down from 2026-06-01, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-3.1-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-lite` | February 25, 2025 | June 1, 2026 | `gemini-3.1-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 17, + "fingerprint": "sha256:c46f075bda7582cef7ad8fb25fda10b4412029124b68f67aa3aae129cb26fb54", + "api": "google/gemini-models", + "version": "2026-06-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-lite-001", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.0-flash-lite-001\" can be shut down from 2026-06-01, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-3.1-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-lite-001` | February 25, 2025 | June 1, 2026 | `gemini-3.1-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 18, + "fingerprint": "sha256:f33c6d97b86cb936d566061674c549260c611d3084532190e53ede81a667cb64", + "api": "google/gemini-models", + "version": "2025-12-09", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-lite-preview", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.0-flash-lite-preview\" can be shut down from 2025-12-09, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-3.1-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-lite-preview` | February 5, 2025 | December 9, 2025 | `gemini-3.1-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 19, + "fingerprint": "sha256:1905e464a0c97bc4e0adc0812fe8f9e578f239fe86d263dbd8ea112ecd669cf8", + "api": "google/gemini-models", + "version": "2025-12-09", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-lite-preview-02-05", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.0-flash-lite-preview-02-05\" can be shut down from 2025-12-09, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-3.1-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-lite-preview-02-05` | February 5, 2025 | December 9, 2025 | `gemini-3.1-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 20, + "fingerprint": "sha256:7b91dbf1e5b957702a1f2e048ff346070c9765f96ec23c6cf018562a7391c15f", + "api": "google/gemini-models", + "version": "2027-03-31", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-native-audio-preview-12-2025", + "replacement": "gemini-3.8-live" + }, + "description": "Model \"gemini-2.5-flash-native-audio-preview-12-2025\" can be shut down from 2027-03-31, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-live` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Preview models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-native-audio-preview-12-2025` | December 12, 2025 | March 31, 2027 | `gemini-3.8-live` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 21, + "fingerprint": "sha256:b3d90322199ab4367fc8eba144f8cd88b5a5c3b786a7374d159a2332d9f5244c", + "api": "google/gemini-models", + "version": "2025-12-09", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-live-2.5-flash-preview", + "replacement": "gemini-3.8-live" + }, + "description": "Model \"gemini-live-2.5-flash-preview\" can be shut down from 2025-12-09, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-live` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-live-2.5-flash-preview` | June 17, 2025 | December 9, 2025 | `gemini-3.8-live` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 22, + "fingerprint": "sha256:840b70b0db6e2eb215e8266fe0105f25a0855d32aba42a776523c0fd0d8a4e52", + "api": "google/gemini-models", + "version": "2025-12-09", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-live-001", + "replacement": "gemini-3.8-live" + }, + "description": "Model \"gemini-2.0-flash-live-001\" can be shut down from 2025-12-09, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-live` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-live-001` | April 9, 2025 | December 9, 2025 | `gemini-3.8-live` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 23, + "fingerprint": "sha256:a6a20dbe9b625f444a1644e3c8ccbce9a63ebfa4e039393c75633c8ca4b13974", + "api": "google/gemini-models", + "version": "2026-12-18", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-preview-tts" + }, + "description": "Model \"gemini-2.5-flash-preview-tts\" can be shut down from 2026-12-18, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Preview models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-preview-tts` | May 20, 2025 | December 18, 2026 | `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 24, + "fingerprint": "sha256:8bc72c3cc1260e614977f305a2c61bee114dd67ec702fff60f09a036232e2a97", + "api": "google/gemini-models", + "version": "2026-12-18", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-pro-preview-tts" + }, + "description": "Model \"gemini-2.5-pro-preview-tts\" can be shut down from 2026-12-18, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Preview models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-pro-preview-tts` | May 20, 2025 | December 18, 2026 | `gemini-3.8-flash-tts` or `gemini-3.8-flash-lite-tts` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 25, + "fingerprint": "sha256:6c676c8e23b7b1d9db5de5e998a741c6fbac7dc2c2bf1929b647e7f6cf680542", + "api": "google/gemini-models", + "version": "2028-05-14", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-embedding-001", + "replacement": "gemini-embedding-2" + }, + "description": "Model \"gemini-embedding-001\" can be shut down from 2028-05-14, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "## Embedding models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-embedding-001` | July 14, 2025 | May 14, 2028 | `gemini-embedding-2` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 26, + "fingerprint": "sha256:f78e21e24ec4d3f9122c2631190b6b92736ec1bd89010b63b209bf2507daf953", + "api": "google/gemini-models", + "version": "2026-11-06", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-embedding-2-preview" + }, + "description": "Model \"gemini-embedding-2-preview\" can be shut down from 2026-11-06, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` (effective November 6, 2026, API requests to `gemini-embedding-2-preview` route to `gemini-embedding-2`) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-embedding-2-preview` | March 10, 2026 | November 6, 2026 | `gemini-embedding-2` (effective November 6, 2026, API requests to `gemini-embedding-2-preview` route to `gemini-embedding-2`) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 27, + "fingerprint": "sha256:0a968f052281aeb0c8cd71d3a92db497be8040686f23c3d592f6406aea39d68f", + "api": "google/gemini-models", + "version": "2026-01-14", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "text-embedding-004", + "replacement": "gemini-embedding-2" + }, + "description": "Model \"text-embedding-004\" can be shut down from 2026-01-14, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `text-embedding-004` | April 9, 2024 | January 14, 2026 | `gemini-embedding-2` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 28, + "fingerprint": "sha256:d1332b877be37336a413687d6be1480cf66dcfb3369101147a88c216a58e0736", + "api": "google/gemini-models", + "version": "2025-10-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "embedding-001", + "replacement": "gemini-embedding-2" + }, + "description": "Model \"embedding-001\" can be shut down from 2025-10-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `embedding-001` | April 9, 2024 | October 30, 2025 | `gemini-embedding-2` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 29, + "fingerprint": "sha256:9961f36c881a0bdf2d339315acd7895323e3b4672b0957436987f3b1c8296b2f", + "api": "google/gemini-models", + "version": "2025-10-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "embedding-gecko-001", + "replacement": "gemini-embedding-2" + }, + "description": "Model \"embedding-gecko-001\" can be shut down from 2025-10-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `embedding-gecko-001` | | October 30, 2025 | `gemini-embedding-2` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 30, + "fingerprint": "sha256:49b126de93982f83c2ee88f884ad720f1d0921206dae42f5826227db76af68ee", + "api": "google/gemini-models", + "version": "2025-10-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-embedding-exp", + "replacement": "gemini-embedding-2" + }, + "description": "Model \"gemini-embedding-exp\" can be shut down from 2025-10-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-embedding-exp` | | October 30, 2025 | `gemini-embedding-2` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 31, + "fingerprint": "sha256:ef27905e81e0ee48ec07d4669a42ea6ce0dd785a7f85033d7e1d34d7bf411b94", + "api": "google/gemini-models", + "version": "2025-10-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-embedding-exp-03-07", + "replacement": "gemini-embedding-2" + }, + "description": "Model \"gemini-embedding-exp-03-07\" can be shut down from 2025-10-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-embedding-2` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-embedding-exp-03-07` | | October 30, 2025 | `gemini-embedding-2` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 32, + "fingerprint": "sha256:acc61a0a44b398c42fb63c271aa2163a03749d76b12932f561f303c4981ae96e", + "api": "google/gemini-models", + "version": "2027-03-15", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-image", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"gemini-2.5-flash-image\" can be shut down from 2027-03-15, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "## Nano Banana models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-image` | October 2, 2025 | March 15, 2027 | `gemini-3.1-flash-lite-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 33, + "fingerprint": "sha256:352f204e72c7ab36bb05cb742c9edee87f1589930ece2bc90ffbb851c443aba7", + "api": "google/gemini-models", + "version": "2026-06-25", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3.1-flash-image-preview", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"gemini-3.1-flash-image-preview\" can be shut down from 2026-06-25, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-3.1-flash-image-preview` | February 26, 2026 | June 25, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 34, + "fingerprint": "sha256:1d09afffb5768ce989c65f94befc597bdba8a13131ad7c2cc139741a1b39bf56", + "api": "google/gemini-models", + "version": "2026-06-25", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3-pro-image-preview", + "replacement": "gemini-3-pro-image" + }, + "description": "Model \"gemini-3-pro-image-preview\" can be shut down from 2026-06-25, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-3-pro-image` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-3-pro-image-preview` | November 20, 2025 | June 25, 2026 | `gemini-3-pro-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 35, + "fingerprint": "sha256:9132c7b110d46a16200f6541ece38bcbe0748e75d36c1bd3586eab10398fbe37", + "api": "google/gemini-models", + "version": "2026-01-15", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-image-preview", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"gemini-2.5-flash-image-preview\" can be shut down from 2026-01-15, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.5-flash-image-preview` | May 7, 2025 | January 15, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 36, + "fingerprint": "sha256:c42e560875145b4013adeac0199e6ee63421d16e345ee97c023565710c4f3215", + "api": "google/gemini-models", + "version": "2025-11-14", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-preview-image-generation", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"gemini-2.0-flash-preview-image-generation\" can be shut down from 2025-11-14, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-2.0-flash-preview-image-generation` | May 7, 2025 | November 14, 2025 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 37, + "fingerprint": "sha256:c889c0a9533b444eda90a0d8d057d30a837941242dfaa095a5378027d6579654", + "api": "google/gemini-models", + "version": "2026-08-17", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-generate-001", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"imagen-4.0-generate-001\" can be shut down from 2026-08-17, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `imagen-4.0-generate-001` | June 24, 2025 | August 17, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 38, + "fingerprint": "sha256:b65d181909243d2cfdbcf4a81fea4fa279eacdb61e776b235685042b1d273da4", + "api": "google/gemini-models", + "version": "2026-08-17", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-ultra-generate-001", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"imagen-4.0-ultra-generate-001\" can be shut down from 2026-08-17, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `imagen-4.0-ultra-generate-001` | June 24, 2025 | August 17, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 39, + "fingerprint": "sha256:8a703192637bc96b8f7a341b9ef30531bd5bb58dd26c89e4fd938dd9834daaa4", + "api": "google/gemini-models", + "version": "2026-08-17", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-fast-generate-001", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"imagen-4.0-fast-generate-001\" can be shut down from 2026-08-17, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `imagen-4.0-fast-generate-001` | June 24, 2025 | August 17, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 40, + "fingerprint": "sha256:03f79598c1d1c60b2390af7583c7346dc18c2cacc9116a52d1d1e4f575c6d070", + "api": "google/gemini-models", + "version": "2026-02-17", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-generate-preview-06-06", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"imagen-4.0-generate-preview-06-06\" can be shut down from 2026-02-17, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `imagen-4.0-generate-preview-06-06` | June 24, 2025 | February 17, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 41, + "fingerprint": "sha256:4e1ece623c8fc9d8f782fc8b9c1bc5c27904204d0cffa5e5369098ba245124e1", + "api": "google/gemini-models", + "version": "2026-02-17", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-ultra-generate-preview-06-06", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"imagen-4.0-ultra-generate-preview-06-06\" can be shut down from 2026-02-17, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `imagen-4.0-ultra-generate-preview-06-06` | June 24, 2025 | February 17, 2026 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 42, + "fingerprint": "sha256:7855e31da95e666c348f96b9ccfbc5e353c3c0c0713553ddbae260d29ebded13", + "api": "google/gemini-models", + "version": "2025-11-10", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-3.0-generate-002", + "replacement": "gemini-nano-banana-2.1" + }, + "description": "Model \"imagen-3.0-generate-002\" can be shut down from 2025-11-10, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-nano-banana-2.1` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `imagen-3.0-generate-002` | February 6, 2025 | November 10, 2025 | `gemini-nano-banana-2.1` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 43, + "fingerprint": "sha256:f4406ae5b26f233d65b6f39e0a4c99868f125bbea55dc703938ca776d8ec633b", + "api": "google/gemini-models", + "version": "2026-10-22", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.1-lite-generate-preview", + "replacement": "gemini-omni-1.2-flash" + }, + "description": "Model \"veo-3.1-lite-generate-preview\" can be shut down from 2026-10-22, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.1-lite-generate-preview` | March 31, 2026 | October 22, 2026 | `gemini-omni-1.2-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 44, + "fingerprint": "sha256:8554aabbaf268ea7946f6a3e686c1157fbff2a57997d35773f1fbf46bec5afc0", + "api": "google/gemini-models", + "version": "2026-10-22", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.1-generate-preview", + "replacement": "gemini-omni-1.2-flash" + }, + "description": "Model \"veo-3.1-generate-preview\" can be shut down from 2026-10-22, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.1-generate-preview` | October 15, 2025 | October 22, 2026 | `gemini-omni-1.2-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 45, + "fingerprint": "sha256:0a83cb678a880fb7254c61aec5e1b0e0ba19aa5435d956156d5459eddbe9be4c", + "api": "google/gemini-models", + "version": "2026-10-22", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.1-fast-generate-preview", + "replacement": "gemini-omni-1.2-flash" + }, + "description": "Model \"veo-3.1-fast-generate-preview\" can be shut down from 2026-10-22, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.1-fast-generate-preview` | October 15, 2025 | October 22, 2026 | `gemini-omni-1.2-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 46, + "fingerprint": "sha256:9ae0db34527de17bb0383edde0172525ec9032cf2a5cdac0df7af07f7c303668", + "api": "google/gemini-models", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.0-generate-001" + }, + "description": "Model \"veo-3.0-generate-001\" can be shut down from 2026-06-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.0-generate-001` | September 9, 2025 | June 30, 2026 | `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 47, + "fingerprint": "sha256:3a692dac54bbd0875feefbf6a8135be447fa904017da920eb1dc6d30e0f1d86a", + "api": "google/gemini-models", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.0-fast-generate-001" + }, + "description": "Model \"veo-3.0-fast-generate-001\" can be shut down from 2026-06-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.0-fast-generate-001` | September 9, 2025 | June 30, 2026 | `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 48, + "fingerprint": "sha256:a394fe9fdeeb5a404f2c0b561439c7236477e7fc837927962ab3aa5db1f896d5", + "api": "google/gemini-models", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-2.0-generate-001" + }, + "description": "Model \"veo-2.0-generate-001\" can be shut down from 2026-06-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-2.0-generate-001` | April 9, 2025 | June 30, 2026 | `gemini-omni-1.2-flash` or the GA models on the [Gemini Enterprise Agent Platform](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/veo/3-1-generate) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 49, + "fingerprint": "sha256:ab74adbe95ffded3bd489bbd60695d9d94948d636f8e60daac190561b6474a19", + "api": "google/gemini-models", + "version": "2025-11-12", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.0-generate-preview", + "replacement": "gemini-omni-1.2-flash" + }, + "description": "Model \"veo-3.0-generate-preview\" can be shut down from 2025-11-12, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.0-generate-preview` | July 31, 2025 | November 12, 2025 | `gemini-omni-1.2-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 50, + "fingerprint": "sha256:0f5636525a0226794daa38aa43146d185121082d0eac106e9d875b8b991d1b91", + "api": "google/gemini-models", + "version": "2025-11-12", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.0-fast-generate-preview", + "replacement": "gemini-omni-1.2-flash" + }, + "description": "Model \"veo-3.0-fast-generate-preview\" can be shut down from 2025-11-12, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `veo-3.0-fast-generate-preview` | July 31, 2025 | November 12, 2025 | `gemini-omni-1.2-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 51, + "fingerprint": "sha256:32849db67ffe3564cf53e5d5b56a8536949a7fd3aa6cb28223c0bd8656ee4e7e", + "api": "google/gemini-models", + "version": "2026-12-03", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-omni-1.1-flash" + }, + "description": "Model \"gemini-omni-1.1-flash\" can be shut down from 2026-12-03, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` (Effective December 3, 2026, the endpoint is automatically routing API requests to `gemini-omni-1.2-flash`) instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "## Gemini Omni Flash models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-omni-1.1-flash` | August 27, 2026 | December 3, 2026 | `gemini-omni-1.2-flash` (Effective December 3, 2026, the endpoint is automatically routing API requests to `gemini-omni-1.2-flash`) |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 52, + "fingerprint": "sha256:6b6d10f0220a8da62121f3ed15db742d6f8bbdd987db4671ee04709957275efc", + "api": "google/gemini-models", + "version": "2026-10-22", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-omni-flash-preview", + "replacement": "gemini-omni-1.2-flash" + }, + "description": "Model \"gemini-omni-flash-preview\" can be shut down from 2026-10-22, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-omni-1.2-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-omni-flash-preview` | June 30, 2026 | October 22, 2026 | `gemini-omni-1.2-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 53, + "fingerprint": "sha256:54a233efe659c23ad8898c69d4d211f7e48aa36acbd16fadb14a3547a6f3daf4", + "api": "google/gemini-models", + "version": "2026-08-31", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-robotics-er-1.6-preview", + "replacement": "gemini-robotics-er-2-preview" + }, + "description": "Model \"gemini-robotics-er-1.6-preview\" can be shut down from 2026-08-31, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-robotics-er-2-preview` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-robotics-er-1.6-preview` | April 14, 2026 | August 31, 2026 | `gemini-robotics-er-2-preview` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 54, + "fingerprint": "sha256:0a9481a7ed1278252e1175f2555423a03b83d4680e42f075558914f3ef3e2e5b", + "api": "google/gemini-models", + "version": "2026-04-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-robotics-er-1.5-preview", + "replacement": "gemini-robotics-er-2-preview" + }, + "description": "Model \"gemini-robotics-er-1.5-preview\" can be shut down from 2026-04-30, the earliest date Google gives: Google requests naming it fail once it is.", + "migration_hint": "Use `gemini-robotics-er-2-preview` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://aistudio.google.com/docs/deprecations", + "source_excerpt": "### Deprecated models\n| Model | Release date | Shutdown date | Recommended replacement |\n| `gemini-robotics-er-1.5-preview` | September 25, 2025 | April 30, 2026 | `gemini-robotics-er-2-preview` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + } +] diff --git a/plugins/notices/testdata/golden/google-vertex-model-retirements.json b/plugins/notices/testdata/golden/google-vertex-model-retirements.json new file mode 100644 index 0000000..6f6fc8d --- /dev/null +++ b/plugins/notices/testdata/golden/google-vertex-model-retirements.json @@ -0,0 +1,765 @@ +[ + { + "id": 1, + "fingerprint": "sha256:ef43ad5bf96238c1c0f4c9e81332efaa8e9e859831388779052f805d89d4babb", + "api": "google/vertex-model-retirements", + "version": "2026-10-20", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-pro" + }, + "description": "Model \"gemini-2.5-pro\" is shut down on 2026-10-20: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Gemini models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-2.5-pro` | June 17, 2025 | October 20, 2026 | `gemini-3.8-flash` or `gemini-3.5-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 2, + "fingerprint": "sha256:599e4f28d4387bf45611fdd8781d9a46b553fd4e8607eb1212b4bd9684f88982", + "api": "google/vertex-model-retirements", + "version": "2026-10-20", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash" + }, + "description": "Model \"gemini-2.5-flash\" is shut down on 2026-10-20: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Gemini models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-2.5-flash` | June 17, 2025 | October 20, 2026 | `gemini-3.8-flash` or `gemini-3.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 3, + "fingerprint": "sha256:8627eb166cc0481d849b3f4a6a41df8dcacfb3cfb780b78907421cbc9916a8ce", + "api": "google/vertex-model-retirements", + "version": "2026-10-20", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-lite" + }, + "description": "Model \"gemini-2.5-flash-lite\" is shut down on 2026-10-20: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Gemini models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-2.5-flash-lite` | July 22, 2025 | October 20, 2026 | `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 4, + "fingerprint": "sha256:616b469e2bd6dee6f2a2a02d7e8e575e7bb1bc940ff8ed740a0c092be3ca3bf1", + "api": "google/vertex-model-retirements", + "version": "2026-12-13", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-live-2.5-flash-native-audio", + "replacement": "gemini-3.8-live" + }, + "description": "Model \"gemini-live-2.5-flash-native-audio\" is shut down on 2026-12-13: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-live` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Gemini models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-live-2.5-flash-native-audio` | December 12, 2025 | December 13, 2026 | `gemini-3.8-live` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 5, + "fingerprint": "sha256:925571477afb104ac207094b15e93155a25d6f98baf62c651aedf0801415ad39", + "api": "google/vertex-model-retirements", + "version": "2027-03-15", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.5-flash-image", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"gemini-2.5-flash-image\" is shut down on 2027-03-15: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Gemini image models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-2.5-flash-image` | October 2, 2025 | March 15, 2027 | `gemini-3.1-flash-lite-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 6, + "fingerprint": "sha256:fd4cc7a2c302199b382abe71f33cf4c81a018d9489eec9194a0bfc6151351791", + "api": "google/vertex-model-retirements", + "version": "2027-04-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "text-embedding-005" + }, + "description": "Model \"text-embedding-005\" is shut down on 2027-04-01: Google requests naming it fail from that date.", + "migration_hint": "Google names no replacement model.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Embeddings models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `text-embedding-005` | November 18, 2024 | April 1, 2027 | |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 7, + "fingerprint": "sha256:174bced505f842a3e620a58fc0cb37092aa503454ab1dbdf37f74a6e2d3294e9", + "api": "google/vertex-model-retirements", + "version": "2027-04-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "text-embedding-004" + }, + "description": "Model \"text-embedding-004\" is shut down on 2027-04-01: Google requests naming it fail from that date.", + "migration_hint": "Google names no replacement model.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Embeddings models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `text-embedding-004` | May 14, 2024 | April 1, 2027 | |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 8, + "fingerprint": "sha256:25ba7181945e0eacf132a86af6f7b1f52ad9c0284173544164e064fe3d27eb2b", + "api": "google/vertex-model-retirements", + "version": "2027-04-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "text-multilingual-embedding-002" + }, + "description": "Model \"text-multilingual-embedding-002\" is shut down on 2027-04-01: Google requests naming it fail from that date.", + "migration_hint": "Google names no replacement model.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Embeddings models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `text-multilingual-embedding-002` | May 14, 2024 | April 1, 2027 | |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 9, + "fingerprint": "sha256:f82b985b94b11005f52d4ea0e58d68759bd90f1d175405558677772deed5f7cf", + "api": "google/vertex-model-retirements", + "version": "2027-04-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "multimodalembedding@001" + }, + "description": "Model \"multimodalembedding@001\" is shut down on 2027-04-01: Google requests naming it fail from that date.", + "migration_hint": "Google names no replacement model.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Embeddings models\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `multimodalembedding@001` | February 12, 2024 | April 1, 2027 | |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 10, + "fingerprint": "sha256:cdcfd1e991b4ace4ae24b878b08f912cc8c8c94d0e92ee797fb7c5ebb205266b", + "api": "google/vertex-model-retirements", + "version": "2027-01-28", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3.7-flash", + "replacement": "gemini-4-hydrogen" + }, + "description": "Model \"gemini-3.7-flash\" is shut down on 2027-01-28: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-4-hydrogen` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Models available for shorter availability periods\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-3.7-flash` | August 13, 2026 | January 28, 2027 | `gemini-4-hydrogen` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 11, + "fingerprint": "sha256:6d64ac7272ecbadb5aa9226e29334db0d4d06aae6edd1f60e12c971f901570c1", + "api": "google/vertex-model-retirements", + "version": "2027-01-28", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-3.6-flash", + "replacement": "gemini-4-hydrogen" + }, + "description": "Model \"gemini-3.6-flash\" is shut down on 2027-01-28: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-4-hydrogen` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Models available for shorter availability periods\n| Model ID | Release date | Retirement date | Replacement model ID |\n| `gemini-3.6-flash` | July 21, 2026 | January 28, 2027 | `gemini-4-hydrogen` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 12, + "fingerprint": "sha256:1bb244ddd4fb2ba43a99d295282f8dc123f8c8a010aa81bfcc0076bf3952b456", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.0-generate-001", + "replacement": "veo-3.1-generate-001" + }, + "description": "Model \"veo-3.0-generate-001\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `veo-3.1-generate-001` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `veo-3.0-generate-001` | July 29, 2025 | June 30, 2026 | `veo-3.1-generate-001` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 13, + "fingerprint": "sha256:a2bfd320cabd411f16c081f877c3cffc6a1569a66dc65d75e948d8fc0661bf35", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-3.0-fast-generate-001", + "replacement": "veo-3.1-fast-generate-001" + }, + "description": "Model \"veo-3.0-fast-generate-001\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `veo-3.1-fast-generate-001` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `veo-3.0-fast-generate-001` | July 29, 2025 | June 30, 2026 | `veo-3.1-fast-generate-001` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 14, + "fingerprint": "sha256:27b0426581ee7f389c1da65c919535f0bf24c0cae3fc0d87c5aed8d34b7a306c", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "veo-2.0-generate-001", + "replacement": "veo-3.1-generate-001" + }, + "description": "Model \"veo-2.0-generate-001\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `veo-3.1-generate-001` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `veo-2.0-generate-001` | May 27, 2025 | June 30, 2026 | `veo-3.1-generate-001` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 15, + "fingerprint": "sha256:09e4fe7cdc44387c7264a44d655992bd5a27288d6773fd8250a95c12f1d15660", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-generate-001", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagen-4.0-generate-001\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagen-4.0-generate-001` | August 14, 2025 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 16, + "fingerprint": "sha256:01e19784f716e18e6de20e5d29b92dc5f693a218ac80a85a6f7faed847df05b2", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-4.0-ultra-generate-001", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagen-4.0-ultra-generate-001\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagen-4.0-ultra-generate-001` | August 14, 2025 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 17, + "fingerprint": "sha256:457cfeb1eeb477b6ccd703bf5f2aeaa2d50853ec7dece2bd73dae2cb640cb233", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-3.0-generate-002", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagen-3.0-generate-002\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagen-3.0-generate-002` | January 29, 2025 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 18, + "fingerprint": "sha256:cabfde9da3d23eefa156b740e713fd626a53db013a21c3e1b1bc1a4c318c4e17", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagen-3.0-generate-001", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagen-3.0-generate-001\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagen-3.0-generate-001` | December 10, 2024 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 19, + "fingerprint": "sha256:f41ec12b39318c08224fe8faebc6867cfb378bf16e064d9eff2c136d2eaf7020", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagegeneration@006", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagegeneration@006\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagegeneration@006` | March 27, 2024 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 20, + "fingerprint": "sha256:856947b84587c850754d47d7f80372527e166991d16dd24de3f80699f89d4ce7", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagegeneration@005", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagegeneration@005\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagegeneration@005` | November 22, 2023 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 21, + "fingerprint": "sha256:0ab8d6f6b400873d7eac52fc6f8227a0c46060458d768d10856b0a51e83f30c9", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagegeneration@004", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagegeneration@004\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagegeneration@004` | | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 22, + "fingerprint": "sha256:fe51a0b57bf9d769cc3d90777822bb63cd7d09aab044be8d8509a9ccb22c3362", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagegeneration@003", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagegeneration@003\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagegeneration@003` | | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 23, + "fingerprint": "sha256:1310723d3a98db1fb0e54de57834d0a34d98d0f40919b1de6eee68400ffe34d0", + "api": "google/vertex-model-retirements", + "version": "2026-06-30", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagegeneration@002", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagegeneration@002\" is shut down on 2026-06-30: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagegeneration@002` | August 17, 2023 | June 30, 2026 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 24, + "fingerprint": "sha256:3fb712cf39ecd4e39fadd64006be677c77fa26c1b0290c0ef1fdbe3c75f77432", + "api": "google/vertex-model-retirements", + "version": "2026-06-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.0-flash\" is shut down on 2026-06-01: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-2.0-flash` | February 5, 2025 | June 1, 2026 | `gemini-3.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 25, + "fingerprint": "sha256:a296a4a21570b7f914e1b77779b91aa200915f8a53a92cc1330e916c6b8ff664", + "api": "google/vertex-model-retirements", + "version": "2026-06-01", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-2.0-flash-lite", + "replacement": "gemini-3.5-flash-lite" + }, + "description": "Model \"gemini-2.0-flash-lite\" is shut down on 2026-06-01: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.5-flash-lite` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-2.0-flash-lite` | February 25, 2025 | June 1, 2026 | `gemini-3.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 26, + "fingerprint": "sha256:28254077d822afb2858f2d40445980c945755d305b5506cde2524c2639c4c52f", + "api": "google/vertex-model-retirements", + "version": "2025-05-24", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.5-pro-001" + }, + "description": "Model \"gemini-1.5-pro-001\" is shut down on 2025-05-24: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-2.5-flash, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.5-pro-001` | May 24, 2024 | May 24, 2025 | `gemini-2.5-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 27, + "fingerprint": "sha256:236a1810846de81794735a1b9c73a40d4a4d0ccdccbb77db09a320f53f25f052", + "api": "google/vertex-model-retirements", + "version": "2025-09-24", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.5-pro-002" + }, + "description": "Model \"gemini-1.5-pro-002\" is shut down on 2025-09-24: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-2.5-flash, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.5-pro-002` | September 24, 2024 | September 24, 2025 | `gemini-2.5-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 28, + "fingerprint": "sha256:3a54f4a8eb835367ab091e3c8b4fd3cb3b4ab61e713716affbf05adcf18e5648", + "api": "google/vertex-model-retirements", + "version": "2025-05-24", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.5-flash-001" + }, + "description": "Model \"gemini-1.5-flash-001\" is shut down on 2025-05-24: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 instead: Google's recommended replacement. (Google first named gemini-2.5-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.5-flash-001` | May 24, 2024 | May 24, 2025 | `gemini-2.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 29, + "fingerprint": "sha256:64da17ec012eb0d5d98ad9abec413d450998e11e2dcd25823d67d8c3a791a389", + "api": "google/vertex-model-retirements", + "version": "2025-09-24", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.5-flash-002" + }, + "description": "Model \"gemini-1.5-flash-002\" is shut down on 2025-09-24: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 instead: Google's recommended replacement. (Google first named gemini-2.5-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.5-flash-002` | September 24, 2024 | September 24, 2025 | `gemini-2.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 30, + "fingerprint": "sha256:ae5f88ca2317ecabd2ac01b82f6f931deb5adf0015c376b4499f6ea739caf66f", + "api": "google/vertex-model-retirements", + "version": "2025-05-24", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "textembedding-gecko-multilingual@001", + "replacement": "gemini-embedding-001" + }, + "description": "Model \"textembedding-gecko-multilingual@001\" is shut down on 2025-05-24: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-embedding-001` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `textembedding-gecko-multilingual@001` | November 2, 2023 | May 24, 2025 | `gemini-embedding-001` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 31, + "fingerprint": "sha256:643b42a3e2f9609a6a6c922e875cbe1a505c24c98e14f984fff4661dd1c4326a", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.0-pro-001" + }, + "description": "Model \"gemini-1.0-pro-001\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-2.5-flash, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.0-pro-001` | February 15, 2024 | April 21, 2025 | `gemini-2.5-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 32, + "fingerprint": "sha256:de0b474847a57fa37c32bcd2dc877d5ee8d701e04da3021ffbd5a4c0e6cc133b", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.0-pro-002" + }, + "description": "Model \"gemini-1.0-pro-002\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-2.5-flash, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.0-pro-002` | April 9, 2024 | April 21, 2025 | `gemini-2.5-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 33, + "fingerprint": "sha256:71a047e6aa5973d29fb5c14cbad6f3d6d867b44ca1c23708001571ff2defe05f", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "gemini-1.0-pro-vision-001" + }, + "description": "Model \"gemini-1.0-pro-vision-001\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` instead: Google's recommended replacement. (Google first named gemini-2.5-flash, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `gemini-1.0-pro-vision-001` | February 15, 2024 | April 21, 2025 | `gemini-2.5-flash` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 34, + "fingerprint": "sha256:6ccf6a6ea1e5e02053b07007fd71bc07e2aa55ec01bba21a480316faae823278", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "text-bison" + }, + "description": "Model \"text-bison\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 instead: Google's recommended replacement. (Google first named gemini-2.5-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `text-bison` | May 2023 | April 21, 2025 | `gemini-2.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 35, + "fingerprint": "sha256:02b2b6b0d29d49017b545b77d4907cbd03136b1b77d1c8eb7337e9e1eb738607", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "chat-bison" + }, + "description": "Model \"chat-bison\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 instead: Google's recommended replacement. (Google first named gemini-2.5-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `chat-bison` | May 2023 | April 21, 2025 | `gemini-2.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 36, + "fingerprint": "sha256:2fc76102654a56b32be0dd835a9d862cfa95f2cafd0afff75334f99cace0db82", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "code-gecko" + }, + "description": "Model \"code-gecko\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.8-flash` or `gemini-3.5-flash-lite` or Gemma 4 instead: Google's recommended replacement. (Google first named gemini-2.5-flash-lite, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `code-gecko` | May 2023 | April 21, 2025 | `gemini-2.5-flash-lite` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 37, + "fingerprint": "sha256:a9a0bfbedd63c0022a969ca211e7db7045ff9f305110511f22e8a96edb2d809e", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "textembedding-gecko@002", + "replacement": "gemini-embedding-001" + }, + "description": "Model \"textembedding-gecko@002\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-embedding-001` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `textembedding-gecko@002` | November 2, 2023 | April 21, 2025 | `gemini-embedding-001` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 38, + "fingerprint": "sha256:5ab1b9bb58a2e1bc39a07e87308bfd8b616dab5514f50826beebad3619341215", + "api": "google/vertex-model-retirements", + "version": "2025-04-21", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "textembedding-gecko@001", + "replacement": "gemini-embedding-001" + }, + "description": "Model \"textembedding-gecko@001\" is shut down on 2025-04-21: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-embedding-001` instead: Google's recommended replacement.", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `textembedding-gecko@001` | June 7, 2023 | April 21, 2025 | `gemini-embedding-001` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + }, + { + "id": 39, + "fingerprint": "sha256:e78fa1f0b47b02780b33bdb22a95a9cff1a7635f3e5de8c61bd1d3fc87f7b239", + "api": "google/vertex-model-retirements", + "version": "2025-09-24", + "change_type": "breaking", + "breaking": true, + "subject": { + "type": "model", + "provider": "google", + "name": "imagetext", + "replacement": "gemini-3.1-flash-lite-image" + }, + "description": "Model \"imagetext\" is shut down on 2025-09-24: Google requests naming it fail from that date.", + "migration_hint": "Use `gemini-3.1-flash-lite-image` instead: Google's recommended replacement. (Google first named gemini-2.5-flash-image, which is itself retired.)", + "source_url": "https://web.archive.org/web/20261114120000/https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions", + "source_excerpt": "### Retired models\n| Model ID | Release date | Retirement date | Recommended upgrade |\n| `imagetext` | June 7, 2023 | September 24, 2025 | `gemini-2.5-flash-image` |", + "confidence": 1, + "detected_at": "2026-11-14T12:00:00Z" + } +] diff --git a/plugins/openapi/adapter/convex.go b/plugins/openapi/adapter/convex.go index 75ca537..a66d74d 100644 --- a/plugins/openapi/adapter/convex.go +++ b/plugins/openapi/adapter/convex.go @@ -12,19 +12,19 @@ import ( // Variables, not constants, only so tests can point them at a local server. var ( // convexCommitsURL lists the commits that changed the Deployment API - // spec in get-convex/convex-backend, newest first; with per_page=1, the + // spec in convex/convex-backend, newest first; with per_page=1, the // newest. - convexCommitsURL = "https://api.github.com/repos/get-convex/convex-backend/commits?path=npm-packages/@convex-dev/platform/deployment-openapi.json&per_page=1" + convexCommitsURL = "https://api.github.com/repos/convex/convex-backend/commits?path=npm-packages/@convex-dev/platform/deployment-openapi.json&per_page=1" // convexCommitURL is one commit, for its date. - convexCommitURL = "https://api.github.com/repos/get-convex/convex-backend/commits/%s" + convexCommitURL = "https://api.github.com/repos/convex/convex-backend/commits/%s" // convexSpecURLTemplate is the Deployment API spec at one commit: 68 // commits from 2025-08-19 to 2026-11-16 (checked 2026-11-19), and a // commit never changes. - convexSpecURLTemplate = "https://raw.githubusercontent.com/get-convex/convex-backend/%s/npm-packages/@convex-dev/platform/deployment-openapi.json" + convexSpecURLTemplate = "https://raw.githubusercontent.com/convex/convex-backend/%s/npm-packages/@convex-dev/platform/deployment-openapi.json" ) // Convex adapts the Convex Deployment API spec (`{deployment-url}/api/v1`) -// in get-convex/convex-backend for the openapi plugin. A tag here is the +// in convex/convex-backend for the openapi plugin. A tag here is the // commit that last changed the spec, as for Supabase. // // The repo does tag releases, `precompiled-YYYY-MM-DD-` (1,213 of diff --git a/plugins/openapi/adapter/versions.go b/plugins/openapi/adapter/versions.go index dd2f0af..a215aab 100644 --- a/plugins/openapi/adapter/versions.go +++ b/plugins/openapi/adapter/versions.go @@ -62,7 +62,7 @@ func (Neon) Versions(ctx context.Context) ([]plugin.Version, error) { // Versions are the commits that changed Convex's deployment API spec. func (Convex) Versions(ctx context.Context) ([]plugin.Version, error) { - return commits(ctx, "get-convex/convex-backend", "npm-packages/@convex-dev/platform/deployment-openapi.json") + return commits(ctx, "convex/convex-backend", "npm-packages/@convex-dev/platform/deployment-openapi.json") } // Versions are the commits that changed PlanetScale's spec. diff --git a/plugins/openapi/convex_test.go b/plugins/openapi/convex_test.go index 0d3afcb..f84525f 100644 --- a/plugins/openapi/convex_test.go +++ b/plugins/openapi/convex_test.go @@ -55,7 +55,7 @@ func (fakeConvexAdapter) SourcePointer(content []byte) func(string) string { func convexFile(tag string) string { return "testdata/convex-" + tag + ".json" } func convexURL(tag string) string { - return "https://raw.githubusercontent.com/get-convex/convex-backend/" + convexCommits[tag][0] + "/npm-packages/@convex-dev/platform/deployment-openapi.json" + return "https://raw.githubusercontent.com/convex/convex-backend/" + convexCommits[tag][0] + "/npm-packages/@convex-dev/platform/deployment-openapi.json" } // convexPlugin is the plugin exactly as registered, over the saved copies. diff --git a/plugins/openapi/openapi.go b/plugins/openapi/openapi.go index 9cb97ef..200bffd 100644 --- a/plugins/openapi/openapi.go +++ b/plugins/openapi/openapi.go @@ -145,7 +145,7 @@ func init() { Sources: []plugin.Source{{ ID: "deployment-api", Layer: plugin.LayerAPI, Page: "providers/convex.md", Watches: "Deployment API operations deprecated, and deprecated operations removed, between commits of the spec", - URLs: []string{"https://github.com/get-convex/convex-backend"}, + URLs: []string{"https://github.com/convex/convex-backend"}, Plugin: Plugin{Adapter: adapter.Convex{}, Diff: convexDiff, Keep: convexKeep}, }}, }) diff --git a/plugins/openapi/testdata/README.md b/plugins/openapi/testdata/README.md index 2e5210d..cdd189e 100644 --- a/plugins/openapi/testdata/README.md +++ b/plugins/openapi/testdata/README.md @@ -31,8 +31,8 @@ Each pair is a real breaking change between two releases of a provider's own spe | `neon-5c57d009.json`, `neon-93b93dc9.json` | https://raw.githubusercontent.com/neondatabase/neon-pkgs/5c57d0095a9a4594a3c8b09d499b132902e7c42e/packages/sdk/spec/neon-openapi.json (and `93b93dc9e4d1b4ab48dac6c8ccba76b35541b476`) | 2026-11-19 | Excerpt for testing; © Neon. neondatabase/neon-pkgs is Apache-2.0, but the spec's own `info.license` says "Proprietary" | "Deprecated: to test a branch's already-saved configuration, use `sendNeonAuthEmailProviderTest`" (`POST /projects/{project_id}/branches/{branch_id}/auth/send_test_email`, new in `93b93dc9`) | | `neon-4c6b3be4.json`, `neon-4497de89.json` | https://raw.githubusercontent.com/neondatabase/neon-pkgs/4c6b3be46b1b333e7f910db51218ad144de27179/packages/sdk/spec/neon-openapi.json (and `4497de89a5e84b38956fde686d271f99317b8fdb`) | 2026-11-19 | Excerpt for testing; © Neon. neondatabase/neon-pkgs is Apache-2.0, but the spec's own `info.license` says "Proprietary" | `"/projects/{project_id}/branches/{branch_id}/recover": {` (in `4c6b3be4`, gone in `4497de89` without being deprecated): the drop test | | `neon-api-client-2.7.2.yaml`, `neon-api-client-2.7.3.yaml` | `public-v2-for-users.gen.yaml` in https://registry.npmjs.org/@neondatabase/api-client/-/api-client-2.7.2.tgz (and `api-client-2.7.3.tgz`) | 2026-11-19 | Excerpt for testing; © Neon. The package is MIT, but the spec's own `info.license` says "Proprietary" | "**Deprecated.** Use `GET /consumption_history/projects` (`getConsumptionHistoryPerProject`)" (`GET /consumption_history/account`, in 2.7.2, gone in 2.7.3) | -| `convex-f35879bb.json`, `convex-5e5159cb.json` | https://raw.githubusercontent.com/get-convex/convex-backend/f35879bb396491942bf8ecbc8ef5e4280499f89f/npm-packages/@convex-dev/platform/deployment-openapi.json (and `5e5159cbea5188e9da5400febda1b031a233eea0`) | 2026-11-19 | FSL-1.1-Apache-2.0 (get-convex/convex-backend `LICENSE.md`; the spec's own `info.license` is `LicenseRef-FSL-1.1-Apache-2.0`): excerpt for testing, © Convex, Inc.; maintainers, please confirm | "Deprecated: use `GET /integrations` instead." (`GET /list_log_streams`, and five more log stream operations, new in `5e5159cb`) | -| `convex-3f6edf7a.json`, `convex-3ead9091.json` | https://raw.githubusercontent.com/get-convex/convex-backend/3f6edf7ab8f3f98e027f317633246a19348eabcc/npm-packages/@convex-dev/platform/deployment-openapi.json (and `3ead909103b7f5897f529c031e80991ad174b07e`) | 2026-11-19 | FSL-1.1-Apache-2.0 (get-convex/convex-backend `LICENSE.md`; the spec's own `info.license` is `LicenseRef-FSL-1.1-Apache-2.0`): excerpt for testing, © Convex, Inc.; maintainers, please confirm | `"name": {` in `UsageLimitConfigRequest` and `UsageLimitConfigResponse` (in `3f6edf7a`, gone in `3ead9091` without being deprecated): the drop test | +| `convex-f35879bb.json`, `convex-5e5159cb.json` | https://raw.githubusercontent.com/convex/convex-backend/f35879bb396491942bf8ecbc8ef5e4280499f89f/npm-packages/@convex-dev/platform/deployment-openapi.json (and `5e5159cbea5188e9da5400febda1b031a233eea0`) | 2026-11-19 | FSL-1.1-Apache-2.0 (convex/convex-backend `LICENSE.md`; the spec's own `info.license` is `LicenseRef-FSL-1.1-Apache-2.0`): excerpt for testing, © Convex, Inc.; maintainers, please confirm | "Deprecated: use `GET /integrations` instead." (`GET /list_log_streams`, and five more log stream operations, new in `5e5159cb`) | +| `convex-3f6edf7a.json`, `convex-3ead9091.json` | https://raw.githubusercontent.com/convex/convex-backend/3f6edf7ab8f3f98e027f317633246a19348eabcc/npm-packages/@convex-dev/platform/deployment-openapi.json (and `3ead909103b7f5897f529c031e80991ad174b07e`) | 2026-11-19 | FSL-1.1-Apache-2.0 (convex/convex-backend `LICENSE.md`; the spec's own `info.license` is `LicenseRef-FSL-1.1-Apache-2.0`): excerpt for testing, © Convex, Inc.; maintainers, please confirm | `"name": {` in `UsageLimitConfigRequest` and `UsageLimitConfigResponse` (in `3f6edf7a`, gone in `3ead9091` without being deprecated): the drop test | | `planetscale-e631095a.yaml`, `planetscale-fc13e09d.yaml` | https://raw.githubusercontent.com/planetscale/terraform-provider-planetscale/e631095aa649a6797578a1d51d861b91e0568aa1/schemas/openapi.yaml (and `fc13e09d0c18b893aabd3e02d175d13957bba677`) | 2026-11-19 | none stated for the file (its `info` says "© 2026 PlanetScale, Inc."); the repo, planetscale/terraform-provider-planetscale, is Apache-2.0. Excerpt for testing; © PlanetScale | "Deprecated. Use GET /organizations/:organization/databases/:database/branches/:branch/change-requests instead." (`GET .../neki-changes`, new in `fc13e09d`) | | `planetscale-b49c3540.yaml`, `planetscale-f6d6ad4d.yaml` | https://raw.githubusercontent.com/planetscale/terraform-provider-planetscale/b49c354080667638b79781801f0517ae07bc55b8/schemas/openapi.yaml (and `f6d6ad4d3929f6c1ef021eb13c1541ba31f72107`) | 2026-11-19 | none stated for the file (its `info` says "© 2026 PlanetScale, Inc."); the repo, planetscale/terraform-provider-planetscale, is Apache-2.0. Excerpt for testing; © PlanetScale | `/organizations/{organization}/databases/{database}/branches/{branch}/read-only-replicas:` (in `b49c3540`, never deprecated, gone in `f6d6ad4d`, where `.../dedicated-read-replicas:` is): the drop test | | `appwrite-1.9.x-8c00ba35-server.json`, `appwrite-1.9.x-7d74bf9f-server.json` | https://raw.githubusercontent.com/appwrite/specs/8c00ba356b01d43fbc6c88c60fb2a4fc99e04b40/specs/1.9.x/open-api3-1.9.x-server.json (and `7d74bf9f3c0c990745e822f5935bcfaca310fd06`) | 2026-11-19 | BSD-3-Clause (appwrite/specs) | `"replaceWith": "tablesDB.createTransaction"` (`x-appwrite.deprecated` of `POST /databases/transactions`, flagged in `7d74bf9f` with 13 more) | diff --git a/plugins/openapi/testdata/golden/convex.json b/plugins/openapi/testdata/golden/convex.json index fbb46cc..8cc1077 100644 --- a/plugins/openapi/testdata/golden/convex.json +++ b/plugins/openapi/testdata/golden/convex.json @@ -14,7 +14,7 @@ "operation": "POST /api/v1/create_log_stream" }, "description": "Operation POST /api/v1/create_log_stream marked deprecated.", - "source_url": "https://raw.githubusercontent.com/get-convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", + "source_url": "https://raw.githubusercontent.com/convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", "source_pointer": "/paths/~1create_log_stream/post", "source_excerpt": "{\"deprecated\":true,\"description\":\"Create a new log stream for the deployment. Errors if a log stream of the\\ngiven type already exists.\\n\\nDeprecated: use `POST /integrations` instead.\",\"operationId\":\"create_log_stream\",\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"$ref\":\"#/components/schemas/CreateLogStreamArgs\"}}},\"required\":true},\"responses\":{\"200\":{\"content\":{\"application/json\":{\"schema\":{\"$ref\":\"#/components/schemas/CreateLogStreamResponse\"}}},\"description\":\"\"}},\"security\":[{\"Deploy Key\":[]},{\"OAuth Team Token\":[]},{\"Team Token\":[]},{\"OAuth Project Token\":[]}],\"summary\":\"Create log stream\",\"tags\":[\"Log Streams\"]}", "confidence": 1, @@ -35,7 +35,7 @@ "operation": "POST /api/v1/delete_log_stream/{id}" }, "description": "Operation POST /api/v1/delete_log_stream/{id} marked deprecated.", - "source_url": "https://raw.githubusercontent.com/get-convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", + "source_url": "https://raw.githubusercontent.com/convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", "source_pointer": "/paths/~1delete_log_stream~1{id}/post", "source_excerpt": "{\"deprecated\":true,\"description\":\"Delete the deployment's log stream with the given id.\\n\\nDeprecated: use `DELETE /integrations/{id}` instead.\",\"operationId\":\"delete_log_stream\",\"parameters\":[{\"description\":\"id of the log stream to delete\",\"in\":\"path\",\"name\":\"id\",\"required\":true,\"schema\":{\"type\":\"string\"}}],\"responses\":{\"200\":{\"description\":\"\"}},\"security\":[{\"Deploy Key\":[]},{\"OAuth Team Token\":[]},{\"Team Token\":[]},{\"OAuth Project Token\":[]}],\"summary\":\"Delete log stream\",\"tags\":[\"Log Streams\"]}", "confidence": 1, @@ -56,7 +56,7 @@ "operation": "GET /api/v1/get_log_stream/{id}" }, "description": "Operation GET /api/v1/get_log_stream/{id} marked deprecated.", - "source_url": "https://raw.githubusercontent.com/get-convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", + "source_url": "https://raw.githubusercontent.com/convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", "source_pointer": "/paths/~1get_log_stream~1{id}/get", "source_excerpt": "{\"deprecated\":true,\"description\":\"Get the config for a specific log stream by id.\\n\\nDeprecated: use `GET /integrations/{id}` instead.\",\"operationId\":\"get_log_stream\",\"parameters\":[{\"description\":\"id of the log stream to retrieve\",\"in\":\"path\",\"name\":\"id\",\"required\":true,\"schema\":{\"type\":\"string\"}}],\"responses\":{\"200\":{\"content\":{\"application/json\":{\"schema\":{\"$ref\":\"#/components/schemas/LogStreamConfig\"}}},\"description\":\"\"}},\"security\":[{\"Deploy Key\":[]},{\"OAuth Team Token\":[]},{\"Team Token\":[]},{\"OAuth Project Token\":[]}],\"summary\":\"Get log stream\",\"tags\":[\"Log Streams\"]}", "confidence": 1, @@ -77,7 +77,7 @@ "operation": "GET /api/v1/list_log_streams" }, "description": "Operation GET /api/v1/list_log_streams marked deprecated.", - "source_url": "https://raw.githubusercontent.com/get-convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", + "source_url": "https://raw.githubusercontent.com/convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", "source_pointer": "/paths/~1list_log_streams/get", "source_excerpt": "{\"deprecated\":true,\"description\":\"List configs for all existing log streams in a deployment.\\n\\nDeprecated: use `GET /integrations` instead.\",\"operationId\":\"list_log_streams\",\"responses\":{\"200\":{\"content\":{\"application/json\":{\"schema\":{\"items\":{\"$ref\":\"#/components/schemas/LogStreamConfig\"},\"type\":\"array\"}}},\"description\":\"\"}},\"security\":[{\"Deploy Key\":[]},{\"OAuth Team Token\":[]},{\"Team Token\":[]},{\"OAuth Project Token\":[]}],\"summary\":\"List log streams\",\"tags\":[\"Log Streams\"]}", "confidence": 1, @@ -98,7 +98,7 @@ "operation": "POST /api/v1/rotate_webhook_secret/{id}" }, "description": "Operation POST /api/v1/rotate_webhook_secret/{id} marked deprecated.", - "source_url": "https://raw.githubusercontent.com/get-convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", + "source_url": "https://raw.githubusercontent.com/convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", "source_pointer": "/paths/~1rotate_webhook_secret~1{id}/post", "source_excerpt": "{\"deprecated\":true,\"description\":\"Rotate the secret for the webhook log stream.\\n\\nDeprecated: use `POST /integrations/{id}/rotate_webhook_secret` instead.\",\"operationId\":\"rotate_webhook_secret\",\"parameters\":[{\"description\":\"id of the webhook log stream for which to rotate the secret\",\"in\":\"path\",\"name\":\"id\",\"required\":true,\"schema\":{\"type\":\"string\"}}],\"responses\":{\"200\":{\"content\":{\"application/json\":{\"schema\":{\"$ref\":\"#/components/schemas/RotateLogStreamSecretResponse\"}}},\"description\":\"\"}},\"security\":[{\"Deploy Key\":[]},{\"OAuth Team Token\":[]},{\"Team Token\":[]},{\"OAuth Project Token\":[]}],\"summary\":\"Rotate webhook log stream secret\",\"tags\":[\"Log Streams\"]}", "confidence": 1, @@ -119,7 +119,7 @@ "operation": "POST /api/v1/update_log_stream/{id}" }, "description": "Operation POST /api/v1/update_log_stream/{id} marked deprecated.", - "source_url": "https://raw.githubusercontent.com/get-convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", + "source_url": "https://raw.githubusercontent.com/convex/convex-backend/5e5159cbea5188e9da5400febda1b031a233eea0/npm-packages/@convex-dev/platform/deployment-openapi.json", "source_pointer": "/paths/~1update_log_stream~1{id}/post", "source_excerpt": "{\"deprecated\":true,\"description\":\"Update an existing log stream for the deployment. Omit a field to keep the\\nexisting value, and use `null` to unset a field.\\n\\nDeprecated: use `PATCH /integrations/{id}` instead.\",\"operationId\":\"update_log_stream\",\"parameters\":[{\"description\":\"id of the log stream to update\",\"in\":\"path\",\"name\":\"id\",\"required\":true,\"schema\":{\"type\":\"string\"}}],\"requestBody\":{\"content\":{\"application/json\":{\"schema\":{\"$ref\":\"#/components/schemas/UpdateLogStreamArgs\"}}},\"required\":true},\"responses\":{\"200\":{\"description\":\"\"}},\"security\":[{\"Deploy Key\":[]},{\"OAuth Team Token\":[]},{\"Team Token\":[]},{\"OAuth Project Token\":[]}],\"summary\":\"Update log stream\",\"tags\":[\"Log Streams\"]}", "confidence": 1, diff --git a/providers/convex.md b/providers/convex.md index 1aced5f..c91632d 100644 --- a/providers/convex.md +++ b/providers/convex.md @@ -8,7 +8,7 @@ Kind: `openapi` (`plugins/openapi`), with `adapter.Convex`. ## Why this source -- **Source:** `npm-packages/@convex-dev/platform/deployment-openapi.json` in [get-convex/convex-backend](https://github.com/get-convex/convex-backend), pinned to the commit that last changed it (`https://raw.githubusercontent.com/get-convex/convex-backend//npm-packages/@convex-dev/platform/deployment-openapi.json`). The newest such commit comes from the GitHub commits API. Checked on 2026-11-19. +- **Source:** `npm-packages/@convex-dev/platform/deployment-openapi.json` in [convex/convex-backend](https://github.com/convex/convex-backend) (the org was `get-convex` until 2026; GitHub redirects the old URLs, checked 2026-11-20), pinned to the commit that last changed it (`https://raw.githubusercontent.com/convex/convex-backend//npm-packages/@convex-dev/platform/deployment-openapi.json`). The newest such commit comes from the GitHub commits API. Checked on 2026-11-19. - **Why a commit, not a release tag:** the repo tags `precompiled-YYYY-MM-DD-` builds (1,213 of them), but those are daily builds of the self-hosted backend, not releases of the API. There are several on some days, ordered only by commit date, and the spec is the same in most of them. The spec at a tag is the spec at the last commit before it that changed the file, so the commits see every version a tag would, and finding the newest takes one call instead of paging through the tags. A commit never changes, so it can be cited and replayed. - **Why this one:** - It's Convex's own description of the API: its docs build renders the API reference from it. @@ -16,7 +16,7 @@ Kind: `openapi` (`plugins/openapi`), with `adapter.Convex`. - There are 68 versions from 2025-08-19, when the spec was added, to 2026-11-16. - **Alternatives considered:** - **The Management API spec** (`management-openapi.json`, next to it: teams, projects, deployments). Its `info.license` is `LicenseRef-Convex`, which nothing in the repo defines, so the plugin neither reads nor saves it. - - **The SDK changelogs** (`convex` on npm, `get-convex/convex-js` `CHANGELOG.md`; `convex-py`). One flat list of bullets per version (95 versions in `convex-js`), with no removed or deprecated sections for the `changelog` plugin to read. + - **The SDK changelogs** (`convex` on npm, `convex/convex-js` `CHANGELOG.md`; `convex-py`). One flat list of bullets per version (95 versions in `convex-js`), with no removed or deprecated sections for the `changelog` plugin to read. - **[Convex News](https://news.convex.dev/)** (RSS at `https://news.convex.dev/rss/`). Product news and announcements, newest post 2026-09-21; it doesn't name API operations. - **The `@convex-dev/platform` npm package** (0.1.11). Its tarball has only `package.json` and the generated client, not the specs. - **Quote:** "Deprecated: use `GET /integrations` instead." (`GET /api/v1/list_log_streams`, deprecated in the spec on 2026-11-05) diff --git a/providers/github-graphql.md b/providers/github-graphql.md new file mode 100644 index 0000000..134ae57 --- /dev/null +++ b/providers/github-graphql.md @@ -0,0 +1,39 @@ +# GitHub GraphQL API (`github/graphql`) + +## What it watches + +Removals GitHub announces for its GraphQL API: a field, an argument, an input field or an enum value, with the date it goes. One `deprecation` event per newly announced removal, its `version` the removal date. + +Kind: `catalog` (`plugins/catalog`), the `UpcomingChanges` reader (`plugins/catalog/graphql.go`). + +## Why this source + +- **Source:** [`src/graphql/data/fpt/upcoming-changes.json`](https://github.com/github/docs/blob/main/src/graphql/data/fpt/upcoming-changes.json) in github/docs, read at every commit that changed it (listed from GitHub's commits API, `?path=`). It's the file [Breaking changes](https://docs.github.com/en/graphql/overview/breaking-changes) on docs.github.com is built from. Checked on 2026-11-21: 1,291 entries, every one `"criticality": "breaking"`, 29 commits since 2023-05-01. +- **Why this one:** one JSON object keyed by removal date, each entry naming its location (`RepositoryPermission.TRIAGE_PLUS`), what to do and why, from GitHub's own schema tooling. A commit never changes, so the raw file at it is its own citation. +- **Alternatives considered:** + - **The Breaking changes page** (HTML): the same entries, rendered; the JSON is what it's made from. + - **The GraphQL schema** (`schema.docs.graphql`, `@deprecated(reason: "… Removal on 2027-04-01 UTC.")`): the same dates inside a GraphQL SDL, which needs a schema reader no kind has. + - **The GitHub changelog**: announces some of these, in prose, with no location. +- **Quote:** `{"location": "RepositoryPermission.TRIAGE_PLUS", "description": "

TRIAGE_PLUS will be removed. Use MODERATE instead.

", "date": "2027-04-01", "criticality": "breaking"}`. + +## How the provider announces changes + +- GitHub's GraphQL API has no versions: a change is announced here with its removal date, a quarter's first day (`2026-10-01`, `2027-01-01`). +- Announcements come a few at a time (one or two a month in 2026), sometimes in a batch (1,109 entries on 2025-04-14, the audit-log fields). + +## What the plugin reads and ignores + +- Reads every entry of the file at each commit. An entry (location and date) in the newer commit's file that the older one didn't have is a `deprecation` event: `version` the removal date (the API has no versions; the day it breaks is what a gate compares, as a model's shutdown date is), `previous_version` the older commit's date, the hint the entry's description and reason as text. The excerpt is the entry's fields as the file writes them, its `owner` left out. +- Subject (`api_operation`): an input object's field (`AddPullRequestReviewInput.comments`) or a root field's argument (`Query.sponsorables.dependencyEcosystem`) is a `request_parameter` of `POST /graphql`, its `property` the location; any other location (a root field itself, a type's field or its argument, an enum value) is a `schema_property`, its `schema` the type and its `property` the rest (`RepositoryPermission` / `TRIAGE_PLUS`). +- An entry a commit drops while still upcoming and a later commit restores is the same event (same removal date, same fingerprint), so it isn't announced twice. +- Ignores an entry dated before the commit that adds it: a revert putting back a removal already made, not an announcement. On 2026-01-05 the file lost 17 such entries, got them back the next day and lost them again on 2026-01-08: no event (the pinned drop test). +- Ignores an entry leaving the file: the removal shipped, or GitHub withdrew it, and the file doesn't say which. +- A first read, with no commit before it, has nothing to compare: no events. + +## Known gaps + +- `previous_version` (a commit date) to `version` (the removal date) isn't a range of this source's listed versions: the removal date is when the change breaks, as a model's shutdown date is. Whether the feed's coverage logic should treat such a pair differently is for the contract (patch-it) to say. + +- The removal itself (the day it ships) isn't a separate `breaking` event; the deprecation names the date. +- GitHub Enterprise Server's own files (`ghes-*`) aren't read. +- A location GitHub moves to a new date is a new event (a new `version`), alongside the first. diff --git a/providers/google-gemini-models.md b/providers/google-gemini-models.md new file mode 100644 index 0000000..4f002dd --- /dev/null +++ b/providers/google-gemini-models.md @@ -0,0 +1,33 @@ +# Google Gemini API models (`google/gemini-models`) + +## What it watches + +Gemini API models Google shuts down: every model on Google's own Gemini API deprecations page with a shutdown date, one `model` event per model name, with the replacement Google recommends. Google gives each date as the earliest a model may be shut down; the event says so. + +Kind: `notices` (`plugins/notices`), with the deprecations-table reader (`plugins/notices/retire`, `retire.Gemini`), reading Markdoc tables. + +## Why this source + +- **Source:** [Gemini deprecations](https://ai.google.dev/gemini-api/docs/deprecations), which redirects to `https://aistudio.google.com/docs/deprecations`; that URL serves the page as Markdown (Markdoc `{% table %}` blocks), and the plugin reads it there. Checked on 2026-11-21. +- **Why this one:** it's Google's own table of every Gemini API model with its release date, its shutdown date and the recommended replacement, one table per model family, the shut-down ones kept under "Deprecated models". It's where Google says deprecation dates are tracked: "Deprecation announcements are made on the Release notes page, and the announced earliest shutdown dates are tracked on this page." +- **Alternatives considered:** + - **The Gemini API release notes** (`https://aistudio.google.com/docs/changelog`): the same deprecations, announced in prose, one entry per day. The table is the same facts, already structured. + - **Vertex AI's model versions page** (`google/vertex-model-retirements`): the same models on Google Cloud, with Google Cloud's own retirement dates, which differ from the Gemini API's (gemini-2.5-pro: 2026-10-20 on Vertex AI, 2026-12-01 here). A separate source: a repo reaches one or the other. + - **The Gemini API's models list** (`GET /v1beta/models`): what's served now, with no dates. +- **Quote:** "| `gemini-2.0-flash` | February 5, 2025 | June 1, 2026 | `gemini-3.6-flash` |" (Gemini 2.0 models, Deprecated models), and above the tables: "The shutdown dates listed in the table indicate the earliest possible dates on which a model might be retired". + +## How the provider announces changes + +- Models are named by version (`gemini-2.5-flash`, `gemini-2.5-flash-preview-09-2025`); a preview gets a shutdown date months after its stable model ships, a stable model about a year after its successor. +- A model is announced in the release notes, then its date appears here. Some shut-down models' requests are routed to a successor ("effective December 1, 2026, API requests to `gemini-2.5-pro` will automatically route to `gemini-3.8-flash`"); the replacement cell says so, and the hint quotes it. + +## What the plugin reads and ignores + +- Reads every Markdoc table with a "Shutdown date", a "Model" and a "Recommended replacement" column: one `breaking` `model` event per model name with a date, `version` the date. `replacement` is set when the cell names exactly one plain model; otherwise the hint quotes the cell. +- Ignores a row whose date isn't a date ("No shutdown date announced"), the managed agents' tables (an "Agent" column, not a model), and a cell that isn't a plain model id (a footnote mark). The pinned drop test: the Gemini 4 models and the agents, next to the two shut-down Gemini 3 previews, give only those two events. +- A read with far fewer models than the last one fails (the table changed shape), as do a page with no table and a block page. + +## Known gaps + +- Google's dates are the earliest possible; a later exact date only shows up when Google edits the row, which is then a new event. +- Models served only on Vertex AI are the other source's. diff --git a/providers/google-vertex-model-retirements.md b/providers/google-vertex-model-retirements.md new file mode 100644 index 0000000..a9ab1f2 --- /dev/null +++ b/providers/google-vertex-model-retirements.md @@ -0,0 +1,32 @@ +# Google Vertex AI model retirements (`google/vertex-model-retirements`) + +## What it watches + +Generative AI models Google Cloud retires on Vertex AI (now called Gemini Enterprise Agent Platform): every model on Google Cloud's model versions page with a plain retirement date, one `model` event per model id, with the replacement Google names. + +Kind: `notices` (`plugins/notices`), with the deprecations-table reader (`plugins/notices/retire`, `retire.Vertex`), reading HTML tables. + +## Why this source + +- **Source:** [Model versions and lifecycle](https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/model-versions) (the old `cloud.google.com/vertex-ai/generative-ai/docs/learn/model-versions` redirects there). Checked on 2026-11-21. +- **Why this one:** it's Google Cloud's own table of every model id with its release date, its retirement date and its replacement, including the "Retired models" table. The release-notes feed (`google/vertex-ai-models`) only announces some deprecations, in prose; this page is where the dates are kept. +- **Alternatives considered:** + - **The Vertex AI release notes feed**: already a source (`google/vertex-ai-models`), for announcements; not every retirement is announced there with a table of ids. + - **The deprecations page** (`docs.cloud.google.com/vertex-ai/generative-ai/docs/deprecations`): SDK modules and features, not model dates. + - **The Gemini API deprecations page** (`google/gemini-models`): the Gemini API's own dates, which differ. +- **Quote:** "| `veo-3.0-generate-001` | July 29, 2025 | June 30, 2026 | `veo-3.1-generate-001` |" (Retired models). + +## How the provider announces changes + +- A GA model is kept for at least a year, written as a minimum ("October 13, 2027 or later", "No sooner than May 20, 2028"); when Google decides to retire it, the cell becomes a plain date, and the model later moves to "Retired models". + +## What the plugin reads and ignores + +- Reads every table with a "Retirement date", a "Model ID" and a "Replacement model ID" (or "Recommended upgrade") column: one `breaking` `model` event per model id with a plain date, `version` the date. `replacement` is set when the cell names exactly one model. +- Ignores a minimum lifetime ("… or later", "No sooner than …", "No retirement date announced"): it isn't a retirement notice. The pinned drop test: the Gemini image models' table, four rows with such dates and one dated retirement, gives one event. +- Ignores a cell that isn't a plain model id ("textembedding-gecko@003 *", with a footnote mark). + +## Known gaps + +- The page is about 430 KB of HTML; only its headings and tables are read, so a date given only in prose beside a table is missed. +- Partner models (Claude, Llama…) on Vertex AI are on other pages. diff --git a/providers/newrelic.md b/providers/newrelic.md index 9e87fc3..a014f70 100644 --- a/providers/newrelic.md +++ b/providers/newrelic.md @@ -2,13 +2,13 @@ ## What it watches -Functions and classes removed from New Relic's Python agent (the `newrelic` package) in 11.0.0: `newrelic.agent.record_exception`, `newrelic.agent.add_custom_parameter`, `newrelic.api.log.NewRelicLogHandler`, and others. Code that uses one breaks on the upgrade. The plugin emits one event per member, pinned to that release. +Functions and classes a new major of New Relic's Python agent (the `newrelic` package) removes, from the major's release notes: in 11.0.0, `newrelic.agent.record_exception`, `newrelic.agent.add_custom_parameter`, `newrelic.api.log.NewRelicLogHandler`, and others. Code that uses one breaks on the upgrade. One event per member, with the major's first release as `version` and the release before it on PyPI as `previous_version`. The releases are listed from PyPI (yanked ones included: 11.0.0 is yanked); nothing in the code names a release or a commit. Kind: `migrationguide` (`plugins/migrationguide`), with the removed-members reader (`plugins/migrationguide/members`), reading a Markdown table. ## Why this source -- **Source:** [`python-agent-110000.mdx`](https://github.com/newrelic/docs-website/blob/f0b4f817bf9a7b76a78e26609369a8a7ce764c8e/src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx) in newrelic/docs-website at commit `f0b4f817bf9a7b76a78e26609369a8a7ce764c8e` (2026-04-22, the file's latest commit). The plugin reads the raw file at that commit, because the repo has no tags. Checked on 2026-11-19. © New Relic, CC BY-NC-SA 4.0. +- **Source:** `python-agent-0000.mdx` in newrelic/docs-website (9.0.0 to 13.0.0 are there, checked 2026-11-20), for each major's first release. The repo has no tags, so the plugin asks GitHub for the newest commit that changed the note and reads the raw file at that commit. 11.0.0's, [`python-agent-110000.mdx`](https://github.com/newrelic/docs-website/blob/f0b4f817bf9a7b76a78e26609369a8a7ce764c8e/src/content/docs/release-notes/agent-release-notes/python-release-notes/python-agent-110000.mdx) at commit `f0b4f817` (2026-04-22), is the one checked on 2026-11-19. A note with no "Removed features" section, or no note, has nothing to read (the pair is skipped). © New Relic, CC BY-NC-SA 4.0. - **Why this one:** these are New Relic's own release notes for the agent's 11.0.0. Their "Removed features" section has a table of the APIs that 11.0.0 removed, with what to use instead. A commit never changes, so the URL is its own citation. 11.0.0 is a version a repo pins. - **Alternatives considered:** - **The REST API v2 spec**, (OpenAPI 3.0.1, 58 operations on 43 paths, fetched 2026-11-19). New Relic serves it only live and doesn't commit it anywhere, so there's no release to pin or replay. Its deprecations aren't machine-readable: it has 0 `deprecated: true` flags. Instead, 12 operation descriptions say "This endpoint will be deprecated after", 11 of them "2024/01" and 1 "2027/01". New Relic's own end-of-life notice for REST API v2 (below) contradicts those dates for 10 of the 12: it retires them on 2027-07-31. It keeps the other 2, on `/alerts_location_failure_conditions/policies/*`, as "Not impacted". @@ -51,4 +51,6 @@ Kind: `migrationguide` (`plugins/migrationguide`), with the removed-members read - **The same functions reached another way** get no event: the `newrelic.api.transaction` and `newrelic.api.time_trace` definitions, and the methods of the same names on `Transaction` (`add_custom_parameter`, `record_exception`…). All were removed in 11.0.0 too. - **The removed settings** (`ssl`, `error_collector.ignore_errors`, `strip_exception_messages.whitelist`…). They're configuration, not code, and change events have no subject for them. - New Relic's REST API v2 end of life (2027-07-31) and NerdGraph (see above). -- New Relic's other agents, and later majors of the Python agent: each is a new entry in this plugin. +- New Relic's other agents. +- Removals in a minor release: only a major's note is read. +- A later major's table is read with 11.0.0's `Paths` and `DropIns`: a name not in them is written as the table writes it, and only a listed drop-in is a rename. diff --git a/providers/numpy.md b/providers/numpy.md index 32357a6..b16e8d9 100644 --- a/providers/numpy.md +++ b/providers/numpy.md @@ -2,13 +2,13 @@ ## What it watches -Members removed from or renamed in NumPy's main namespace in 2.0.0 (`np.float_`, `np.NaN`, `np.product` and about fifty more): code using one raises `AttributeError`. One event per member. Pinned to that release. +Members a new major removes from or renames in NumPy's main namespace, from that major's migration guide: in 2.0.0, `np.float_`, `np.NaN`, `np.product` and about fifty more (code using one raises `AttributeError`). One event per member, with the major's first release as `version` and the release before it on PyPI as `previous_version`. The releases are listed from PyPI; the guide is read at each major's first tag (`v.0.0`), so nothing in the code names a release. Kind: `migrationguide` (`plugins/migrationguide`), with the removed-members reader (`plugins/migrationguide/members`). ## Why this source -- **Source:** [`doc/source/numpy_2_0_migration_guide.rst` at v2.0.0](https://github.com/numpy/numpy/blob/v2.0.0/doc/source/numpy_2_0_migration_guide.rst), read raw at the tag. Checked on 2026-11-04. +- **Source:** `doc/source/numpy__0_migration_guide.rst` at tag `v.0.0`, read raw at the tag; the one so far is [2.0's](https://github.com/numpy/numpy/blob/v2.0.0/doc/source/numpy_2_0_migration_guide.rst). A major with no guide at its tag has nothing to read (the pair is skipped). Releases from [PyPI](https://pypi.org/project/numpy/). Checked on 2026-11-04 (2.0) and 2026-11-20 (no other guide yet). - **Why this one:** it's NumPy's own migration guide, with a table of every removed member and its migration guideline. A tag never changes, so the URL is its own citation. - **Alternatives considered:** the 2.0.0 release notes (list the removals in prose, spread over several sections); the rendered guide on numpy.org (the same text as HTML); NEP 52 (the plan, not what shipped). - **Quote:** "The table below provides replacements for the removed members:" (Main namespace), with rows such as "NaN — Use ``np.nan`` instead." @@ -27,4 +27,5 @@ Kind: `migrationguide` (`plugins/migrationguide`), with the removed-members read ## Known gaps - The guide's other tables (`np.lib` members, changed behavior) aren't read. -- Later releases' removals aren't watched. +- Removals in a minor release aren't watched: only a major gets a guide. +- A later major's guide is read with 2.0's rule: a guideline that is exactly "Use ``np.`` instead." is a rename. NumPy 2.0's guide says each such replacement works on 1.x; a later guide might name one that's new, which would make the rename fail on the release before. diff --git a/providers/posthog.md b/providers/posthog.md index 917620c..9e6fc84 100644 --- a/providers/posthog.md +++ b/providers/posthog.md @@ -2,13 +2,13 @@ ## What it watches -Members removed from the `posthog` Python SDK in 8.0.0 (`CaptureMode`, `posthog.capture_v1`, `posthog.capture_v1.CaptureV1Error`, `posthog.request.batch_post`…): code using one breaks on the upgrade. One event per member. Pinned to that release. +Members a new major of the `posthog` Python SDK removes, from that major's migration guide: in 8.0.0, `CaptureMode`, `posthog.capture_v1`, `posthog.capture_v1.CaptureV1Error`, `posthog.request.batch_post`… (code using one breaks on the upgrade). One event per member, with the major's first release as `version` and the release before it on PyPI as `previous_version`. The releases are listed from PyPI; the guide is read at each major's first tag, so nothing in the code names a release. Kind: `migrationguide` (`plugins/migrationguide`), with the removed-members reader (`plugins/migrationguide/members`), reading a Markdown table. ## Why this source -- **Source:** [`docs/migration-7.x-to-8.0.md` at posthog-v8.0.0](https://github.com/PostHog/posthog-python/blob/posthog-v8.0.0/docs/migration-7.x-to-8.0.md) (commit `6edff41425188056e48f6119457dc9bc0669ca99`), read raw at the tag. Checked on 2026-11-19. The guide isn't in the repo at posthog-v7.91.4, the release before, and is the same at posthog-v8.0.2. MIT. +- **Source:** `docs/migration-.x-to-.0.md` at tag `posthog-v.0.0`, read raw at the tag; the one so far is [`docs/migration-7.x-to-8.0.md` at posthog-v8.0.0](https://github.com/PostHog/posthog-python/blob/posthog-v8.0.0/docs/migration-7.x-to-8.0.md) (commit `6edff41425188056e48f6119457dc9bc0669ca99`). A major with no guide at its tag has nothing to read (the pair is skipped). Releases from [PyPI](https://pypi.org/project/posthog/). Checked on 2026-11-19. The guide isn't in the repo at posthog-v7.91.4, the release before, and is the same at posthog-v8.0.2. MIT. - **Why this one:** it's PostHog's own migration guide for the SDK's 8.0.0, and its "Fix removed APIs" section is a table of what 8.0.0 removed and what to use instead. A tag never changes, so the URL is its own citation, and 8.0.0 is a version a repo pins. - **Alternatives considered:** - **`references/public_api_snapshot.txt`** in the same repo: a generated listing of the public API at every tag. Diffing it between two releases gives every removed name with its full path, but no reason, replacement or announcement. The plugin reads the guide, and the listing was used to check the paths of the guide's names. diff --git a/providers/redis.md b/providers/redis.md index fb28c52..a954ff1 100644 --- a/providers/redis.md +++ b/providers/redis.md @@ -2,35 +2,36 @@ ## What it watches -Redis's command surface: commands that disappear entirely from `redis-doc`'s own catalog of every command, between two snapshots of it. +Redis's command surface: commands that disappear entirely between two Redis releases, read from the command definitions in the server's own source (`src/commands/`, one JSON file per command) at each release tag. -Kind: `catalog` (`plugins/catalog`), new in this change — no existing format plugin reads a flat JSON catalog keyed by name; see "Alternatives considered" for the formats checked and ruled out first. +Kind: `catalog` (`plugins/catalog`), the `Commands` reader (`plugins/catalog/redis.go`). ## Why this source -- **Source:** `commands.json` in [redis/redis-doc](https://github.com/redis/redis-doc), fetched at a commit (`https://raw.githubusercontent.com/redis/redis-doc//commands.json`); the newest commit from `GET https://api.github.com/repos/redis/redis-doc/commits/master`. Checked on 2026-11-18. -- **Why this one:** it's the real, machine-readable file redis.io's own command reference is generated from, one JSON object per command (370 of them as checked), each with the metadata (arity, flags, ACL categories, and for a few, `deprecated_since` / `replaced_by`) that drives the docs site. `redis-doc` has no tags, so a commit SHA stands in for a release; that SHA is still a permanent, immutable citation, the same property a tag gives elsewhere. +- **Source:** [`src/commands/`](https://github.com/redis/redis/tree/unstable/src/commands) in redis/redis, read at each final release's tag (`X.Y.Z`, listed from [GitHub releases](https://github.com/redis/redis/releases) and ordered by version). A release is one listing (`GET https://api.github.com/repos/redis/redis/contents/src/commands?ref=`); a file that is gone at the next release is fetched once, at the older tag (`https://raw.githubusercontent.com/redis/redis//src/commands/`), for the command's name and the entry quoted as evidence. Checked on 2026-11-20: 460 files at 8.10.0, the directory there from 7.0.0. +- **Why this one:** it is what the server is built from: `commands.def`, the server's command table, is generated from these files, and so is redis.io's command reference. A release tag maps an event to the server version a team runs, and a tag never changes, so the file's URL is its own citation. - **Alternatives considered:** - - **An OpenAPI spec.** Redis the database has none: it's a binary protocol, not a REST API. (Redis Cloud, the separate hosted-management product, does publish a REST API, but only behind a live Swagger UI at `api.redislabs.com`, not an official, git-pinned spec repo — no stable tag to diff between releases the way Stripe's or GitHub's are.) - - **The official client libraries' changelogs** (`redis-py`'s `CHANGES`, `node-redis`'s `CHANGELOG.md`): both exist, but both stopped being updated once each project moved past its early releases — `CHANGES` says outright "this file contains only the changes history before redis-py version 4.0.0 ... after ... all changes can be found in the Release notes published in GitHub"; `node-redis`'s file stops at v4.0.2 (Jan 2022) while the package itself is past v6. Checked their actual bullets against `plugins/changelog`'s classifier (which needs a plain "Removed `X`" sentence with a backtick'd name): across every version heading in both files, none matched — the prose names JS/Python arguments and config options, not Redis commands, and rarely in backticks. - - **Redis's own deprecations/sunset prose** (`docs.github.com`-style breaking-changes page): Redis has no equivalent single page; deprecation notes live per-command, in the catalog itself (see below). - - **An RSS/Atom feed:** none found for Redis's own release notes; `redis/redis`'s GitHub Releases has an Atom feed (`/releases.atom`), but its entries are prose changelogs with the same shape problem as the client libraries above, not a vendor-labelled "breaking" category the way `feed`'s existing readers (GitHub Actions, Vertex AI) depend on. -- **Quote:** `"FUNCTION INFO"` is in the catalog at commit `cc0427b`; by the very next commit touching the file, it and `FUNCTION CREATE` are gone, replaced by `FUNCTION LOAD` ([PR #1697](https://github.com/redis/redis-doc/pull/1697)). + - **`redis/redis-doc` `commands.json`** (what this source read before, until 2026-11-20): the repo is archived, the file last changed on 2023-10-24, 370 commands, so nothing from Redis 7.4 or 8.x was ever seen. + - **`redis/docs` `data/commands.json`** (redis.io's maintained docs repo, 678 commands on 2026-11-20): one file, but a docs artifact. Its history (5 commits since 2024-02) shows editorial churn that would read as removals: commit `2f513f2` (2024-06-06) dropped 126 module commands (`BF.*`, `CF.*`, `FT.*`…) that Redis never removed, and later commits put them back; commit `9740114` (2026-07-30) deleted the file outright. Its versions are commit dates, not server releases. Every one of those would be a false event, so it isn't read. + - **An OpenAPI spec.** Redis the database has none: it's a binary protocol, not a REST API. + - **The client libraries' changelogs** (`redis-py`'s `CHANGES`, `node-redis`'s `CHANGELOG.md`): both stopped being updated years ago, and their bullets name client arguments, not server commands. +- **Quote:** at tag `8.8-m03`, `src/commands/gcra.json` is `{"GCRA": {"summary": "Rate limit via GCRA (Generic Cell Rate Algorithm).", … "since": "8.8.0", …}}`; at `8.8-rc1` the file is gone, and so is `gcrasetvalue.json`. ## How the provider announces changes -- **No API version at all**: Redis is versioned by server release (`7.0.0`, `8.2.0`...), with no header, path or date scheme the way Stripe or GitHub have. A client picks a server to connect to; there is no "pin an API version" concept to gate against. -- **Commands are deprecated, essentially never removed.** Of the 370 commands in the live catalog, 21 carry `deprecated_since` (e.g. `HMSET` since 4.0.0, replaced by `HSET`); every one of them still works. Checked directly against the real source of truth, [redis/redis](https://github.com/redis/redis)'s own `src/commands/*.json`: diffing the full command file list between the `7.0.0` and `8.2.0` GA tags removed **zero** files. Redis's own backward-compatibility stance means a shipped command keeps working forever. -- **The one real removal found, `FUNCTION CREATE` / `FUNCTION INFO`, never shipped.** They existed only in `redis-doc`'s catalog during the pre-release design of the Functions feature; `src/commands/function-create.json` doesn't exist even at `7.0-rc1`, the first public release candidate, tagged a week *after* the catalog commit that dropped them. So this is a real, verifiable removal in the repo's history, but not one any real user's code could have depended on — unlike Stripe's, Datadog's or GitHub's demo changes, which all broke a real, shipped version. Recorded here rather than smoothed over: Redis's command surface, at least since 7.0 GA, has had no breaking removal to replay instead. +- **No API version**: Redis is versioned by server release (`7.4.0`, `8.10.0`). Several lines are patched at once (7.2.10 shipped after 8.0.0), which is why versions are ordered by number, not by date: a pair across lines would read the older line's missing commands as removals. +- **Commands are deprecated, essentially never removed.** Between every final release from 7.0.0 to 8.10.3, no command file was removed (checked 2026-11-20 across the tags); about twenty commands carry `deprecated_since` and still work. The one removal in that span is between pre-release tags: GCRA and GCRASETVALUE, added in the 8.8 milestone builds, gone at 8.8-rc1. The golden test pins that pair. ## What the plugin reads and ignores -- Reads: `commands.json` at the newest commit, compared with the commit read before it. A name present before and missing after becomes a `breaking` `package_release` event (`change: removed_symbol`); the excerpt quotes the entry's own JSON from the snapshot where it still existed. -- Ignores: everything else about a command (arguments, flags, complexity, ACL categories) — only presence is diffed. A name that's only *added* is not an event. A rename is read as one removal, since nothing in the catalog says a disappearance and an appearance are the same command; guessing that would trade precision for recall. -- The live `deprecated_since` / `replaced_by` fields on still-present commands aren't read yet (see "Known gaps"): they're deprecations, not removals, and every one of them already works forever regardless. -- Reads a historical pair (a version pair, commit `cc0427b` → `06f3598`) and recreates the real removal of `FUNCTION CREATE` and `FUNCTION INFO` (the golden test uses trimmed excerpts of both commits' `commands.json`, alongside `GET`, unchanged, as the drop-test fixture). +- Reads: the list of `*.json` files in `src/commands/` at each release. A file in the older release's list and not in the newer's becomes a `breaking` `package_release` event (`change: removed_symbol`), its symbol the command's name (a subcommand with its container: `CLIENT KILL`), its version the newer release and its `previous_version` the older. The excerpt quotes the file at the older tag. +- Ignores: what a command's file says (arguments, flags, complexity, ACL categories): only presence is compared. An added command is not an event. A file renamed with the same command in it would read as a removal; none was renamed in the span checked. +- A release from before 7.0.0 has no `src/commands/`: nothing to read (the pair is skipped). +- Pre-release tags (`-rc`, `-m`) aren't listed: they aren't releases a team runs. +- The pinned drop test: 8.8.0 → 8.10.0 adds 17 command files and removes none, so no event. ## Known gaps -- The 21 commands already marked `deprecated_since` in the live catalog aren't turned into `deprecation` events: there's no second snapshot showing the moment each one was marked that way conveniently paired with a trimmed fixture, and since none of them is ever actually removed, the user-facing urgency is low. A future change could diff for a command gaining `deprecated_since` between two snapshots the same way this one diffs for removal. -- `node-redis` and `redis-py`'s own breaking changes (argument shapes, defaults, RESP3 becoming the default response protocol) aren't watched: real breaking changes exist in both (checked: `node-redis` v4.0.0's "Breaking Changes" section, `redis-py` v8.0.0's RESP2/RESP3 unification), but neither client writes them as the plain, single-symbol sentences `plugins/changelog` already reads elsewhere. A client-library plugin for Redis would need its own, looser reader, not this one. +- Commands gaining `deprecated_since` between two releases aren't turned into `deprecation` events yet: that needs the changed files' contents, not only the list. +- Module commands (`FT.*`, `JSON.*`, `TS.*`…) live in the modules' own repos, not in `src/commands/`. +- `node-redis` and `redis-py`'s own breaking changes aren't watched here: they're client SDKs, a separate source. diff --git a/providers/salesforce.md b/providers/salesforce.md index 2edf69d..7103ea0 100644 --- a/providers/salesforce.md +++ b/providers/salesforce.md @@ -8,12 +8,13 @@ Kind: `notices` (`plugins/notices`), with the end-of-life reader (`plugins/notic ## Why this source -- **Source:** [API End-of-Life Policy](https://developer.salesforce.com/docs/platform/api-rest/guide/api-rest-eol.html), Salesforce's own table of REST API version ranges and their support status. Checked 2026-11-20: a plain GET of the live page gets a 403 every time, including with a browser `User-Agent`, so `env.Get` always fails here. The Wayback Machine's own save-page-now request succeeds against the same URL anyway (checked the same day), so this plugin falls back to a fresh snapshot when the direct read is blocked, and reads and cites that snapshot directly: unlike `retirements` and `feed`, which read the live page first and only snapshot it afterward to cite, there's no live read here to cite alongside. +- **Source:** [API End-of-Life Policy](https://developer.salesforce.com/docs/platform/api-rest/guide/api-rest-eol.html), Salesforce's own table of REST API version ranges and their support status. Checked 2026-11-20: a plain GET of the live page gets a 403 every time, including with a browser `User-Agent`; on 2026-11-21 its CDN (`server: AkamaiNetStorage`) answered 503 instead, after the fetch layer's retries. So `env.Get` always fails here. The Wayback Machine's own crawler reads the same URL anyway (its capture of 2026-11-20 parses to the same findings), so this plugin falls back to a fresh snapshot when the direct read is blocked (401, 403, or 503), and reads and cites that snapshot directly: unlike `retirements` and `feed`, which read the live page first and only snapshot it afterward to cite, there's no live read here to cite alongside. **A read that can't be made is a failed run, never "nothing changed":** any other status (404, 429, 500…), a snapshot the archive can't take, or a snapshot with no table in it (a block page saved in its place) fails the read, and patch-it's hosted ingestion service records the error. - **Why this one:** it's the only place Salesforce states, in one page, which whole version ranges still work, which are scheduled to stop, and which already have. Salesforce's own policy text above the table: "Salesforce is committed to supporting each API version for a minimum of 3 years from the date of first release... Salesforce notifies customers who use an API version scheduled for deprecation at least 1 year before support for the version ends." - **Alternatives considered:** - **A changelog or RSS/Atom feed.** None found. Salesforce Help's release notes (HTML and PDF, three times a year: Spring, Summer, Winter) cover new features and, inconsistently, "Critical Updates" with their own auto-activation dates, but as prose spread across hundreds of pages per release, not a page or feed keyed by what changed in the API. No official feed of any of this exists. - **An OpenAPI spec.** Salesforce publishes no stable, versioned one. There's a beta, on-demand generator (`POST .../async/specifications/oas3`) for the sObjects REST API only, explicitly "subject to change... Don't build production integrations based on this," generated live per org and not pinned to a release, so there's nothing to diff between two points in time. - **Official Python and JS/TS SDKs for the REST API.** Checked 2026-11-20: Salesforce publishes none. `simple-salesforce` (PyPI) and `jsforce` (npm) are the community-maintained libraries almost everyone actually uses, but they're not Salesforce's own, so a breaking change in either is about the library, not the API; left for a future, separate client-library plugin if either becomes worth watching on its own. Salesforce does maintain its own SDKs for other surfaces (the `sf` CLI, Lightning Web Components), just not a general REST/SOAP API client. + - **The docs site's JSON content API** (`https://developer.salesforce.com/docs/get_document_content/api_rest/api_rest_eol.htm/en-us/`, the older "atlas" REST API Developer Guide; `get_document/atlas.en-us.api_rest.meta` names the newest doc version). It answers a plain GET (checked 2026-11-21), but it lags the live page: its newest version, 262.0 (Summer '26), lists versions 31.0 through 66.0 as supported and has no row for the 31.0–40.0 deprecation the live page announces, so it would miss exactly what this source is for. - **The retirement-detail sub-pages** the main table links to (e.g. "Salesforce Platform API Versions 31.0 through 40.0 Retirement"), each its own Salesforce Help article. The main page already states the same range, status and season; reading only it keeps one source of truth and one snapshot per run. - **Quote:** "As of Summer ’25, these versions are retired and unavailable." (versions 21.0 through 30.0, a real, already-happened retirement)