Skip to content

Commit

Permalink
Ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
ka-sarthak committed Jan 8, 2025
1 parent ed9567e commit e1f4237
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/nomad_measurements/xrd/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ class XRDParser(MatchingParser):
"""
Parser for matching XRD files and creating instances of ELNXRayDiffraction
"""

def set_entrydata_definition(self):
self.entrydata_definition = ELNXRayDiffraction

Expand All @@ -43,7 +44,9 @@ def parse(
) -> None:
self.set_entrydata_definition()
data_file = mainfile.split('/')[-1]
entry = self.entrydata_definition.m_from_dict(self.entrydata_definition.m_def.a_template)
entry = self.entrydata_definition.m_from_dict(
self.entrydata_definition.m_def.a_template
)
entry.data_file = data_file
file_name = f'{"".join(data_file.split(".")[:-1])}.archive.json'
archive.data = RawFileXRDData(
Expand Down

0 comments on commit e1f4237

Please sign in to comment.