Skip to content

Commit

Permalink
NodeSet: a few minor code fixes (#520)
Browse files Browse the repository at this point in the history
From pylint:
NodeSet.py:63:0: C0413: Import "from ClusterShell.Defaults import config_paths, DEFAULTS" should be placed at the top of the module (wrong-import-position)
NodeSet.py:68:0: W0611: Unused RangeSetException imported from ClusterShell.RangeSet (unused-import)
NodeSet.py:69:0: W0611: Unused RangeSetPaddingError imported from ClusterShell.RangeSet (unused-import)
  • Loading branch information
thiell authored Feb 9, 2023
1 parent 56a31e5 commit b568d18
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions lib/ClusterShell/NodeSet.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,21 +54,20 @@
import string
import sys

# Python 3 compatibility
try:
basestring
except NameError:
basestring = str

from ClusterShell.Defaults import config_paths, DEFAULTS
import ClusterShell.NodeUtils as NodeUtils

# Import all RangeSet module public objects
from ClusterShell.RangeSet import RangeSet, RangeSetND, AUTOSTEP_DISABLED
from ClusterShell.RangeSet import RangeSetException, RangeSetParseError
from ClusterShell.RangeSet import RangeSetPaddingError
from ClusterShell.RangeSet import RangeSetParseError


# Python 3 compatibility
try:
basestring
except NameError:
basestring = str

# Define default GroupResolver object used by NodeSet
DEF_GROUPS_CONFIGS = config_paths('groups.conf')
ILLEGAL_GROUP_CHARS = set("@,!&^*")
Expand Down

0 comments on commit b568d18

Please # to comment.