Skip to content

Commit

Permalink
Invalid class and namespace as check exceptions
Browse files Browse the repository at this point in the history
  • Loading branch information
joente committed Dec 19, 2023
1 parent e534c96 commit 01cd1a5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion lib/version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Version string. Examples:
# '3.0.0'
# '3.0.0-alpha9'
__version__ = '3.0.16-alpha1'
__version__ = '3.0.16-alpha2'
7 changes: 3 additions & 4 deletions lib/wmiquery.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,11 @@
import re
from aiowmi.query import Query
from libprobe.asset import Asset
from libprobe.exceptions import CheckException, IgnoreCheckException
from aiowmi.query import Query
from libprobe.exceptions import CheckException
from aiowmi.connection import Connection
from aiowmi.connection import Protocol as Service
from aiowmi.exceptions import WbemExInvalidClass, WbemExInvalidNamespace
from typing import List, Tuple, Dict, Optional
from typing import List, Tuple, Optional


DTYPS_NOT_NULL = {
Expand All @@ -20,7 +19,7 @@
}
QUERY_TIMEOUT = 120
QUERY_CLASS_PAT = re.compile('\s+from\s(\w+)\s?', re.IGNORECASE)


def get_class(query: str) -> str:
o = QUERY_CLASS_PAT.search(query)
Expand Down

0 comments on commit 01cd1a5

Please sign in to comment.