From c22a5ffae7e02f31242fcc705696eec6f55caac7 Mon Sep 17 00:00:00 2001 From: Hugo Date: Mon, 9 Dec 2019 22:35:31 +0200 Subject: [PATCH] Print some basic system information for the logs --- .github/workflows/lint.yml | 3 +++ .github/workflows/system-info.py | 24 ++++++++++++++++++++++++ .github/workflows/test-docker.yml | 3 +++ .github/workflows/test-windows.yml | 3 +++ .github/workflows/test.yml | 3 +++ 5 files changed, 36 insertions(+) create mode 100644 .github/workflows/system-info.py diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 195ea386524..576b884143e 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -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 diff --git a/.github/workflows/system-info.py b/.github/workflows/system-info.py new file mode 100644 index 00000000000..499935b4d81 --- /dev/null +++ b/.github/workflows/system-info.py @@ -0,0 +1,24 @@ +""" +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()) +print("platform.mac_ver()\t", platform.mac_ver()) diff --git a/.github/workflows/test-docker.yml b/.github/workflows/test-docker.yml index 4121eb5e9f8..3e8a416a576 100644 --- a/.github/workflows/test-docker.yml +++ b/.github/workflows/test-docker.yml @@ -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 }} diff --git a/.github/workflows/test-windows.yml b/.github/workflows/test-windows.yml index 00cae9bc2c7..e0c55bc1a1f 100644 --- a/.github/workflows/test-windows.yml +++ b/.github/workflows/test-windows.yml @@ -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 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 69ed445a6bc..78307b7a11a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -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: |