Merge pull request #4262 from hugovk/gha-system-info

GHA: Print some basic system information for the logs
This commit is contained in:
Hugo van Kemenade 2019-12-15 13:59:54 +02:00 committed by GitHub
commit aea1111aa3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 37 additions and 0 deletions

View File

@ -20,6 +20,9 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
- name: Build system information
run: python .github/workflows/system-info.py
- name: Install dependencies
run: |
python -m pip install --upgrade pip

25
.github/workflows/system-info.py vendored Normal file
View File

@ -0,0 +1,25 @@
"""
Print out some handy system info like Travis CI does.
This sort of info is missing from GitHub Actions.
Requested here:
https://github.com/actions/virtual-environments/issues/79
"""
import os
import platform
import sys
print("Build system information")
print()
print("sys.version\t\t", sys.version.split("\n"))
print("os.name\t\t\t", os.name)
print("sys.platform\t\t", sys.platform)
print("platform.system()\t", platform.system())
print("platform.machine()\t", platform.machine())
print("platform.platform()\t", platform.platform())
print("platform.version()\t", platform.version())
print("platform.uname()\t", platform.uname())
if sys.platform == "darwin":
print("platform.mac_ver()\t", platform.mac_ver())

View File

@ -29,6 +29,9 @@ jobs:
steps:
- uses: actions/checkout@v1
- name: Build system information
run: python .github/workflows/system-info.py
- name: Docker pull
run: |
docker pull pythonpillow/${{ matrix.docker }}:${{ matrix.dockerTag }}

View File

@ -70,6 +70,9 @@ jobs:
python-version: ${{ matrix.python-version }}
architecture: ${{ matrix.architecture }}
- name: Build system information
run: python .github/workflows/system-info.py
- name: pip install wheel pytest pytest-cov
run: |
"%pythonLocation%\python.exe" -m pip install wheel pytest pytest-cov

View File

@ -55,6 +55,9 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
- name: Build system information
run: python .github/workflows/system-info.py
- name: Install Linux dependencies
if: startsWith(matrix.os, 'ubuntu')
run: |