Repository navigation
Conversation
Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: adssib <[email protected]>
|
Claude finished @adssib's task in 1m 38s —— View job
Rules
Bugs
I found nothing else blocking. I checked these:
Verified
Non-blocking
Thanks for the clear "Calls I made" section. It made the precision tradeoffs easy to check. |
| } | ||
| if len(commits) == 0 || commits[0].SHA == "" { | ||
| return "", fmt.Errorf("github lists no commit") | ||
| return "", fmt.Errorf("github lists no commit: %w", plugin.ErrNothingToRead) |
There was a problem hiding this comment.
This changes behaviour for five other sources, not just New Relic. LatestCommit is also called by the OpenAPI adapters for Appwrite, Convex, Neon, PlanetScale and Supabase (plugins/openapi/adapter/{appwrite,convex,neon,planetscale,supabase}.go), and each one wraps the error with %w. So if one of those providers moves or renames its spec, the empty commit list now reaches the runner as ErrNothingToRead. The pair gets skipped quietly, where today it fails and someone notices the broken source.
Suggestion: keep a neutral sentinel here, e.g. var ErrNoCommit = errors.New("github lists no commit"), and turn it into "nothing to read" only in members.Guide.GuideURL, where an empty list really does mean "this major has no note":
sha, err := github.LatestCommit(ctx, env.Get, g.commitsURL(major))
if errors.Is(err, github.ErrNoCommit) {
return "", fmt.Errorf("no %s note for %s: %w", g.Package, v.ID, plugin.ErrNothingToRead)
}As a side effect, core/github would no longer need to import core/plugin.
Closes #179
What this changes
The last releases named in plugin code are gone. The three removed-members guides (NumPy, PostHog, New Relic) were each pinned to one release (
NumPy2at 2.0.0,PostHog8at 8.0.0,NewRelic11at 11.0.0 and a fixed docs commit). Each is now read at every major:X.0.0);numpy_{major}_0_migration_guide.rst,migration-{prev}.x-to-{major}.0.md,python-agent-{major}0000.mdx);plugin.ErrNothingToRead, so the pair is skipped);Untagged), looked up when they're read.Also:
changelog.Textual0860/Urllib3200andsdkguide.AnthropicV1(the golden tests' cases) move into_test.gofiles.cmd/new-plugin) no longer writes a release into a plugin's non-test code.plugins/all's newTestNoPinnedReleaseInPluginCodefails on a release number (X.Y.Z) or a full commit SHA in any string literal of any plugin's non-test code. Comments may still say which release a reader was checked at.core/versions:FirstOfMajor(moved fromsdkguide), andPyPIReleasesWithYanked. New Relic's 11.0.0, the release its note documents, is yanked on PyPI, so a guide lists yanked releases too. The golden stays at 11.0.0, and a pin on 11.0.1 still crosses it.migrationguide.Guide:GuideURL(ctx, env, v) (string, error)(it may look up a commit), andRead(page, sourceURL, from, to, now): the event's version andsource_urlcome from the release read, not the guide's field.Every existing golden is byte-identical.
#179's checklist
ListVersions/ReadAt/Extract(since plugins#225; the members guides now list every release, not one).versions.Compare).TestNoPinnedReleaseInPluginCode).previous_version.github/graphql, add github/graphql: announced GraphQL removals #239).Checklist
WatchesandURLsno longer name a release (I read them)testdata/README.mdlists the two new test files (GitHub commit-list shapes)env.Getmake checkpasses locallyCalls I made (please check)
np.Xinstead." becomes a rename. That held for 2.0, whose guide says each such replacement works on 1.x; a later guide might not. Written down as a known gap inproviders/numpy.md.Paths/DropIns/StillWorkfor later majors. These are keyed by name. A name they don't cover gets the conservative default:removed_symbol, never a rename.Related PRs
🤖 Generated with Claude Code