mirror of
https://github.com/actions/setup-python.git
synced 2026-01-20 21:08:54 +08:00
add fixes
This commit is contained in:
parent
b313c4cb46
commit
cb8feb63f7
4 changed files with 40 additions and 7 deletions
|
|
@ -33,15 +33,20 @@ class PoetryCache extends CacheDistributor {
|
|||
|
||||
if (pythonLocation) {
|
||||
core.debug(`pythonLocation is ${pythonLocation}`);
|
||||
const {exitCode, stderr} = await exec.getExecOutput(
|
||||
`poetry env use ${pythonLocation}`
|
||||
const {
|
||||
exitCode,
|
||||
stderr
|
||||
} = await exec.getExecOutput(
|
||||
`poetry env use ${pythonLocation}`,
|
||||
undefined,
|
||||
{ignoreReturnCode: true}
|
||||
);
|
||||
|
||||
if (exitCode) {
|
||||
throw new Error(stderr);
|
||||
core.info(`[warning]${stderr}`);
|
||||
}
|
||||
} else {
|
||||
core.warning('python binaries were not found in PATH.');
|
||||
core.info('[warning]python binaries were not found in PATH.');
|
||||
}
|
||||
|
||||
return paths;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue