Skip to content

Commit ddeb5e7

Browse files
committed
Another fix
1 parent b3d5b4b commit ddeb5e7

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

src/nomad_simulation_parsers/parsers/exciting/parser.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
XMLParser,
1515
)
1616
from nomad.units import ureg
17+
from nomad.utils import get_logger
1718
from nomad_simulations.schema_packages.general import Simulation
1819
from structlog.stdlib import (
1920
BoundLogger,
@@ -29,7 +30,15 @@
2930
from .info_parser import InfoFileParser
3031

3132

33+
LOGGER = get_logger(__name__)
34+
35+
3236
class InfoParser(TextParser):
37+
# TODO temporary fix for structlog unable to propagate logger
38+
@property
39+
def logger(self):
40+
return LOGGER
41+
3342
def get_xc_functionals(self, xc_type: int) -> list[dict[str, Any]]:
3443
xc_functional_map = {
3544
2: ['LDA_C_PZ', 'LDA_X_PZ'],

src/nomad_simulation_parsers/parsers/fhiaims/parser.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,11 @@
4949
LOGGER = get_logger(__name__)
5050

5151

52-
# TODO temporary fix for structlog unable to propagate logger
53-
@with_logger(logger=LOGGER)
5452
class FHIAimsOutMappingParser(TextMappingParser):
53+
# TODO temporary fix for structlog unable to propagate logger
54+
@property
55+
def logger(self):
56+
return LOGGER
5557

5658
_gw_flag_map = {
5759
'gw': 'G0W0',

0 commit comments

Comments
 (0)