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

Update to Node 18.0.0 #471

Merged
merged 19 commits into from May 23, 2022
Merged

Update to Node 18.0.0 #471

merged 19 commits into from May 23, 2022

Conversation

ShogunPanda
Copy link
Contributor

@ShogunPanda ShogunPanda commented Apr 15, 2022

Summary:

  1. Rewrite the build system reducing dependency.
  2. Drop compatiblity for Node < 12.0 and Internet Explorer. Only active Node versions and ever-green browsers are supported.
  3. Dropped most dependency (note: once we decide to drop support for Node 12 and Node 14, no dependency besides object-inspect, which is for browsers, will be needed)
  4. Updated the exported stream API to Node 18.0.0.

.github/workflows/ci.yml Outdated Show resolved Hide resolved
.github/workflows/ci.yml Outdated Show resolved Hide resolved
.github/workflows/sauce.yml Outdated Show resolved Hide resolved
.gitignore Outdated Show resolved Hide resolved
build/build.mjs Show resolved Hide resolved
examples/capslock-type.cjs Outdated Show resolved Hide resolved
examples/typer.mjs Show resolved Hide resolved
lib/internal/js_stream_socket.js Outdated Show resolved Hide resolved
lib/internal/inspect.js Outdated Show resolved Hide resolved
lib/internal/inspect-browser.js Outdated Show resolved Hide resolved
lib/internal/errors.js Outdated Show resolved Hide resolved
@@ -0,0 +1,446 @@

'use strict';
Copy link
Member

Choose a reason for hiding this comment

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

remove this file, we don't want primordials.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Unfortunately the Node core uses primordials everywhere.
I've replaced with a custom slimmed down primordials file.

package.json Outdated Show resolved Hide resolved
@benjamingr
Copy link
Member

This is great, awesome work - thanks 🙏

(Not LGTMing since I didn't review fully and Matteo is already looking whom I trust to approve once issues have been resolved)

@mcollina
Copy link
Member

If supporting Node v12 does not add much of a problem, then it would be great!

@ShogunPanda
Copy link
Contributor Author

I'll try and see what happens. Will keep you posted!

@mcollina
Copy link
Member

Good work! I see CI is passing.. minus Safari. Do you know why?

@ShogunPanda
Copy link
Contributor Author

There is a bug reported in airtap-sauce (airtap/sauce#11).

I was thinking: since we can use playwright for all browsers and all platforms (thanks to GH actions matrix), do we still need sauce?

Anyway, tomorrow I'll focus on Node 12 compatibility (I think I just have to transpile ?. and ??) and this should be good to go.

@mcollina
Copy link
Member

playwright would be awesome

@ShogunPanda ShogunPanda changed the title Node 18 Update to Node 18.0.0 Apr 21, 2022
@ShogunPanda
Copy link
Contributor Author

@mcollina I was able to accomplish both: Node 12 is now supported and SauceLabs has been dropped in favor of playwright.

lib/internal/streams/pipeline.js Outdated Show resolved Hide resolved
lib/ours/util.js Outdated Show resolved Hide resolved
lib/ours/util.js Outdated Show resolved Hide resolved
lib/ours/errors.js Outdated Show resolved Hide resolved
lib/ours/errors.js Outdated Show resolved Hide resolved
lib/ours/errors.js Outdated Show resolved Hide resolved
},
"license": "MIT"
"dependencies": {
Copy link
Member

Choose a reason for hiding this comment

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

I think this is missing the string_decoder module for Browser usage. Please verify everything is working webpack and rollup.

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@mcollina mcollina merged commit 81c5264 into nodejs:main May 23, 2022
@ShogunPanda ShogunPanda deleted the node-18 branch May 24, 2022 05:54
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.

None yet

4 participants