@@ -195,7 +195,7 @@ def _draw_box_plotly(fig: Any, structure: Atoms, px: Any, go: Any) -> Any:
195195 cell = get_cell (structure )
196196 data = fig .data
197197 for lines in _get_box_skeleton (cell ):
198- fig = px .line_3d (** dict (zip (["x" , "y" , "z" ], lines .T )))
198+ fig = px .line_3d (** dict (zip (["x" , "y" , "z" ], lines .T , strict = True )))
199199 fig .update_traces (line_color = "#000000" )
200200 data = fig .data + data
201201 return go .Figure (data = data )
@@ -462,7 +462,7 @@ def _plot3d(
462462 vector_color = np .ones ((len (structure ), 3 )) * vector_color
463463
464464 if vector_field is not None :
465- for arr , pos , col in zip (vector_field , positions , vector_color ):
465+ for arr , pos , col in zip (vector_field , positions , vector_color , strict = True ):
466466 view .shape .add_arrow (list (pos ), list (pos + arr ), list (col ), 0.2 )
467467
468468 if show_axes : # Add axes
@@ -689,7 +689,7 @@ def _add_colorscheme_spacefill(
689689 Returns:
690690 (nglview.NGLWidget): The modified widget.
691691 """
692- for elem , num in set (zip (elements , atomic_numbers )):
692+ for elem , num in set (zip (elements , atomic_numbers , strict = True )):
693693 view .add_spacefill (
694694 selection = "#" + elem ,
695695 radius_type = "vdw" ,
0 commit comments