Skip to content

Commit

Permalink
fix builtins module (#276)
Browse files Browse the repository at this point in the history
  • Loading branch information
ojh6404 authored Aug 29, 2024
1 parent 8760e48 commit 29a9524
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/viser/_gui_api.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from __future__ import annotations

import builtins
import colorsys
import dataclasses
import functools
Expand Down Expand Up @@ -1242,7 +1243,7 @@ def add_slider(
"""
value: IntOrFloat = initial_value
assert max >= min
step = __builtins__.min(step, max - min)
step = builtins.min(step, max - min)
assert max >= value >= min

# GUI callbacks cast incoming values to match the type of the initial value. If
Expand Down Expand Up @@ -1325,7 +1326,7 @@ def add_multi_slider(
A handle that can be used to interact with the GUI element.
"""
assert max >= min
step = __builtins__.min(step, max - min)
step = builtins.min(step, max - min)
assert all(max >= x >= min for x in initial_value)

# GUI callbacks cast incoming values to match the type of the initial value. If
Expand Down

0 comments on commit 29a9524

Please sign in to comment.