chore: use node version from puppeteer for issue analyzer (#9485)

This commit is contained in:
jrandolf 2023-01-11 13:38:23 +01:00 committed by GitHub
parent 4240e15f55
commit 3fde00525e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -12,6 +12,7 @@ import {
lastMaintainedChromiumVersion, lastMaintainedChromiumVersion,
} from '../versions.js'; } from '../versions.js';
import core from '@actions/core'; import core from '@actions/core';
import packageJson from '../packages/puppeteer/package.json' assert {type: 'json'};
const LAST_SUPPORTED_PUPPETEER_VERSION = versionsPerRelease.get( const LAST_SUPPORTED_PUPPETEER_VERSION = versionsPerRelease.get(
lastMaintainedChromiumVersion lastMaintainedChromiumVersion
@ -19,7 +20,7 @@ const LAST_SUPPORTED_PUPPETEER_VERSION = versionsPerRelease.get(
if (!LAST_SUPPORTED_PUPPETEER_VERSION) { if (!LAST_SUPPORTED_PUPPETEER_VERSION) {
core.setFailed('No maintained version found.'); core.setFailed('No maintained version found.');
} }
const LAST_SUPPORTED_NODE_VERSION = '14.19.0'; const LAST_SUPPORTED_NODE_VERSION = packageJson.engines.node.slice(2).trim();
const SUPPORTED_OSES = ['windows', 'macos', 'linux']; const SUPPORTED_OSES = ['windows', 'macos', 'linux'];
const SUPPORTED_PACKAGE_MANAGERS = ['yarn', 'npm', 'pnpm']; const SUPPORTED_PACKAGE_MANAGERS = ['yarn', 'npm', 'pnpm'];