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

Upgrade dependencies #293

Merged
merged 7 commits into from
Feb 18, 2022
Merged

Upgrade dependencies #293

merged 7 commits into from
Feb 18, 2022

Conversation

matteofigus
Copy link
Member

@matteofigus matteofigus commented Feb 17, 2022

Update some dependencies. See in-line comments for some details about a couple of changes I had to do in order to simplify dependency management.

PR Checklist:

  • Changelog updated
  • All tests pass
  • Pre-commit checks pass
  • If releasing a new version, have you bumped the version in the main CFN template?

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@@ -45,7 +45,7 @@ jobs:
- name: Set up Nodejs 12
uses: actions/setup-node@v1
with:
node-version: 12
node-version: 14
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create React App v5 includes loads of warnings for node 12 so I moved all to node 14.

@@ -50,13 +50,13 @@ format-cfn:

.PHONY: format-docs
format-docs:
npx prettier-eslint ./*.md ./docs/*.md --write --prose-wrap always
npx prettier ./*.md ./docs/*.md --write
Copy link
Member Author

@matteofigus matteofigus Feb 18, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create React App v5 moved internally to ESLint 8, and prettier-eslint cli is stuck to ESLint 5: prettier/prettier-eslint-cli#304

When upgrading, prettier-eslint was failing. I decided to just move to prettier cli, which has a --write functionality as well. The difference is that instead of inferring the linting config from the Create React App module, I am defining the config inside the root's package.json. But the advantage is that the dependency tree is much smaller and that allows to remove some vulnerabilities too.

When running with just prettier, the linting is 99% same. You'll notice a couple of new line changes in 5 JavaScript files, but I decided that it was ok for now.

@@ -140,7 +140,7 @@ def glue_columns():
]


@pytest.fixture(scope="session", autouse=True)
@pytest.fixture(scope="module", autouse=True)
Copy link
Member Author

@matteofigus matteofigus Feb 18, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had an issue here when running the acceptance tests. They ran for 64 minutes, and everything running during the last 4 failed with 401 status codes because the token was expired. So I decided to move the cognito token fetch from session to module in order to reduce the probability of that happening again.

@matteofigus matteofigus marked this pull request as ready for review February 18, 2022 15:25
@matteofigus matteofigus requested a review from ctd February 18, 2022 15:25
@matteofigus matteofigus merged commit d419d2b into master Feb 18, 2022
@matteofigus matteofigus deleted the deps branch February 18, 2022 16:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants