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

Enable GraphQL file upload tests for Node >16 #7978

Closed
4 tasks done
mtrezza opened this issue May 6, 2022 · 1 comment · Fixed by #7980
Closed
4 tasks done

Enable GraphQL file upload tests for Node >16 #7978

mtrezza opened this issue May 6, 2022 · 1 comment · Fixed by #7980
Labels
type:ci CI related issue

Comments

@mtrezza
Copy link
Member

mtrezza commented May 6, 2022

New Issue Checklist

Issue Description

Some GraphQL file tests needed to be disabled for Node >=17 to bring Parse Server forward for Node 17 / 18 compatibility, see #7896 (comment).

Disabled tests:

it('should support files', async () => {

it('should return File object', async () => {

The node-fetch package became incompatible with its use in GraphQL Parse Server in Node 17/18. Either there is a fix, or node-fetch needs to be replaced with another package.

Going back and using old version of node-fetch 2.x is not an attractive option; the upgrade to 3.x was done previously by dependabot due to a security vulnerability. Even though it's a dev dependency, in a CI/CD pipeline outdated packages can be a security risk, depending on the type of vulnerability. It may also impact Parse Server's vulnerability score, as devDependencies may not always be excluded from that calculation. In addition, we'll keep getting automatic upgrade PRs for node-fetch from dependabot and Snky if we go back to 2.x.

The tests currently run on Node <17; since the Node 16 LTS end date is Apr 2024, we are at least keeping an eye on the tests until then, although we are not running them for Node >16.

Suggested solution:

  • Run the tests only for Node <17 for now
  • Do not run the tests on Node 17, which is an odd-intermediate version where LTS ends 2022-06 anyway
  • Over time (until Node 16 LTS end Apr 2024), create a PR to run the tests on Node 18 using Node's built-in fetch

Steps to reproduce

n/a

Actual Outcome

Tests are disabled.

Expected Outcome

Tests should be enabled.

Environment

n/a

@parse-github-assistant
Copy link

parse-github-assistant bot commented May 6, 2022

Thanks for opening this issue!

  • 🚀 You can help us to fix this issue faster by opening a pull request with a failing test. See our Contribution Guide for how to make a pull request, or read our New Contributor's Guide if this is your first time contributing.

@mtrezza mtrezza added the type:ci CI related issue label May 6, 2022
@mtrezza mtrezza linked a pull request May 6, 2022 that will close this issue
2 tasks
@mtrezza mtrezza changed the title GraphQL file tests disabled Enable GraphQL file upload tests for Node >=18 May 6, 2022
@mtrezza mtrezza changed the title Enable GraphQL file upload tests for Node >=18 Enable GraphQL file upload tests for Node >16 May 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:ci CI related issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant