Fix a bug when generating the error message in `generate_config_file`

The stdout and stderr parts are rightly decoded as UTF-8, but then they are formatted into a byte string which (at least on my platform) treats the UTF-8 as ascii and boom! exception is raised trying to generate the error message.

Cc: @eteq for confirmation