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: replace glob.sync for glob@9 #377

Merged
merged 1 commit into from
Mar 7, 2023
Merged

fix: replace glob.sync for glob@9 #377

merged 1 commit into from
Mar 7, 2023

Conversation

richardlau
Copy link
Member

glob@9 no longer exports sync().

Fixes: #376
Refs: isaacs/node-glob#493
Refs: #372

glob@9 no longer exports `sync()`.

Fixes: #376
Refs: isaacs/node-glob#493
@richardlau
Copy link
Member Author

Alternatively we could revert #372.
According to https://github.com/isaacs/node-glob/blob/main/changelog.md#90, glob@9 drops support for Node.js versions earlier than 16 and we're currently running the bot on Node.js 14:

# node -v
v14.16.1
#

@richardlau
Copy link
Member Author

FWIW I'm not opposed to bumping the version of Node.js on the server running the bot, but our package.json claims this runs on Node.js 12 and later:

github-bot/package.json

Lines 10 to 12 in 1b78c05

"engines": {
"node": ">= 12.0.0"
},

@targos
Copy link
Member

targos commented Mar 7, 2023

I think we should bump the server to at least v16 (ideally v18 to be future-proof).
v14.x is very close to its EoL date.

@richardlau
Copy link
Member Author

I think we should bump the server to at least v16 (ideally v18 to be future-proof). v14.x is very close to its EoL date.

Tried. Blocked on the server still running Debian 8 -- we're using Nodesource distributions of Node.js on the server and they don't have newer Node.js packages for Debian 8 (Jessie). nodejs/build#3214

@Trott
Copy link
Member

Trott commented Mar 7, 2023

Hmmm...it looks like the actions are green when they are failing... https://github.com/nodejs/github-bot/actions/runs/4354160252/jobs/7609125321#step:12:1467 fails but is green....

@richardlau
Copy link
Member Author

Should we go ahead and land this and hope it fixes the current issue?

I'll go ahead and merge and see if the bot at least starts. It can't be worse that the current state, and if it doesn't we can revert this and the glob update temporarily while we get the server updated.

@richardlau richardlau merged commit 7f2b20b into main Mar 7, 2023
@richardlau richardlau deleted the richardlau-globsync branch March 7, 2023 17:12
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.

Bot failing to start: TypeError: glob.sync is not a function
3 participants