Skip to content

Commit

Permalink
Convert env value to boolean explicitly (#105)
Browse files Browse the repository at this point in the history
  • Loading branch information
ehclark authored Oct 22, 2024
1 parent 0806b64 commit 6251f78
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/anyvar/storage/sql_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ def __init__(
os.environ.get("ANYVAR_SQL_STORE_BATCH_LIMIT", "100000")
)
self.flush_on_batchctx_exit = (
bool(os.environ.get("ANYVAR_SQL_STORE_FLUSH_ON_BATCHCTX_EXIT", "True"))
os.environ.get("ANYVAR_SQL_STORE_FLUSH_ON_BATCHCTX_EXIT", "true").lower()
in ["true", "yes", "1"]
if flush_on_batchctx_exit is None
else flush_on_batchctx_exit
)
Expand Down

0 comments on commit 6251f78

Please sign in to comment.