Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove deprecated #61

Merged
merged 1 commit into from
Oct 24, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions ovos_bus_client/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,24 +263,18 @@ def get_context(self, max_frames: int = None,
class Session:
def __init__(self, session_id: str = None, expiration_seconds: int = None,
active_skills: List[List[Union[str, float]]] = None,
history=None, max_time=None, max_messages=None,
utterance_states: dict = None, lang: str = None,
context: IntentContextManager = None,
valid_langs: List[str] = None,
site_id: str = "unknown",
pipeline: List[str] = None):
"""
Construct a session identifier
@param session_id: string UUID for the session
@param expiration_seconds: TTL for session (-1 for no expiration)
@param active_skills: List of list skill_id, last reference
@param history: DEPRECATED
@param max_time: DEPRECATED
@param max_messages: DEPRECATED
@param utterance_states: dict of skill_id to UtteranceState
@param lang: language associated with this Session
@param context: IntentContextManager for this Session
@param valid_langs: DEPRECATED
"""
self.session_id = session_id or str(uuid4())
self.lang = lang or get_default_lang()
Expand All @@ -305,15 +299,6 @@ def __init__(self, session_id: str = None, expiration_seconds: int = None,
]
self.context = context or IntentContextManager()

# deprecated - TODO remove 0.0.8
if history is not None or max_time is not None or max_messages is not None:
LOG.warning("valid_langs , history, max_time and max_messages have been deprecated")
self.history = [] # (Message , timestamp)
self.max_time = 5 # minutes
self.max_messages = 5
self.valid_languages = list(set([get_default_lang()] +
Configuration().get("secondary_langs", [])))

@property
def active(self) -> bool:
"""
Expand Down
Loading