checklist icon indicating copy to clipboard operation
checklist copied to clipboard

Read the 'pkl' file under Windows, prompt 'an integer is required (get type bytes)'

Open Rui-hub1 opened this issue 2 years ago • 0 comments

my read program

import checklist
from checklist.test_suite import TestSuite
suite_path = 'release_data/qqp/qqp_suite.pkl'
suite = TestSuite.from_file(suite_path)

Error reported after running the program

Traceback (most recent call last):
  File "C:\Users\Rui\Desktop\All_code\CheckList\release_data\qqp\test.py", line 4, in <module>
    suite = TestSuite.from_file(suite_path)
  File "C:\Users\Rui\Desktop\All_code\CheckList\checklist\test_suite.py", line 33, in from_file
    return load_test(path)
  File "C:\Users\Rui\Desktop\All_code\CheckList\checklist\abstract_test.py", line 13, in load_test
    return dill.load(infile)
  File "C:\ProgramData\anaconda3\envs\CheckList\lib\site-packages\dill\_dill.py", line 287, in load
    return Unpickler(file, ignore=ignore, **kwds).load()
  File "C:\ProgramData\anaconda3\envs\CheckList\lib\site-packages\dill\_dill.py", line 442, in load
    obj = StockUnpickler.load(self)
TypeError: an integer is required (got type bytes)

what I should do to solve this problem

Rui-hub1 avatar Oct 09 '23 02:10 Rui-hub1