From 2de128e4b020ea1027c9c934362f4c8b561d1204 Mon Sep 17 00:00:00 2001 From: Vadzim Hushchanskou Date: Thu, 21 Nov 2024 14:49:31 +0300 Subject: [PATCH] Minor warning fix --- pytest_reportportal/service.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pytest_reportportal/service.py b/pytest_reportportal/service.py index 295fb61..70b0034 100644 --- a/pytest_reportportal/service.py +++ b/pytest_reportportal/service.py @@ -218,9 +218,8 @@ def _get_item_dirs(self, item: Item) -> List[str]: """ root_path = item.session.config.rootdir.strpath dir_path = item.fspath.new(basename="") - rel_dir = dir_path.new(dirname=dir_path.relto(root_path), basename="", - drive="") - return [d for d in rel_dir.parts(reverse=False) if d.basename] + rel_dir = dir_path.new(dirname=dir_path.relto(root_path), basename="", drive="") + return [str(d) for d in rel_dir.parts(reverse=False) if d.basename] def _get_tree_path(self, item: Item) -> List[Item]: """Get item of parents.