Skip to content

Commit 9c8445e

Browse files
[STYLE] more churn for the linter (- WIP PR #454 -)
Changes in file multicast/__main__.py: * linter churn Changes in file multicast/hear.py: * linter churn Changes in file tests/context.py: * linter churn
1 parent c8894d6 commit 9c8445e

File tree

3 files changed

+19
-6
lines changed

3 files changed

+19
-6
lines changed

multicast/__main__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ def setupArgs(cls, parser):
263263
This is trivial implementation make this an optional abstract method. Subclasses may
264264
choose to implement it or leave it as a no-op.
265265
"""
266-
pass # skipcq: PTC-W0049 - optional abstract method
266+
pass # skipcq: PTC-W0049, PYL-W0107 - optional abstract method
267267

268268
@staticmethod
269269
def NoOp(*args, **kwargs):
@@ -663,7 +663,7 @@ def doStep(self, *args, **kwargs) -> tuple:
663663
1,
664664
f"CRITICAL - Attempted '[{__name__}]: {args}' just failed! :: {exit_code} {_cause}" # noqa
665665
)
666-
if (sys.stderr.isatty()):
666+
if sys.stderr.isatty():
667667
print(
668668
"WARNING - An error occurred while handling the arguments. Refused.",
669669
file=sys.stderr,

multicast/hear.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -823,7 +823,21 @@ class McastHEAR(multicast.mtool):
823823
__prologue__ = "Python Multicast Server for multicast input."
824824

825825
@classmethod
826-
def setupArgs(cls, parser): # skipcq: PY-D0003
826+
def setupArgs(cls, parser):
827+
"""
828+
Ignored for this subclass of mtool.
829+
830+
See multicast.__main__.McastRecvHearDispatch.setupArgs instead.
831+
832+
Args:
833+
parser (argparse.ArgumentParser): ignored.
834+
835+
Returns:
836+
None: This method does not return a value.
837+
838+
Note:
839+
This is trivial implementation make this an optional abstract method.
840+
"""
827841
pass # skipcq - Optional abstract method
828842

829843
def doStep(self, *args, **kwargs):

tests/context.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1102,10 +1102,9 @@ def _should_get_package_version_WHEN_valid(self) -> packaging.version.Version:
11021102
len(parsed_version.release) >= 2,
11031103
"Version must have at least major.minor components."
11041104
)
1105-
except ImportError:
1105+
except Exception:
11061106
self.fail("Failed to import the multicast package to retrieve version.")
1107-
finally:
1108-
return parsed_version
1107+
return parsed_version
11091108

11101109
@unittest.skipUnless(True, "Insanity Test. Good luck debugging.")
11111110
def test_absolute_truth_and_meaning(self) -> None:

0 commit comments

Comments
 (0)