Errors from old Python setuptools

Setuptools 40.6 added section [options.data_files] to setup.cfg. Having setuptools < 40.6 results in this error upon trying to install a Python package:

distutils.errors.DistutilsOptionError: Unsupported distribution option section: [options.data_files]

Fix: upgrade setuptools via:

pip install --upgrade setuptools

Example

A setup.cfg might contain [options.data_files] section like:

[options.data_files]
data = myprogram/data/stuff.txt