Skip to content

Error when reading .coverage file #39

Open
@adirizka7

Description

@adirizka7
Error detected while processing function coverage#Show[9]..function coverage#Show[5]..<SNR>75_CoverageShow[9]..coverage#ShowCoverage[45]..4[13]..maktaba#python#Eval:
line    6:
Traceback (most recent call last):
  File "/usr/lib64/python3.7/site-packages/coverage/data.py", line 293, in read_file
    self.read_fileobj(f)
  File "/usr/lib64/python3.7/site-packages/coverage/data.py", line 271, in read_fileobj
    data = self._read_raw_data(file_obj)
  File "/usr/lib64/python3.7/site-packages/coverage/data.py", line 311, in _read_raw_data
    go_away = file_obj.read(len(cls._GO_AWAY))
  File "/usr/lib64/python3.7/codecs.py", line 322, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf0 in position 99: invalid continuation byte
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/fedora/.vim/plugged/vim-coverage/python/vim_coverage.py", line 33, in GetCoveragePyLines
    cov.load()
  File "/usr/lib64/python3.7/site-packages/coverage/control.py", line 677, in load
    self.data_files.read(self.data)
  File "/usr/lib64/python3.7/site-packages/coverage/data.py", line 653, in read
    data.read_file(self.filename)
  File "/usr/lib64/python3.7/site-packages/coverage/data.py", line 297, in read_file
    filename, exc.__class__.__name__, exc,
coverage.misc.CoverageException: Couldn't read data from '/home/fedora/Desktop/GIT/tinydb/.coverage': UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf0 in position 99: invalid continu
ation byte
E858: Eval did not return a valid python object

lib version

attrs==20.1.0
coverage==5.2.1
importlib-metadata==1.7.0
iniconfig==1.0.1
more-itertools==8.4.0
packaging==20.4
pluggy==0.13.1
py==1.9.0
pyparsing==2.4.7
pytest==6.0.1
pytest-cov==2.10.1
six==1.15.0
toml==0.10.1
zipp==3.1.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions