-
-
Notifications
You must be signed in to change notification settings - Fork 539
Closed
Description
Issue
When DEFAULT_CONFIG_FILE
is corrupted, tox outputs failed to read config file None
.
Environment
Provide at least:
- OS: Linux
Output of pip list
of the host Python, where tox
is installed
$ pip list
Package Version Editable project location
------------- -------------------------------- -------------------------
cachetools 6.2.0
chardet 5.2.0
colorama 0.4.6
distlib 0.4.0
filelock 3.19.1
packaging 25.0
pip 25.2
platformdirs 4.4.0
pluggy 1.6.0
pyproject-api 1.9.1
setuptools 80.9.0
tox 4.30.3.dev0+g5e0784a7f.d20250917 /home/kurt/dev/pr-tox
virtualenv 20.34.0
wheel 0.45.1
Output of running tox
Output of tox -rvv
$ tox --help
ERROR:root:failed to read config file None because File contains no section headers.
file: '/home/kurt/.config/tox/config.ini', line: 1
'[tox\n'
ROOT: failed to read config file None because File contains no section headers.
file: '/home/kurt/.config/tox/config.ini', line: 1
'[tox\n'
usage: tox [-h] [--colored {yes,no}] [--stderr-color {BLACK,BLUE,CYAN,GREEN,LIGHTBLACK_EX,LIGHTBLUE_EX,LIGHTCYAN_EX,LIGHTGREEN_EX,LIGHTMAGENTA_EX,LIGHTRED_EX,LIGHTWHITE_EX,LIGHTYELLOW_EX,MAGENTA,RED,RESET,WHITE,YELLOW}] [-v | -q]
...
Minimal example
$ echo '[tox' > ~/.config/tox/config.ini
Metadata
Metadata
Assignees
Labels
No labels