Skip to content

Commit 29d007b

Browse files
authored
[3.6] bpo-30871: Add test.pythoninfo (#3174)
* bpo-30871: Add test.pythoninfo (#3075) * Add Lib/test/pythoninfo.py: script collecting various informations about Python to help debugging test failures. * regrtest: remove sys.hash_info and sys.flags from header. * Travis CI, Appveyor: run pythoninfo before tests (cherry picked from commit b907abc) * bpo-30871: pythoninfo: add expat and _decimal (#3121) * bpo-30871: pythoninfo: add expat and _decimal * Remove _decimal.__version__ The string is hardcoded, not really interesting. (cherry picked from commit f6ebd83) * bpo-30871: Add "make pythoninfo" (#3120) (cherry picked from commit a3a01a2) * bpo-30871: pythoninfo: more sys, os, time data (#3130) * bpo-30871: pythoninfo: more sys, os, time data PythonInfo now converts types other than intger to string by default. * fix typo (cherry picked from commit ad7eaed) * bpo-31231: Fix pythoninfo in Travis config (#3134) bpo-31231, bpo-30871: Replace "./python -m test.pythoninfo" with "make pythoninfo", since macOS uses ./python.exe. (cherry picked from commit 92b1f90)
1 parent e76cb43 commit 29d007b

File tree

5 files changed

+479
-3
lines changed

5 files changed

+479
-3
lines changed

.github/appveyor.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ branches:
77
- buildbot-custom
88
build_script:
99
- cmd: PCbuild\build.bat -e
10+
- cmd: PCbuild\win32\python.exe -m test.pythoninfo
1011
test_script:
1112
- cmd: PCbuild\rt.bat -q -uall -u-cpu -rwW --slowest --timeout=1200 -j0
1213
environment:

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ matrix:
5959
# Need a venv that can parse covered code.
6060
./python -m venv venv
6161
./venv/bin/python -m pip install -U coverage
62+
./venv/bin/python -m test.pythoninfo
6263
script:
6364
# Skip tests that re-run the entire test suite.
6465
- ./venv/bin/python -m coverage run --pylib -m test -uall,-cpu -x test_multiprocessing_fork -x test_multiprocessing_forkserver -x test_multiprocessing_spawn
@@ -86,6 +87,7 @@ before_script:
8687
echo "$changes"
8788
exit 1
8889
fi
90+
make pythoninfo
8991
9092
script:
9193
# Using the built Python as patchcheck.py is built around the idea of using

Lib/test/libregrtest/main.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -423,16 +423,13 @@ def display_header(self):
423423
print("==", platform.python_implementation(), *sys.version.split())
424424
print("==", platform.platform(aliased=True),
425425
"%s-endian" % sys.byteorder)
426-
print("== hash algorithm:", sys.hash_info.algorithm,
427-
"64bit" if sys.maxsize > 2**32 else "32bit")
428426
print("== cwd:", os.getcwd())
429427
cpu_count = os.cpu_count()
430428
if cpu_count:
431429
print("== CPU count:", cpu_count)
432430
print("== encodings: locale=%s, FS=%s"
433431
% (locale.getpreferredencoding(False),
434432
sys.getfilesystemencoding()))
435-
print("Testing with flags:", sys.flags)
436433

437434
def run_tests(self):
438435
# For a partial run, we do not need to clutter the output.

0 commit comments

Comments
 (0)