Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
import json
from pathlib import Path, PureWindowsPath
import warnings

from allotropy.allotrope.models.adm.binding_affinity_analyzer.wd._2024._12.binding_affinity_analyzer import (
Model,
)
Expand Down Expand Up @@ -36,24 +32,8 @@ class CytivaBiacoreT200ControlParser(VendorParser[MapperData, Model]):
def create_data(self, named_file_contents: NamedFileContents) -> MapperData:
base_data = DictData(decode_data(named_file_contents))
data = Data.create(base_data)
mapper_data = MapperData(
return MapperData(
metadata=create_metadata(data, named_file_contents),
measurement_groups=create_measurement_groups(data),
calculated_data=create_calculated_data(data),
)
try:
unread = base_data.get_unread_deep()
original_path = named_file_contents.original_file_path
# Derive file stem robustly for both POSIX and Windows-style paths
stem = (
PureWindowsPath(original_path).stem
if "\\" in original_path and "/" not in original_path
else Path(original_path).stem
)
out_name = f"{stem}data_unread_2.json"
with open(out_name, "w", encoding="utf-8") as f:
json.dump(unread, f, ensure_ascii=False, indent=2)
except Exception as e:
# Best-effort debug artifact; do not break parsing on failure
warnings.warn(f"Failed to write unread debug file: {e!s}", stacklevel=1)
return mapper_data
Loading