Skip to content

Commit a94afc0

Browse files
committed
Run formatter
1 parent 7a63744 commit a94afc0

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

text_2_sql/autogen/src/autogen_text_2_sql/autogen_text_2_sql.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232

3333

3434
class AutoGenText2Sql:
35-
def __init__(self, state_store : StateStore, **kwargs):
35+
def __init__(self, state_store: StateStore, **kwargs):
3636
self.target_engine = os.environ["Text2Sql__DatabaseEngine"].upper()
3737

3838
if not state_store:

text_2_sql/autogen/src/autogen_text_2_sql/state_store.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
from abc import ABC, abstractmethod
22
from cachetools import TTLCache
33

4+
45
class StateStore(ABC):
56
@abstractmethod
67
def get_state(self, thread_id):
@@ -13,7 +14,7 @@ def save_state(self, thread_id, state):
1314

1415
class InMemoryStateStore(StateStore):
1516
def __init__(self):
16-
self.cache = TTLCache(maxsize=1000, ttl=4*60*60) # 4 hours
17+
self.cache = TTLCache(maxsize=1000, ttl=4 * 60 * 60) # 4 hours
1718

1819
def get_state(self, thread_id: str) -> dict:
1920
return self.cache.get(thread_id)

0 commit comments

Comments
 (0)