From ded2c9dadad618cf254f39d0358117300f3f2cc3 Mon Sep 17 00:00:00 2001 From: Jeremy Stanley Date: Tue, 19 Apr 2022 14:39:11 +0000 Subject: [PATCH] Force UTF-8 mode for testing Add the PYTHONWARNDFAULTENCODING and PYTHONUTF8 envvars to guard against addition of any non-UTF-8 behaviors or reliance on implicit encoding default, and to make sure things will continue to work when these switches are on by default in future versions of the interpreter. --- tox.ini | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tox.ini b/tox.ini index 33cf2ca..e62c385 100644 --- a/tox.ini +++ b/tox.ini @@ -49,7 +49,9 @@ basepython = python3 # for migration advice." but this can't be matched by message because it # contains a colon setenv = + PYTHONWARNDFAULTENCODING = 1 PYTHONWARNINGS = error, ignore::FutureWarning:Cython.Compiler.Main, ignore::DeprecationWarning:distutils.command.install, ignore:The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives:DeprecationWarning, ignore:Creating a LegacyVersion has been deprecated and will be removed in the next major release:DeprecationWarning, ignore:SelectableGroups dict interface is deprecated. Use select.:DeprecationWarning:flake8.plugins.manager, ignore:setup.py install is deprecated. Use build and pip and other standards-based tools., ignore:easy_install command is deprecated. Use build and pip and other standards-based tools., ignore::DeprecationWarning:pip._vendor.certifi.core, ignore::DeprecationWarning:pip._vendor.pep517.in_process, ignore:module 'sre_constants' is deprecated:DeprecationWarning:pip._vendor.pyparsing.core, ignore:module 'sre_constants' is deprecated:DeprecationWarning:pkg_resources._vendor.pyparsing + PYTHONUTF8 = 1 VIRTUALENV_CREATOR = venv commands = mudpy_selftest mudpy/tests/fixtures/test_daemon.yaml deps = {toxinidir} -- 2.11.0