Bump hassil to 3.1.0 (#150584)

This commit is contained in:
Michael Hansen
2025-08-13 13:58:57 -05:00
committed by GitHub
parent b3d3284f5c
commit cf68214c4d
8 changed files with 16 additions and 16 deletions

View File

@@ -11,7 +11,7 @@ import time
from typing import Any, Literal, final
from hassil import Intents, recognize
from hassil.expression import Expression, ListReference, Sequence
from hassil.expression import Expression, Group, ListReference
from hassil.intents import WildcardSlotList
from homeassistant.components import conversation, media_source, stt, tts
@@ -413,7 +413,7 @@ class AssistSatelliteEntity(entity.Entity):
for intent in intents.intents.values():
for intent_data in intent.data:
for sentence in intent_data.sentences:
_collect_list_references(sentence, wildcard_names)
_collect_list_references(sentence.expression, wildcard_names)
for wildcard_name in wildcard_names:
intents.slot_lists[wildcard_name] = WildcardSlotList(wildcard_name)
@@ -727,9 +727,9 @@ class AssistSatelliteEntity(entity.Entity):
def _collect_list_references(expression: Expression, list_names: set[str]) -> None:
"""Collect list reference names recursively."""
if isinstance(expression, Sequence):
seq: Sequence = expression
for item in seq.items:
if isinstance(expression, Group):
grp: Group = expression
for item in grp.items:
_collect_list_references(item, list_names)
elif isinstance(expression, ListReference):
# {list}

View File

@@ -6,5 +6,5 @@
"documentation": "https://www.home-assistant.io/integrations/assist_satellite",
"integration_type": "entity",
"quality_scale": "internal",
"requirements": ["hassil==2.2.3"]
"requirements": ["hassil==3.1.0"]
}

View File

@@ -14,7 +14,7 @@ import re
import time
from typing import IO, Any, cast
from hassil.expression import Expression, ListReference, Sequence, TextChunk
from hassil.expression import Expression, Group, ListReference, TextChunk
from hassil.intents import (
Intents,
SlotList,
@@ -1183,7 +1183,7 @@ class DefaultAgent(ConversationEntity):
for trigger_intent in trigger_intents.intents.values():
for intent_data in trigger_intent.data:
for sentence in intent_data.sentences:
_collect_list_references(sentence, wildcard_names)
_collect_list_references(sentence.expression, wildcard_names)
for wildcard_name in wildcard_names:
trigger_intents.slot_lists[wildcard_name] = WildcardSlotList(wildcard_name)
@@ -1520,9 +1520,9 @@ def _get_match_error_response(
def _collect_list_references(expression: Expression, list_names: set[str]) -> None:
"""Collect list reference names recursively."""
if isinstance(expression, Sequence):
seq: Sequence = expression
for item in seq.items:
if isinstance(expression, Group):
grp: Group = expression
for item in grp.items:
_collect_list_references(item, list_names)
elif isinstance(expression, ListReference):
# {list}

View File

@@ -6,5 +6,5 @@
"documentation": "https://www.home-assistant.io/integrations/conversation",
"integration_type": "system",
"quality_scale": "internal",
"requirements": ["hassil==2.2.3", "home-assistant-intents==2025.7.30"]
"requirements": ["hassil==3.1.0", "home-assistant-intents==2025.7.30"]
}

View File

@@ -36,7 +36,7 @@ go2rtc-client==0.2.1
ha-ffmpeg==3.2.2
habluetooth==5.0.1
hass-nabucasa==0.111.2
hassil==2.2.3
hassil==3.1.0
home-assistant-bluetooth==1.13.1
home-assistant-frontend==20250811.0
home-assistant-intents==2025.7.30

2
requirements_all.txt generated
View File

@@ -1140,7 +1140,7 @@ hass-splunk==0.1.1
# homeassistant.components.assist_satellite
# homeassistant.components.conversation
hassil==2.2.3
hassil==3.1.0
# homeassistant.components.jewish_calendar
hdate[astral]==1.1.2

View File

@@ -998,7 +998,7 @@ hass-nabucasa==0.111.2
# homeassistant.components.assist_satellite
# homeassistant.components.conversation
hassil==2.2.3
hassil==3.1.0
# homeassistant.components.jewish_calendar
hdate[astral]==1.1.2

View File

@@ -31,7 +31,7 @@ RUN --mount=from=ghcr.io/astral-sh/uv:0.8.9,source=/uv,target=/bin/uv \
PyTurboJPEG==1.8.0 \
go2rtc-client==0.2.1 \
ha-ffmpeg==3.2.2 \
hassil==2.2.3 \
hassil==3.1.0 \
home-assistant-intents==2025.7.30 \
mutagen==1.47.0 \
pymicro-vad==1.0.1 \