[eric] browser: read-script defaults on with a kill switch; write-side stays off pending a fix

This commit is contained in:
ciregenz
2026-07-28 13:35:36 -07:00
parent c0c15b4c9c
commit c93ddf70ad
2 changed files with 3 additions and 3 deletions
@@ -54,7 +54,7 @@ P_SYSTEM = (
def read_script_enabled() -> bool:
return os.environ.get("OSW_READ_SCRIPT", "0") != "0"
return os.environ.get("OSW_READ_SCRIPT", "1") != "0"
def is_answer(reply: str) -> Optional[str]:
+2 -2
View File
@@ -95,11 +95,11 @@ def test_a_page_that_never_settles_still_answers_from_the_last_read(monkeypatch)
def test_flag_gate(monkeypatch):
monkeypatch.delenv("OSW_READ_SCRIPT", raising=False)
assert rs.read_script_enabled() is False
monkeypatch.setenv("OSW_READ_SCRIPT", "1")
assert rs.read_script_enabled() is True
monkeypatch.setenv("OSW_READ_SCRIPT", "0")
assert rs.read_script_enabled() is False
monkeypatch.setenv("OSW_READ_SCRIPT", "1")
assert rs.read_script_enabled() is True
def test_answers_from_the_staged_page():