osm_poi_matchmaker.utils.dataproviders_loader   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 13
dl 0
loc 16
rs 10
c 0
b 0
f 0
wmc 1

1 Function

Rating   Name   Duplication   Size   Complexity  
A import_module() 0 4 1
1
try:
0 ignored issues
show
introduced by
Missing module docstring
Loading history...
2
    import logging
3
    import sys
4
    import importlib
5
except ImportError as err:
6
    logging.error('Error %s import module: %s', __name__, err)
7
    logging.exception('Exception occurred')
8
9
    sys.exit(128)
10
11
12
def import_module(module_name, class_name):
0 ignored issues
show
introduced by
Missing function or method docstring
Loading history...
13
    module = importlib.import_module(module_name)
14
    load_class = getattr(module, class_name)
15
    return load_class
16