前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >安装allure后执行命令后报错 INTERNALERROR> AttributeError: module 'pytest' has no attribute 'allure'

安装allure后执行命令后报错 INTERNALERROR> AttributeError: module 'pytest' has no attribute 'allure'

作者头像
小黑同学
发布2020-08-17 15:27:31
1.2K0
发布2020-08-17 15:27:31
举报
文章被收录于专栏:E=mc²E=mc²

安装allure后执行命令后报错module ‘pytest’ has no attribute ‘allure’

代码语言:javascript
复制
C:\Users\Desktop\xin>pytest -s -q --alluredir report
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR> File "c:\python34\lib\site-packages\_pytest\main.py", line 199, in wrap_session
INTERNALERROR> config._do_configure()
INTERNALERROR> File "c:\python34\lib\site-packages\_pytest\config\__init__.py", line 636, in _do_configure
INTERNALERROR> self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR> File "c:\python34\lib\site-packages\pluggy\hooks.py", line 306, in call_historic
INTERNALERROR> res = self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR> File "c:\python34\lib\site-packages\pluggy\manager.py", line 68, in _hookexec
INTERNALERROR> return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR> File "c:\python34\lib\site-packages\pluggy\manager.py", line 62, in <lambda>
INTERNALERROR> firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
INTERNALERROR> File "c:\python34\lib\site-packages\pluggy\callers.py", line 208, in _multicall
INTERNALERROR> return outcome.get_result()
INTERNALERROR> File "c:\python34\lib\site-packages\pluggy\callers.py", line 80, in get_result
INTERNALERROR> raise ex[1].with_traceback(ex[2])
INTERNALERROR> File "c:\python34\lib\site-packages\pluggy\callers.py", line 187, in _multicall
INTERNALERROR> res = hook_impl.function(*args)
INTERNALERROR> File "c:\python34\lib\site-packages\allure\pytest_plugin.py", line 80, in pytest_configure
INTERNALERROR> pytest.allure._allurelistener = testlistener
INTERNALERROR> AttributeError: 'module' object has no attribute 'allure'

解决 cmd执行如下命令:

pip uninstall pytest-allure-adaptor pip install allure-pytest

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2019-06-24 ,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档