# Buggy code
def show(self, file=None):
    if file is None:
        file = get_text_stderr()
    color = None
    if self.ctx is not None:
        color = self.ctx.color
    if self.extra:
        if isinstance(self.extra, six.string_types):
            self.extra = [
                self.extra,
            ]
        for extra in self.extra:
            if color:
                extra = getattr(crayons, color, "blue")(extra)
            click_echo(fix_utf8(extra), file=file)
    hint = ""
    if self.cmd is not None and self.cmd.get_help_option(self.ctx) is not None:
        hint = 'Try "%s %s" for help.\n' % (
            self.ctx.command_path,
            self.ctx.help_option_names[0],
        )
    if self.ctx is not None:
        click_echo(self.ctx.get_usage() + "\n%s" % hint, file=file, color=color)
    click_echo(self.message, file=file)


# Traceback (json.decoder.JSONDecodeError)
$ pipenv check --system
Checking PEP 508 requirements...
Traceback (most recent call last):
File "/usr/local/bin/pipenv", line 11, in <module>
sys.exit(cli())
File "/usr/local/lib/python3.5/dist-packages/pipenv/vendor/click/core.py", line 722, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/pipenv/vendor/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.5/dist-packages/pipenv/vendor/click/core.py", line 1066, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python3.5/dist-packages/pipenv/vendor/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.5/dist-packages/pipenv/vendor/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/pipenv/cli.py", line 762, in check
pypi_mirror=pypi_mirror
File "/usr/local/lib/python3.5/dist-packages/pipenv/core.py", line 2295, in do_check
results = simplejson.loads(c.out)
File "/usr/lib/python3.5/json/__init__.py", line 319, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.5/json/decoder.py", line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.5/json/decoder.py", line 357, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

# Fixed code
def show(self, file=None):
    if file is None:
        file = get_text_stderr()
    color = None
    if self.ctx is not None:
        color = self.ctx.color
    if self.extra:
        if isinstance(self.extra, six.string_types):
            self.extra = [
                self.extra,
            ]
        for extra in self.extra:
            if color:
                extra = getattr(crayons, color, "blue")(extra)
            click_echo(decode_for_output(extra, file), file=file)
    hint = ""
    if self.cmd is not None and self.cmd.get_help_option(self.ctx) is not None:
        hint = 'Try "%s %s" for help.\n' % (
            self.ctx.command_path,
            self.ctx.help_option_names[0],
        )
    if self.ctx is not None:
        click_echo(self.ctx.get_usage() + "\n%s" % hint, file=file, color=color)
    click_echo(self.message, file=file)