Modernize to python-3.9+ with pyupgrade (--py39-plus)

This commit is contained in:
Fabien Castan 2025-04-30 19:18:06 +02:00
parent 22b2161ddd
commit 41738f7f40
26 changed files with 148 additions and 157 deletions

View file

@ -1,5 +1,4 @@
#!/usr/bin/env python
# coding:utf-8
class MeshroomException(Exception):
@ -33,7 +32,7 @@ class UnknownNodeTypeError(GraphException):
"""
def __init__(self, nodeType, msg=None):
msg = "Unknown Node Type: " + nodeType
super(UnknownNodeTypeError, self).__init__(msg)
super().__init__(msg)
self.nodeType = nodeType
@ -42,7 +41,7 @@ class NodeUpgradeError(GraphException):
msg = f"Failed to upgrade node {nodeName}"
if details:
msg += f": {details}"
super(NodeUpgradeError, self).__init__(msg)
super().__init__(msg)
class GraphVisitMessage(GraphException):