Skip to content
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

fix(plugin-compat): update fsevents patch for version 2.2.0 #2078

Merged
merged 2 commits into from
Nov 4, 2020

Conversation

merceyz
Copy link
Member

@merceyz merceyz commented Nov 3, 2020

What's the problem this PR addresses?

fsevents released version 2.2.0 and the patch is no longer compatible
fsevents/fsevents@2.1.3...v2.2.0

Fixes #2077
Fixes #719 (comment)
Fixes https://github.com/yarnpkg/berry/runs/1348595951?check_suite_focus=true#step:6:112

How did you fix it?

Updated the patch

Checklist

  • I have read the Contributing Guide.
  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

@merceyz
Copy link
Member Author

merceyz commented Nov 3, 2020

@Kizmar @milichev if you want this fix before it's released you can run yarn set version from sources --branch 2078 or grab the bundle from the CI once it finishes https://github.com/yarnpkg/berry/actions/runs/344176832

@Kizmar
Copy link

Kizmar commented Nov 3, 2020

For the record; that branch does work when I yarn install. Thank you for tackling this so quickly.

@Sun-2
Copy link

Sun-2 commented Nov 7, 2020

@Kizmar @milichev if you want this fix before it's released you can run yarn set version from sources --branch 2078 or grab the bundle from the CI once it finishes https://github.com/yarnpkg/berry/actions/runs/344176832

Throws with

Unrecognized or legacy configuration settings found: changesetIgnorePatterns - run "yarn config -v" to see the list of settings supported in Yarn (in /tmp/yarnpkg-sources/d0a670/.yarnrc.yml)
cat ~/.yarnrc.yml
yarnPath: ".yarn/releases/yarn-berry.cjs"
cat /tmp/yarnpkg-sources/d0a670/.yarnrc.yml
changesetIgnorePatterns:
  - "**/*.test.{js,ts}"

enableGlobalCache: false

immutablePatterns:
  - .pnp.*

initScope: yarnpkg

npmPublishAccess: public

packageExtensions:
  "@emotion/babel-preset-css-prop@*":
    peerDependencies:
      "@babel/core": "*"
  "@gatsbyjs/relay-compiler@2.0.0-printer-fix.2":
    peerDependencies:
      "@babel/core": "*"
  "@webpack-cli/package-utils@*":
    dependencies:
      cross-spawn: "*"
  gatsby-cli@*:
    peerDependencies:
      eslint: "*"
      gatsby: "*"
      react: "*"
      webpack: "*"
  gatsby-plugin-emotion@*:
    peerDependencies:
      "@babel/core": "*"
  gatsby-plugin-favicon@*:
    peerDependencies:
      webpack: "*"
  gatsby-plugin-sharp@*:
    dependencies:
      debug: "*"
  gatsby-react-router-scroll@*:
    dependencies:
      prop-types: "*"
  gatsby-recipes@*:
    peerDependencies:
      eslint: "*"
      gatsby: "*"
      ink: "*"
      react: "*"
      webpack: "*"
  gatsby-remark-prismjs@*:
    dependencies:
      lodash: "*"
  gatsby@*:
    peerDependencies:
      "@babel/core": "*"
  monaco-editor-webpack-plugin@*:
    dependencies:
      webpack: ^4.5.0
  react-instantsearch-core@*:
    peerDependenciesMeta:
      algoliasearch:
        optional: true
  react-instantsearch-dom@*:
    dependencies:
      react-fast-compare: "*"
  typedoc@*:
    peerDependenciesMeta:
      "@strictsoftware/typedoc-plugin-monorepo":
        optional: true
      typedoc-neo-theme:
        optional: true
      typedoc-plugin-yarn:
        optional: true

preferInteractive: true

telemetryUserId: yarnpkg/berry

yarnPath: scripts/run-yarn.js

@merceyz
Copy link
Member Author

merceyz commented Nov 7, 2020

Your Yarn version seems to be old enough to be unable to parse the newer configs we have in the repo, you can grab the bundle from the link I provided instead

@Sun-2
Copy link

Sun-2 commented Nov 7, 2020

@merceyz

I had the latest version of classic. However by the virtue of yarnPath, Berry from ~/.yarn was used instead. (It seems to be the standard installation method of Yarn 2.)

Are you sure it's because of the version?

@merceyz
Copy link
Member Author

merceyz commented Nov 7, 2020

I had the latest version of classic.

It's the v2 version you have that I was talking about.

However by the virtue of yarnPath, Berry from ~/.yarn was used instead. (It seems to be the standard installation method of Yarn 2.)

We document installing on a per-project basis https://yarnpkg.com/getting-started/install#per-project-install

Are you sure it's because of the version?

Just a guess as older versions loaded the config file in strict mode which throws on unknown values

@DannyHinshaw
Copy link

Any ideas on when we can see this fix in a release?

@merceyz
Copy link
Member Author

merceyz commented Nov 16, 2020

Next release should be sometime this month, in the meantime you can run yarn set version from sources to get this fix

@DannyHinshaw
Copy link

@merceyz thanks, yea just keepin an eye on it for when we can revert back to latest

@Fernando-Marquardt
Copy link

Next release should be sometime this month, in the meantime you can run yarn set version from sources to get this fix

There is no other way? The version from sources is broken, at least for me, always trowing an error on a JSON.parse from httpUtils when trying to add a new dependency. This version even breaks the set version, with a semver check that forbids going back to berry.

@alubbe
Copy link
Contributor

alubbe commented Nov 19, 2020

I also can't use yarn set version from sources because our typescript CRA app stops working as the type files of our dependencies can not be found after the upgrade (from 2.3.3). A new release would be greatly appreciated 👍

@merceyz
Copy link
Member Author

merceyz commented Nov 19, 2020

@Fernando-Marquardt @alubbe Might be a bug in master, try yarn set version from sources --branch 2078

@Fernando-Marquardt
Copy link

@Fernando-Marquardt @alubbe Might be a bug in master, try yarn set version from sources --branch 2078

Tried that, but got the same error. I will open an issue about this to avoid going fourth in here, but thanks for the help.

@jeanlescure
Copy link

@Fernando-Marquardt I can't find the issue in regards to the set version error

In the meantime @merceyz I tried both yarn set version from sources and yarn set version from sources --branch 2078, either way I got the following error:

error An unexpected error occurred: "Release not found: from".

@merceyz
Copy link
Member Author

merceyz commented Nov 20, 2020

It's a V2 command so you need to already be using berry, try this

yarn set version berry && yarn set version from sources --branch 2078

@jeanlescure
Copy link

@merceyz we have abandoned the idea of using berry for the time being, we'll wait until the relationship between yarn v2, create-react-app, sass, etc is more stable and less "workaroundy", thanks for the reply though

@steveetm

This comment has been minimized.

@AmadoGuerrero
Copy link

Ok guys for the life of me I couldn't get it working, so this is what I did.
First of all, make sure you don't have a .yarnrc or .yarnrc.yml in your main directory.
Then run:
npx create-react-app my-app --template typescript (It'll use yarn 1 to do it, as normal)
cd my-app
yarn set version berry
yarn set version from sources --branch 2078
yarn install

Its the only way I was able to get it to work for some reason.

@evelant

This comment has been minimized.

@arcanis
Copy link
Member

arcanis commented Nov 27, 2020

Just to be clear, I've marked both comments as off-topic since the topic is to add support for 2.2.0 to the fsevents layer, which is now done. Opinions are fine (and can be easily seen by anyone, it's not like I suppressed them), but I want to keep topics focused on this repository - especially within PRs, which are implementation details.

The next release, along with the fix, will be shipped in a few days, I just have one remaining PR to review. Until then, feel free to use the "from sources" command. It's almost exactly what will ship anyway.

@yarnpkg yarnpkg locked as resolved and limited conversation to collaborators Nov 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet