Skip to content

Commit

Permalink
fix: sanitize kwargs too
Browse files Browse the repository at this point in the history
  • Loading branch information
maffettone committed Apr 12, 2024
1 parent 985e59d commit 07c32bc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion bmm_agents/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,6 @@ def measurement_plan(self, relative_point: ArrayLike) -> Tuple[str, List, dict]:
*element_positions[:, 1],
*self.element_det_positions,
]
args = sanitize_doc(args) # Convert numpy types to python types

kwargs = dict(
elements=self.elements,
Expand All @@ -235,6 +234,8 @@ def measurement_plan(self, relative_point: ArrayLike) -> Tuple[str, List, dict]:
snapshots=False,
md={"relative_position": relative_point},
)
args = sanitize_doc(args) # Convert numpy types to python types
kwargs = sanitize_doc(kwargs) # Convert numpy types to python types

return "agent_move_and_measure", args, kwargs

Expand Down

0 comments on commit 07c32bc

Please sign in to comment.