mirror of
https://github.com/actions/setup-python.git
synced 2025-04-24 15:32:13 +00:00
Revert poetry and pipenv changes
This commit is contained in:
parent
f8a2339550
commit
a0c296a502
3 changed files with 9 additions and 42 deletions
24
dist/setup/index.js
vendored
24
dist/setup/index.js
vendored
|
@ -64494,7 +64494,6 @@ const glob = __importStar(__nccwpck_require__(8090));
|
||||||
const os = __importStar(__nccwpck_require__(2037));
|
const os = __importStar(__nccwpck_require__(2037));
|
||||||
const path = __importStar(__nccwpck_require__(1017));
|
const path = __importStar(__nccwpck_require__(1017));
|
||||||
const core = __importStar(__nccwpck_require__(2186));
|
const core = __importStar(__nccwpck_require__(2186));
|
||||||
const utils_1 = __nccwpck_require__(1314);
|
|
||||||
const cache_distributor_1 = __importDefault(__nccwpck_require__(8953));
|
const cache_distributor_1 = __importDefault(__nccwpck_require__(8953));
|
||||||
class PipenvCache extends cache_distributor_1.default {
|
class PipenvCache extends cache_distributor_1.default {
|
||||||
constructor(pythonVersion, patterns = '**/Pipfile.lock') {
|
constructor(pythonVersion, patterns = '**/Pipfile.lock') {
|
||||||
|
@ -64521,16 +64520,9 @@ class PipenvCache extends cache_distributor_1.default {
|
||||||
}
|
}
|
||||||
computeKeys() {
|
computeKeys() {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
const hash = yield glob.hashFiles(this.cacheDependencyPath);
|
const hash = yield glob.hashFiles(this.patterns);
|
||||||
let primaryKey = '';
|
const primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
||||||
const restoreKey = undefined;
|
const restoreKey = undefined;
|
||||||
if (utils_1.IS_LINUX) {
|
|
||||||
const osRelease = yield utils_1.getLinuxOSReleaseInfo();
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${osRelease}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
}
|
|
||||||
return {
|
return {
|
||||||
primaryKey,
|
primaryKey,
|
||||||
restoreKey
|
restoreKey
|
||||||
|
@ -64583,7 +64575,6 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||||
const glob = __importStar(__nccwpck_require__(8090));
|
const glob = __importStar(__nccwpck_require__(8090));
|
||||||
const path = __importStar(__nccwpck_require__(1017));
|
const path = __importStar(__nccwpck_require__(1017));
|
||||||
const exec = __importStar(__nccwpck_require__(1514));
|
const exec = __importStar(__nccwpck_require__(1514));
|
||||||
const utils_1 = __nccwpck_require__(1314);
|
|
||||||
const cache_distributor_1 = __importDefault(__nccwpck_require__(8953));
|
const cache_distributor_1 = __importDefault(__nccwpck_require__(8953));
|
||||||
class PoetryCache extends cache_distributor_1.default {
|
class PoetryCache extends cache_distributor_1.default {
|
||||||
constructor(pythonVersion, patterns = '**/poetry.lock') {
|
constructor(pythonVersion, patterns = '**/poetry.lock') {
|
||||||
|
@ -64605,16 +64596,9 @@ class PoetryCache extends cache_distributor_1.default {
|
||||||
}
|
}
|
||||||
computeKeys() {
|
computeKeys() {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
const hash = yield glob.hashFiles(this.cacheDependencyPath);
|
const hash = yield glob.hashFiles(this.patterns);
|
||||||
let primaryKey = '';
|
const primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
||||||
const restoreKey = undefined;
|
const restoreKey = undefined;
|
||||||
if (utils_1.IS_LINUX) {
|
|
||||||
const osRelease = yield utils_1.getLinuxOSReleaseInfo();
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${osRelease}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
}
|
|
||||||
return {
|
return {
|
||||||
primaryKey,
|
primaryKey,
|
||||||
restoreKey
|
restoreKey
|
||||||
|
|
|
@ -2,7 +2,6 @@ import * as glob from '@actions/glob';
|
||||||
import * as os from 'os';
|
import * as os from 'os';
|
||||||
import * as path from 'path';
|
import * as path from 'path';
|
||||||
import * as core from '@actions/core';
|
import * as core from '@actions/core';
|
||||||
import {getLinuxOSReleaseInfo, IS_LINUX} from '../utils';
|
|
||||||
|
|
||||||
import CacheDistributor from './cache-distributor';
|
import CacheDistributor from './cache-distributor';
|
||||||
|
|
||||||
|
@ -32,17 +31,9 @@ class PipenvCache extends CacheDistributor {
|
||||||
}
|
}
|
||||||
|
|
||||||
protected async computeKeys() {
|
protected async computeKeys() {
|
||||||
const hash = await glob.hashFiles(this.cacheDependencyPath);
|
const hash = await glob.hashFiles(this.patterns);
|
||||||
let primaryKey = '';
|
const primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
||||||
const restoreKey = undefined;
|
const restoreKey = undefined;
|
||||||
|
|
||||||
if (IS_LINUX) {
|
|
||||||
const osRelease = await getLinuxOSReleaseInfo();
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${osRelease}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
} else {
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
}
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
primaryKey,
|
primaryKey,
|
||||||
restoreKey
|
restoreKey
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import * as glob from '@actions/glob';
|
import * as glob from '@actions/glob';
|
||||||
|
import * as os from 'os';
|
||||||
import * as path from 'path';
|
import * as path from 'path';
|
||||||
import * as exec from '@actions/exec';
|
import * as exec from '@actions/exec';
|
||||||
import {getLinuxOSReleaseInfo, IS_LINUX} from '../utils';
|
|
||||||
|
|
||||||
import CacheDistributor from './cache-distributor';
|
import CacheDistributor from './cache-distributor';
|
||||||
|
|
||||||
|
@ -32,17 +32,9 @@ class PoetryCache extends CacheDistributor {
|
||||||
}
|
}
|
||||||
|
|
||||||
protected async computeKeys() {
|
protected async computeKeys() {
|
||||||
const hash = await glob.hashFiles(this.cacheDependencyPath);
|
const hash = await glob.hashFiles(this.patterns);
|
||||||
let primaryKey = '';
|
const primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
||||||
const restoreKey = undefined;
|
const restoreKey = undefined;
|
||||||
|
|
||||||
if (IS_LINUX) {
|
|
||||||
const osRelease = await getLinuxOSReleaseInfo();
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${osRelease}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
} else {
|
|
||||||
primaryKey = `${this.CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-python-${this.pythonVersion}-${this.packageManager}-${hash}`;
|
|
||||||
}
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
primaryKey,
|
primaryKey,
|
||||||
restoreKey
|
restoreKey
|
||||||
|
|
Loading…
Add table
Reference in a new issue