File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
src/nomad_simulations/schema_packages Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 1+ from typing import TYPE_CHECKING
2+
13from nomad import utils
24from nomad .datamodel .metainfo .basesections .v2 import Entity
35from nomad .datamodel .metainfo .plot import PlotlyFigure , PlotSection
79
810logger = utils .get_logger (__name__ )
911
12+ if TYPE_CHECKING :
13+ from nomad .datamodel .metainfo import BoundLogger
14+
1015
1116class PhysicalProperty (PlotSection ):
1217 """
@@ -145,7 +150,7 @@ def _is_contribution(self) -> bool:
145150 return True
146151 return False
147152
148- def _validate_contributions_structure (self , logger ) -> bool :
153+ def _validate_contributions_structure (self , logger : 'BoundLogger' ) -> bool :
149154 """
150155 Validates that contributions do not contain nested contributions.
151156 This prevents recursive contribution structures which are not intended.
Original file line number Diff line number Diff line change 11import numpy as np
22import pytest
3+ from typing import Callable
34from nomad .datamodel import EntryArchive
45from nomad .datamodel .metainfo .plot import PlotlyFigure
56from nomad .metainfo import Quantity
@@ -101,7 +102,7 @@ def test_plotting_and_contributions(self):
101102 ],
102103 )
103104 def test_name_setting_during_normalization (
104- self , instantiator : callable , reference : str
105+ self , instantiator : Callable , reference : str
105106 ):
106107 """
107108 Test that the name is set during normalization for PhysicalProperty.
You can’t perform that action at this time.
0 commit comments