Compare commits

..

2 Commits

Author SHA1 Message Date
gowridurgad
b30ec2846d Check failure fix 2026-01-29 16:59:28 +05:30
dependabot[bot]
9799cba2a7 Bump eslint from 8.57.1 to 9.39.2
Bumps [eslint](https://github.com/eslint/eslint) from 8.57.1 to 9.39.2.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/compare/v8.57.1...v9.39.2)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 9.39.2
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-01-19 07:34:44 +00:00
7 changed files with 456 additions and 668 deletions

View File

@@ -44084,14 +44084,6 @@ const cachePackages = async (packageManager) => {
core.debug(`Caching for '${packageManager}' is not supported`);
return;
}
// Check if the package manager is installed before attempting to save cache
// This prevents cache save failures for package managers that may not be installed
const isInstalled = await (0, cache_utils_1.isPackageManagerInstalled)(packageManager);
if (!isInstalled) {
core.warning(`Package manager '${packageManager}' was not found in the PATH. ` +
`Skipping cache save.`);
return;
}
if (!cachePaths.length) {
// TODO: core.getInput has a bug - it can return undefined despite its definition (tests only?)
// export declare function getInput(name: string, options?: InputOptions): string;
@@ -44155,7 +44147,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.repoHasYarnBerryManagedDependencies = exports.getCacheDirectories = exports.resetProjectDirectoriesMemoized = exports.isPackageManagerInstalled = exports.getPackageManagerInfo = exports.getCommandOutputNotEmpty = exports.getCommandOutput = exports.supportedPackageManagers = void 0;
exports.repoHasYarnBerryManagedDependencies = exports.getCacheDirectories = exports.resetProjectDirectoriesMemoized = exports.getPackageManagerInfo = exports.getCommandOutputNotEmpty = exports.getCommandOutput = exports.supportedPackageManagers = void 0;
exports.isGhes = isGhes;
exports.isCacheFeatureAvailable = isCacheFeatureAvailable;
const core = __importStar(__nccwpck_require__(37484));
@@ -44226,25 +44218,6 @@ const getPackageManagerInfo = async (packageManager) => {
}
};
exports.getPackageManagerInfo = getPackageManagerInfo;
/**
* Checks if a package manager is installed and available on the PATH
* This helps prevent cache failures when a package manager is specified
* but not yet installed (e.g., pnpm via corepack)
* See: https://github.com/actions/setup-node/issues/1357
*/
const isPackageManagerInstalled = async (packageManager) => {
try {
const { exitCode } = await exec.getExecOutput(`${packageManager} --version`, undefined, {
ignoreReturnCode: true,
silent: true
});
return exitCode === 0;
}
catch {
return false;
}
};
exports.isPackageManagerInstalled = isPackageManagerInstalled;
/**
* getProjectDirectoriesFromCacheDependencyPath is called twice during `restoreCache`
* - first through `getCacheDirectories`

31
dist/setup/index.js vendored
View File

@@ -53696,16 +53696,6 @@ const restoreCache = async (packageManager, cacheDependencyPath) => {
if (!packageManagerInfo) {
throw new Error(`Caching for '${packageManager}' is not supported`);
}
// Check if the package manager is installed before attempting to cache
// This prevents cache failures for package managers that need to be installed first
// See: https://github.com/actions/setup-node/issues/1357
const isInstalled = await (0, cache_utils_1.isPackageManagerInstalled)(packageManager);
if (!isInstalled) {
core.warning(`Package manager '${packageManager}' was not found in the PATH. ` +
`Skipping cache restore. Please ensure the package manager is installed ` +
`before running this action or set 'package-manager-cache: false' to disable caching.`);
return;
}
const platform = process.env.RUNNER_OS;
const arch = os_1.default.arch();
const cachePaths = await (0, cache_utils_1.getCacheDirectories)(packageManagerInfo, cacheDependencyPath);
@@ -53795,7 +53785,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.repoHasYarnBerryManagedDependencies = exports.getCacheDirectories = exports.resetProjectDirectoriesMemoized = exports.isPackageManagerInstalled = exports.getPackageManagerInfo = exports.getCommandOutputNotEmpty = exports.getCommandOutput = exports.supportedPackageManagers = void 0;
exports.repoHasYarnBerryManagedDependencies = exports.getCacheDirectories = exports.resetProjectDirectoriesMemoized = exports.getPackageManagerInfo = exports.getCommandOutputNotEmpty = exports.getCommandOutput = exports.supportedPackageManagers = void 0;
exports.isGhes = isGhes;
exports.isCacheFeatureAvailable = isCacheFeatureAvailable;
const core = __importStar(__nccwpck_require__(37484));
@@ -53866,25 +53856,6 @@ const getPackageManagerInfo = async (packageManager) => {
}
};
exports.getPackageManagerInfo = getPackageManagerInfo;
/**
* Checks if a package manager is installed and available on the PATH
* This helps prevent cache failures when a package manager is specified
* but not yet installed (e.g., pnpm via corepack)
* See: https://github.com/actions/setup-node/issues/1357
*/
const isPackageManagerInstalled = async (packageManager) => {
try {
const { exitCode } = await exec.getExecOutput(`${packageManager} --version`, undefined, {
ignoreReturnCode: true,
silent: true
});
return exitCode === 0;
}
catch {
return false;
}
};
exports.isPackageManagerInstalled = isPackageManagerInstalled;
/**
* getProjectDirectoriesFromCacheDependencyPath is called twice during `restoreCache`
* - first through `getCacheDirectories`

1004
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -43,12 +43,12 @@
"@types/jest": "^29.5.14",
"@types/node": "^24.1.0",
"@types/semver": "^7.5.8",
"@typescript-eslint/eslint-plugin": "^5.54.0",
"@typescript-eslint/parser": "^5.54.0",
"@typescript-eslint/eslint-plugin": "^8.54.0",
"@typescript-eslint/parser": "^8.54.0",
"@vercel/ncc": "^0.38.3",
"eslint": "^8.57.0",
"eslint": "^9.39.2",
"eslint-config-prettier": "^8.6.0",
"eslint-plugin-jest": "^27.9.0",
"eslint-plugin-jest": "^28.14.0",
"eslint-plugin-node": "^11.1.0",
"jest": "^29.7.0",
"jest-circus": "^29.7.0",

View File

@@ -9,7 +9,6 @@ import {State} from './constants';
import {
getCacheDirectories,
getPackageManagerInfo,
isPackageManagerInstalled,
repoHasYarnBerryManagedDependencies,
PackageManagerInfo
} from './cache-utils';
@@ -22,20 +21,6 @@ export const restoreCache = async (
if (!packageManagerInfo) {
throw new Error(`Caching for '${packageManager}' is not supported`);
}
// Check if the package manager is installed before attempting to cache
// This prevents cache failures for package managers that need to be installed first
// See: https://github.com/actions/setup-node/issues/1357
const isInstalled = await isPackageManagerInstalled(packageManager);
if (!isInstalled) {
core.warning(
`Package manager '${packageManager}' was not found in the PATH. ` +
`Skipping cache restore. Please ensure the package manager is installed ` +
`before running this action or set 'package-manager-cache: false' to disable caching.`
);
return;
}
const platform = process.env.RUNNER_OS;
const arch = os.arch();

View File

@@ -2,7 +2,7 @@ import * as core from '@actions/core';
import * as cache from '@actions/cache';
import {State} from './constants';
import {getPackageManagerInfo, isPackageManagerInstalled} from './cache-utils';
import {getPackageManagerInfo} from './cache-utils';
// Catch and log any unhandled exceptions. These exceptions can leak out of the uploadChunk method in
// @actions/toolkit when a failed upload closes the file descriptor causing any in-process reads to
@@ -45,17 +45,6 @@ const cachePackages = async (packageManager: string) => {
return;
}
// Check if the package manager is installed before attempting to save cache
// This prevents cache save failures for package managers that may not be installed
const isInstalled = await isPackageManagerInstalled(packageManager);
if (!isInstalled) {
core.warning(
`Package manager '${packageManager}' was not found in the PATH. ` +
`Skipping cache save.`
);
return;
}
if (!cachePaths.length) {
// TODO: core.getInput has a bug - it can return undefined despite its definition (tests only?)
// export declare function getInput(name: string, options?: InputOptions): string;

View File

@@ -110,30 +110,6 @@ export const getPackageManagerInfo = async (packageManager: string) => {
}
};
/**
* Checks if a package manager is installed and available on the PATH
* This helps prevent cache failures when a package manager is specified
* but not yet installed (e.g., pnpm via corepack)
* See: https://github.com/actions/setup-node/issues/1357
*/
export const isPackageManagerInstalled = async (
packageManager: string
): Promise<boolean> => {
try {
const {exitCode} = await exec.getExecOutput(
`${packageManager} --version`,
undefined,
{
ignoreReturnCode: true,
silent: true
}
);
return exitCode === 0;
} catch {
return false;
}
};
/**
* getProjectDirectoriesFromCacheDependencyPath is called twice during `restoreCache`
* - first through `getCacheDirectories`