TypeError: attrib() got an unexpected keyword argument ‘convert’
调用OS库时出现了一个类似这样的错误,之后运行其他程序也总是会出现
File “/usr/local/lib/python3.7/site-packages/_pytest/tmpdir.py”, line 35, in TempPathFactory
lambda p: Path(os.path.abspath(six.text_type§))
TypeError: attrib() got an unexpected keyword argument ‘convert’
查阅stackoverflow后,发现改变pytest版本后能够解决这个问题:
pip install pytest==5.2.0