-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BREAKING CHANGE: eslint-plugin-formatjs - Latest minor release forces upgrade to eslint 9 #4536
Comments
I'm also running into this. It might be as simple as changing the eslint peer dependency, which was previously Dropping 7 and 8 is definitely a breaking change. Based on the commit, f9a0e1b, it looks like it wasn't intentional - cc @michaelfaith |
This change adds support for eslint v9. In order to provide backwards compatibility, I added a `context-compat` module in order to message the `context` object into the appropriate form, depending on the version used. This is mainly only being used for get the `parserServices`, which lives under the `sourceCode` object in v9, but directly on the `context` in earlier versions. Additionally, the `RuleModule` type changed to include an additional generic parameter for pluginDocs. Since the existing rules aren't adding any additional props specific for the plugin, there wasn't a need to create a new type for that. Lastly, v9 is stricter about running exact duplicate tests through the `RuleTester`, and there was one exact duplicate that I removed.
That's actually what I did. I just went back and pulled up the PR and I had it with all three (https://github.com/formatjs/formatjs/pull/4505/files#diff-ee71fcd23af2b6ff9e4ee7d37e0e1978201a7b0e2624ea2e130927136e5d5058). I'm guessing that was changed by one of the maintainers after merging the PR? I was having trouble with getting the BAZEL stuff running locally, so they picked it up and took it the rest of the way, after I got local jest tests green. But also, @heath-freenome is right to say that |
Sorry I'll major bump the packages and mark the recently released version as deprecated. |
It should be relatively easy to include support for 8.57 at least, if you wanted to have some backwards compatability (even if it's still breaking). But then you'd have to major again when v10 comes out and v8 support is dropped... |
Thanks for the suggestion. Nope, with the capacity I have I can only support 1 major |
@longlho Can you also consider releasing a |
FWIW, I pinned our project's dependency to 4.13.x by using @longlho, thanks for maintaining the library, and for your attention to the issue. @michaelfaith, thanks for doing the upgrade and taking the effort to thoughtfully try to make it backwards compatible, even though it didn't end up shipping that way. |
Which package?
eslint-plugin-formatjs
Describe the bug
The recent
4.14.0
is giving me peer dependency issues, saying that it can't find eslint 9. I believe this is due to the internal upgrade to@typescript-eslint
v8 which requires eslint 9.To Reproduce
Codesandbox URL
I tried but could not get it to install eslint 8
Reproducible Steps/Repo
Steps to reproduce the behavior:
npm install eslint@8
npm install eslint-config-formatjs
Expected behavior
Doing a minor upgrade should not force me to use eslint 9, which I cannot do at this point because other dependencies aren't ready to make the shift.
I highly recommend rolling back the change made in
4.14.0
and pushing that into a major version updateThe text was updated successfully, but these errors were encountered: