Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit556ac3e

Browse files
committed
Remove pyproject.toml from default values
1 parent6f8266d commit556ac3e

File tree

3 files changed

+5
-100
lines changed

3 files changed

+5
-100
lines changed

‎.github/workflows/test-python.yml‎

Lines changed: 0 additions & 96 deletions
Original file line numberDiff line numberDiff line change
@@ -200,54 +200,6 @@ jobs:
200200
-name:Run simple code
201201
run:python -c 'import math; print(math.factorial(5))'
202202

203-
setup-versions-from-standard-pyproject-file-without-parameter:
204-
name:Setup ${{ matrix.python }} ${{ matrix.os }} standard pyproject file without parameter
205-
runs-on:${{ matrix.os }}
206-
strategy:
207-
fail-fast:false
208-
matrix:
209-
os:[macos-latest, windows-latest, ubuntu-20.04, ubuntu-22.04]
210-
python:[3.5.4, 3.6.7, 3.7.5, 3.8.15, 3.9.13]
211-
exclude:
212-
-os:ubuntu-22.04
213-
python:3.5.4
214-
-os:ubuntu-22.04
215-
python:3.6.7
216-
-os:ubuntu-22.04
217-
python:3.7.5
218-
-os:windows-latest
219-
python:3.8.15
220-
steps:
221-
-name:Checkout
222-
uses:actions/checkout@v3
223-
224-
-name:build-version-file ${{ matrix.python }}
225-
run:|
226-
echo '[project]
227-
requires-python = "${{ matrix.python }}"
228-
' > pyproject.toml
229-
230-
-name:setup-python ${{ matrix.python }}
231-
id:setup-python
232-
uses:./
233-
234-
-name:Check python-path
235-
run:./__tests__/check-python-path.sh '${{ steps.setup-python.outputs.python-path }}'
236-
shell:bash
237-
238-
-name:Validate version
239-
run:|
240-
$pythonVersion = (python --version)
241-
if ("Python ${{ matrix.python }}" -ne "$pythonVersion"){
242-
Write-Host "The current version is $pythonVersion; expected version is ${{ matrix.python }}"
243-
exit 1
244-
}
245-
$pythonVersion
246-
shell:pwsh
247-
248-
-name:Run simple code
249-
run:python -c 'import math; print(math.factorial(5))'
250-
251203
setup-versions-from-poetry-pyproject-file:
252204
name:Setup ${{ matrix.python }} ${{ matrix.os }} poetry pyproject file
253205
runs-on:${{ matrix.os }}
@@ -298,54 +250,6 @@ jobs:
298250
-name:Run simple code
299251
run:python -c 'import math; print(math.factorial(5))'
300252

301-
setup-versions-from-poetry-pyproject-file-without-parameter:
302-
name:Setup ${{ matrix.python }} ${{ matrix.os }} poetry pyproject file without parameter
303-
runs-on:${{ matrix.os }}
304-
strategy:
305-
fail-fast:false
306-
matrix:
307-
os:[macos-latest, windows-latest, ubuntu-20.04, ubuntu-22.04]
308-
python:[3.5.4, 3.6.7, 3.7.5, 3.8.15, 3.9.13]
309-
exclude:
310-
-os:ubuntu-22.04
311-
python:3.5.4
312-
-os:ubuntu-22.04
313-
python:3.6.7
314-
-os:ubuntu-22.04
315-
python:3.7.5
316-
-os:windows-latest
317-
python:3.8.15
318-
steps:
319-
-name:Checkout
320-
uses:actions/checkout@v3
321-
322-
-name:build-version-file ${{ matrix.python }}
323-
run:|
324-
echo '[tool.poetry.dependencies]
325-
python = "${{ matrix.python }}"
326-
' > pyproject.toml
327-
328-
-name:setup-python ${{ matrix.python }}
329-
id:setup-python
330-
uses:./
331-
332-
-name:Check python-path
333-
run:./__tests__/check-python-path.sh '${{ steps.setup-python.outputs.python-path }}'
334-
shell:bash
335-
336-
-name:Validate version
337-
run:|
338-
$pythonVersion = (python --version)
339-
if ("Python ${{ matrix.python }}" -ne "$pythonVersion"){
340-
Write-Host "The current version is $pythonVersion; expected version is ${{ matrix.python }}"
341-
exit 1
342-
}
343-
$pythonVersion
344-
shell:pwsh
345-
346-
-name:Run simple code
347-
run:python -c 'import math; print(math.factorial(5))'
348-
349253
setup-pre-release-version-from-manifest:
350254
name:Setup 3.9.0-beta.4 ${{ matrix.os }}
351255
runs-on:${{ matrix.os }}

‎dist/setup/index.js‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69700,7 +69700,6 @@ function cacheDependencies(cache, pythonVersion) {
6970069700
function resolveVersionInputFromDefaultFile() {
6970169701
const couples = [
6970269702
['.python-version', utils_1.getVersionInputFromPlainFile],
69703-
['pyproject.toml', utils_1.getVersionInputFromTomlFile]
6970469703
];
6970569704
for (const [versionFile, _fn] of couples) {
6970669705
utils_1.logWarning(`Neither 'python-version' nor 'python-version-file' inputs were supplied. Attempting to find '${versionFile}' file.`);
@@ -69975,6 +69974,10 @@ function getOSInfo() {
6997569974
});
6997669975
}
6997769976
exports.getOSInfo = getOSInfo;
69977+
/**
69978+
* Extract a value from an object by following the keys path provided.
69979+
* If the value is present, it is returned. Otherwise undefined is returned.
69980+
*/
6997869981
function extractValue(obj, keys) {
6997969982
if (keys.length > 0) {
6998069983
const value = obj[keys[0]];

‎src/setup-python.ts‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ import {
1010
logWarning,
1111
IS_MAC,
1212
getVersionInputFromFile,
13-
getVersionInputFromPlainFile,
14-
getVersionInputFromTomlFile
13+
getVersionInputFromPlainFile
1514
}from'./utils';
1615

1716
functionisPyPyVersion(versionSpec:string){
@@ -32,7 +31,6 @@ async function cacheDependencies(cache: string, pythonVersion: string) {
3231
functionresolveVersionInputFromDefaultFile():string[]{
3332
constcouples:[string,(versionFile:string)=>string[]][]=[
3433
['.python-version',getVersionInputFromPlainFile],
35-
['pyproject.toml',getVersionInputFromTomlFile]
3634
];
3735
for(const[versionFile,_fn]ofcouples){
3836
logWarning(

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp