Repository navigation
fix(markers): let marker plugins opt out of contributions - #1785
Conversation
The plugin gRPC service carries submit methods whether or not a marker provider accepts submissions, so every plugin provider implemented Submitter and fetch-only providers received contribution jobs and were offered contribution settings. A capability can now declare supports_contribution=false in its metadata; reload wraps it in a fetch-only provider that forwards ID, CacheRevision, description and FetchMarkers only. Manifests without the key keep today's behaviour. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Silo Kody — review completeReview finished. Check the inline comments for findings and verify each suggestion against the code and tests. Reviewing changes in Silo
Review settingsReview OptionsThe following review options are enabled or disabled:
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
|
Automated check: Macroscope check run agent (gpt-6-luna). No validation was performed. Posted via Macroscope — v1 validation impact |
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Silo Kody — review completeReview finished. Check the inline comments for findings and verify each suggestion against the code and tests. Reviewing changes in Silo
Review settingsReview OptionsThe following review options are enabled or disabled:
|
|
Thanks, updated the description to |
|
Silo's pull request guidance changed today (#2016). A PR that changes what a user sees now needs before-and-after evidence in its Evidence section, and a PR with no visible change says Missing here: Before-and-after screenshots of the admin marker provider settings for a fetch-only plugin showing the contribution controls gone, or, if nothing changes until a plugin opts in, the line 'Evidence: none, no user-visible change' with that reason. The rules are in Show visible changes, and the PR template shows the Evidence section layout. I've converted this PR to draft for now. Mark it ready for review once the Evidence section is filled in. Generated by Claude Code |
|
This change is visible in Admin → Providers: for a plugin that opts out, the marker settings disable the sharing controls and omit “Test connection” and submission stats. The Evidence section says there is no user-visible change, so it lacks evidence for this opt-in case. Please add before-and-after screenshots of the same marker-provider settings screen and data, and identify the surface and build or commit for each capture. Automated check: Macroscope check run agent (gpt-6-luna). Evidence was not reviewed for correctness. Posted via Macroscope — Visible change evidence |
|
The Evidence section covers this now. No marker plugin sets |
Quick104
left a comment
There was a problem hiding this comment.
Review of 8ddb552. Two findings are inline. I'm fixing both on this branch, and a summary comment will follow.
The approach holds up. Before this change every registered marker provider is a PluginProvider, so every one is a Submitter. Each place that asks whether a provider takes contributions uses that type assertion: contribution dispatch, SubmissionRequirementProvider, the admin is_submitter flag, and validate. Wrapping at registration makes all of them follow the manifest. The wrapper forwards everything callers assert on current main (DescribedProvider, CacheRevision), and the branch merges cleanly with main. TestReloadMarkerPluginProvidersHonorsSupportsContribution fails on the base for the expected reason and passes on this head.
A provider keeps its saved sharing flags after a plugin update declares supports_contribution=false. The share task picked providers from those flags alone, so it rescanned every candidate file each night without submitting anything. It now skips providers the registry doesn't hold as submitters, and the admin tile shows sharing as off for them. Trim the new tests to what the reload test doesn't already cover. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Review summaryReviewed head: a7aa296 (originally 8ddb552) The approach is right. Before this change every marker plugin registered as a Addressed on this branch
Tests that failed on the base
Focused Go tests for Left for maintainers
Validated featuresNo passed validation case is reached. The PR only changes behavior for a plugin that opts out, and none does yet. Other checks
Cross-provider reviewCodex (gpt-6.1-sol) reviewed 8ddb552 independently. It confirmed the share-task finding, and it raised the multi-replica timing noted above. Fit: 8/10 · Readiness: 9/10 — conditional (assuming CI is green)
|
Silo Kody — review completeReview finished. Check the inline comments for findings and verify each suggestion against the code and tests. Reviewing changes in Silo
Review settingsReview OptionsThe following review options are enabled or disabled:
|
|
The latest Automated check: Macroscope check run agent (gpt-6-luna). Evidence was not reviewed for correctness. Posted via Macroscope — Visible change evidence |
contribute.go: this branch imports regexp and main (Silo-Server#3000) imports math; keep both. Main (Silo-Server#1785, Silo-Server#2689) dropped the task's config argument: the providers that contribute automatically now come from the runner's AutoContributors. This branch's three tests set up a provider through the removed fakeAutoConfig; they now set the fake runner's auto contributors instead and call the three-argument constructor. What they check is unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Problem
Related issue: N/A. Split out of #792.
Validation tasks: none
A marker plugin that only reads markers, such as a public or anonymous provider, is still treated as a contributor. The plugin gRPC service has submit methods whether or not the provider accepts submissions, so every plugin provider implements
markers.Submitter. Contribution then sends it submission jobs, and the admin API offers it contribution settings and user stats it can't support.This change lets a marker capability declare
supports_contribution: falsein its capability metadata. Silo then registers it as fetch-only.Approach
supports_contribution: falseis wrapped inmarkers.ReadOnlyPluginProvider. The wrapper forwardsID,CacheRevision,ProviderDescriptionandFetchMarkersand nothing else, so the existingSubmitterassertions in contribution and the admin API follow the manifest.CacheRevisionhas to be forwarded. Population keys its cache on it, and reload compares it to decide whether to refresh the plugin runtime.The flag sits next to
default_fetch_priorityandrequired_external_idsin the capability'smetadataobject. Plugin authors will need it documented with those keys in the plugin SDK docs. I haven't changed the SDK in this PR.Validation
go test ./internal/markers/ ./cmd/silo/ -count=1andgo test ./internal/api/handlers/ -run Marker -count=1pass.go vet ./cmd/silo ./internal/markersis clean.SubmissionRequirementProviderand forwardingCacheRevision, a reload with a fetch-only manifest registering a non-submitter, and the share task skipping a fetch-only provider with saved sharing flags. The reload test and the share-task row both fail on code without their fix.mainby a merge commit.Benchmarks
Not applicable. This changes which interface a provider is registered behind.
Evidence
Evidence: none, no user-visible change. No marker plugin sets
supports_contribution: falseyet, so every existing install keeps today's settings screen. The contribution controls only change once a plugin opts in, and there's no fetch-only plugin to capture that against yet.Risks
None identified. The key is opt-in and additive. A plugin that sets it loses the contribution UI and jobs, which is the intent.
Checklist
AI Disclosure
mainstill needs. Claude Opus checked each fix(playback): refresh incomplete skip markers #792 concern against currentmain, ported this one, and wrote and ran the tests.main's provider assertions (Submitter,SubmissionRequirementProvider,DescribedProvider,CacheRevision) to confirm the wrapper hides only the submit surface. That check addedCacheRevisionforwarding, which the original fix(playback): refresh incomplete skip markers #792 version lacked.Note
Let marker plugins opt out of contributions via
supports_contributionmetadatamarkers.ReadOnlyPluginProvider, a fetch-only wrapper that hides submission methods. Providers registered inreloadMarkerPluginProvidersuse this wrapper when the plugin's capability metadata setssupports_contributionto false; absent, unsupported, or unparseable values default to true for compatibility (plugin_provider.go).markers.ContributionService.AcceptsContributions, which reports whether a provider ID has Submitter support.tasks.ContributeMarkersTask.Executenow skips providers that do not accept contributions, even if their saved auto-contribution flags are still enabled (contribute.go, contribute_markers.go).supports_contribution: falseno longer satisfy theSubmitterinterface, so their saved contribution settings are ignored during automatic marker contribution.Macroscope summarized a7aa296.