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

Roll out v2.0.0-0 across main js repos #13

Closed
8 tasks done
kvz opened this issue Oct 25, 2021 · 11 comments
Closed
8 tasks done

Roll out v2.0.0-0 across main js repos #13

kvz opened this issue Oct 25, 2021 · 11 comments
Assignees
Labels
satellite Miscellanous related projects

Comments

@kvz kvz mentioned this issue Oct 25, 2021
Closed
1 task
@lekevbot lekevbot added the satellite Miscellanous related projects label Oct 25, 2021
mifi added a commit to transloadit/node-sdk that referenced this issue Oct 27, 2021
kvz pushed a commit to transloadit/node-sdk that referenced this issue Oct 27, 2021
@kvz
Copy link
Member Author

kvz commented Oct 27, 2021

upgrade workflow that worked for me:

  • git checkout main || git checkout master
  • git pull
  • git checkout -b linting2
  • yarn add -D eslint-config-transloadit@2.0.0-0 eslint-plugin-react-hooks eslint-plugin-promise@^4.3.1 eslint-plugin-import eslint-plugin-node eslint-plugin-prefer-import
  • Remove any reference of react/jsx-one-expression-per-line
  • Remove any reference of no-await-in-loop
  • commit as Upgrade linting to 2.0.0-0
  • DEBUG=eslint:cli-engine ./node_modules/.bin/eslint . --fix --quiet (optionally without --quiet to also see warnings)
  • address any error by fixing code or adding exceptions to .eslintrc.js
  • commit as Fix linting
  • Submit PR Upgrade linting to 2.0.0-0 which Refs: https://github.com/transloadit/eslint-config-transloadit/issues/13 and optionally adds conflict resolve tip.

@kvz
Copy link
Member Author

kvz commented Oct 28, 2021

Question: is there a trick to upgrade the peerdeps, just like installing them? Tried running that and it picked old versions. Then tried with @2.0.0-0 and it errored out

@mifi
Copy link
Collaborator

mifi commented Oct 28, 2021

which peer deps are giving you an error? peer deps are just normal deps, nothing special about them (just a flag saying that a subdependency requires the peer deps)

@mifi
Copy link
Collaborator

mifi commented Oct 28, 2021

I took my liberty of updating your comment above to add -D in yarn add as it is most common to have linting as part of dev dependnecies to avoid them being installed in production or by consuming apps.

As for api2 I see that all linting is part of dependencies - I'm not sure if that is deliberate. It may severely increase install times on production servers when using yarn --prod

I also had to run the following:

yarn add -D eslint-plugin-promise@^4.3.1 eslint-plugin-import eslint-plugin-node

@kvz
Copy link
Member Author

kvz commented Oct 28, 2021

which peer deps are giving you an error? peer deps are just normal deps, nothing special about them (just a flag saying that a subdependency requires the peer deps)

I basically meant: this line was quite convenient for installing peerDeps: npx install-peerdeps --dev eslint-config-transloadit i thought, but i could not change it to automatically install/upgrade to the peerDeps of 2.0.0-0. For instance, just running that command defaulted to 1.3 versions. And running npx install-peerdeps --dev eslint-config-transloadit@2.0.0-0 errored out.

@kvz
Copy link
Member Author

kvz commented Oct 28, 2021

Thanks for the other additions, changed the instructions accordingly (i think) 👌

@kvz
Copy link
Member Author

kvz commented Oct 28, 2021

As for api2 I see that all linting is part of dependencies - I'm not sure if that is deliberate. It may severely increase install times on production servers when using yarn --prod

Ah yes, and you make a good point. The api works a bit different tho so in practice it doesn't matter there. But we might as well do it right everywhere 👌

@mifi
Copy link
Collaborator

mifi commented Oct 28, 2021

I basically meant: this line was quite convenient for installing peerDeps: npx install-peerdeps --dev eslint-config-transloadit i thought, but i could not change it to automatically install/upgrade to the peerDeps of 2.0.0-0. For instance, just running that command defaulted to 1.3 versions. And running npx install-peerdeps --dev eslint-config-transloadit@2.0.0-0 errored out.

Ah. I managed to get this command to work to list out the deps:

npm info "eslint-config-transloadit@2.0.0-0" peerDependencies
 
{
  '@babel/core': '^7.13.10',
  '@babel/eslint-parser': '^7.13.10',
  '@babel/eslint-plugin': '^7.13.10',
  eslint: '^7.22.0',
  'eslint-plugin-import': '^2.22.1',
  'eslint-plugin-jest': '^24.3.1',
  'eslint-plugin-jsx-a11y': '^6.4.1',
  'eslint-plugin-node': '^11.1.0',
  'eslint-plugin-promise': '^4.3.1',
  'eslint-plugin-react': '^7.22.0',
  'eslint-plugin-react-hooks': '^4.2.0'
}

but I think peerDeps for v1 and v2.0.0-0 are the same, no?

https://github.com/transloadit/eslint-config-transloadit/blame/main/package.json

@kvz
Copy link
Member Author

kvz commented Oct 28, 2021

Ah okay that clears things up, thanks!

@kvz
Copy link
Member Author

kvz commented Nov 1, 2021

To go 2.0.0 after going 2.0.0-0:

yarn add -D eslint-config-transloadit
# remove any reference of: no-underscore-dangle
yarn fix
# commit as: Upgrade to linting 2.0.0 (final release)

@kvz
Copy link
Member Author

kvz commented Nov 1, 2021

Upgraded all consumers, just in master, to the final release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
satellite Miscellanous related projects
Projects
None yet
Development

No branches or pull requests

3 participants