Repository navigation
fix(eslint-plugin-oracles): remove legacyCampaigns; every raw campaign in an oracle file is reported - #23
Merged
Conversation
… campaign oracle/oracle-property-only no longer exempts files listed in settings.oracles.legacyCampaigns. A configuration that still sets the setting, to any value, gets one removedSetting report at line 1 of each oracle file and exempts nothing. The baselineWithoutReason, staleBaseline, malformedList, malformedEntry, and refusedEntry reports are removed with it. Maintainer decision 2026-11-10: "remove legacyCampaigns, as that's another out for agents". Co-authored-by: Isaac <no-reply@databricks.com>
…t behavior in the changeset The plugin has never been released, so the changeset is a patch and states only what the rule does now, not a removal of a setting no release had. Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
🦋 Changeset detectedLatest commit: e88aa0c The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
commit: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This change removes the
settings.oracles.legacyCampaignssetting from@tanstack/eslint-plugin-oracles.The rule
oracle/oracle-property-onlynow reports every raw campaign in an oracle file. No list can exempt a file.A configuration that still sets
legacyCampaignsgets oneremovedSettingreport at line 1 of each oracle file. The message starts with "legacyCampaignsis removed: convert the listed files tooracleProperty".The rule does not throw on the setting. The rule also does not ignore the setting silently.
Why
The maintainer decision of 2026-11-10 says: "remove legacyCampaigns, as that's another out for agents".
TanStack DB emptied its
legacyCampaignslist in TanStack/db#2408. Thus no file in DB needs the exemption now.Changes
src/registration.jsno longer parses the list. It setslegacyCampaignsSetwhen the configuration gives the setting a value other thanundefined.src/rules/oracle-property-only.jsremoves the entry checks and the exemption. The rule no longer has the messagesbaselineWithoutReason,staleBaseline,malformedList,malformedEntry, andrefusedEntry. The new message isremovedSetting.tests/oracle-property-only-oracle.property.test.jshas a new law and a new model. The model is now short: a set value causes one removal report, and the rule reports each use.Evidence
legacyCampaignssetting with any value causes oneremovedSettingreport at line 1, also in an implementation module. The authority is the maintainer decision of 2026-11-10 and the decision of 2026-11-09 thatoraclePropertyis the only campaign API. The never-throw part comes from frozen principle P8.legacydimension generates three forms. The first is an absent setting (no key, orundefined). The second is a list of any subset of ten entry kinds. The third is one of five values that are not lists. Each of thirteen required states has a constructed history. On the fixed seed 20261109, 17 histories reached "a file that a legacyCampaigns entry names still reports its raw uses". 8 histories reached the empty list. 18 histories reached a value that is not a list. 8 histories reached the implementation module with the setting. 20 histories reached refused or malformed entries.npx vitest --run --maxWorkers=2 tests/oracle-property-only-oracle.property.test.jsfailed both seeds. The shrunk history hadlegacy: { form: "list", entries: [] }, and the expectedremovedSettingreport was missing. A scratch run that compared only reports after line 1 also failed. In that run, a reasoned entry for the file hid therawPropertyreport.pnpm --filter @tanstack/eslint-plugin-oracles test -- --maxWorkers=2passed 19 test files and 4320 tests.pnpm typecheck,pnpm lint:check, andprettier --checkon the changed files also passed.entries: ["reasoned"]because the raw use was not reported. Mutant (b) ignored the setting silently. The oracle failed both seeds on an empty list because the removal report was missing.legacyCampaignsvalue whose read throws, such as a getter or a proxy. The rule still does not follow an aliased campaign, a campaign in a helper, or a re-exported fast-check binding. TanStack DB still reads the setting incheck-legacy-oracle-campaigns.mjsand in the legacy-campaign-baseline oracle. DB must remove them when it updates its pin of this plugin. If DB keeps an emptylegacyCampaignskey, each oracle file gets the removal report.Size
The production change removes a net 90 lines from the rule and the settings parse. It adds no new state or branch other than one report.
Review round
An independent review found no defect in the rule. It found that the first changeset was
minorand announced a removal that no release ever had. The changeset is now apatchthat states only the current behavior.This pull request and its description were written by Isaac.