Skip to content

Commit

Permalink
Add warning for python 2.7 (#673)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitry-shibanov authored May 24, 2023
1 parent 0cbcb9a commit bd6b4b6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dist/setup/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -67612,6 +67612,9 @@ function run() {
core.info(`Successfully set up PyPy ${installed.resolvedPyPyVersion} with Python (${installed.resolvedPythonVersion})`);
}
else {
if (version.startsWith('2')) {
core.warning('The support for python 2.7 will be removed on June 19. Related issue: https://github.com/actions/setup-python/issues/672');
}
const installed = yield finder.useCpythonVersion(version, arch, updateEnvironment, checkLatest, allowPreReleases);
pythonVersion = installed.version;
core.info(`Successfully set up ${installed.impl} (${pythonVersion})`);
Expand Down
5 changes: 5 additions & 0 deletions src/setup-python.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,11 @@ async function run() {
`Successfully set up PyPy ${installed.resolvedPyPyVersion} with Python (${installed.resolvedPythonVersion})`
);
} else {
if (version.startsWith('2')) {
core.warning(
'The support for python 2.7 will be removed on June 19. Related issue: https://github.com/actions/setup-python/issues/672'
);
}
const installed = await finder.useCpythonVersion(
version,
arch,
Expand Down

0 comments on commit bd6b4b6

Please sign in to comment.