Remove all references to pyCompatibility

- "pyCompatibility.basestring" are replaced by standard Python3 "str"
- "Sequence" and "Iterable" from "collections" are now directly imported
with "collections.abc"
This commit is contained in:
Candice Bentéjac 2022-12-05 12:40:04 +01:00
parent d2c707f6fa
commit 635f85e7fd
10 changed files with 30 additions and 56 deletions

View file

@ -1,7 +1,5 @@
#!/usr/bin/env python
# coding:utf-8
from meshroom.core import pyCompatibility
from PySide2.QtCore import QUrl, QFileInfo
from PySide2.QtCore import QObject, Slot
@ -27,7 +25,7 @@ class FilepathHelper(QObject):
Returns:
str: String representation of 'path'
"""
if not isinstance(path, (QUrl, pyCompatibility.basestring)):
if not isinstance(path, (QUrl, str)):
raise TypeError("Unexpected data type: {}".format(path.__class__))
if isinstance(path, QUrl):
path = path.toLocalFile()