Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
synesthesiam committed Jan 20, 2020
1 parent 8b82545 commit 19f8be8
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions rhasspyclient/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,9 @@ async def get_sentences(self) -> Dict[str, List[str]]:
parser = configparser.ConfigParser(
allow_no_value=True, strict=False, delimiters=["="]
)
parser.optionxform = str # case sensitive

# case sensitive
parser.optionxform = str # type: ignore
parser.read_string(await response.text())

# Group sentences by intent
Expand Down Expand Up @@ -101,8 +103,8 @@ async def get_custom_words(self) -> Dict[str, Set[str]]:
async with self.session.get(self.custom_words_url) as response:
# Group pronunciations by word
pronunciations: Dict[str, Set[str]] = defaultdict(set)
async for line in response.content:
line = line.decode().strip()
async for line_bytes in response.content:
line = line_bytes.decode().strip()

# Skip blank lines
if len(line) == 0:
Expand Down Expand Up @@ -187,7 +189,7 @@ async def text_to_intent(

# -------------------------------------------------------------------------

async def text_to_speech(self, text: str, repeat: bool = False) -> Dict[str, Any]:
async def text_to_speech(self, text: str, repeat: bool = False) -> str:
"""
Generate speech from text.
Expand Down

0 comments on commit 19f8be8

Please sign in to comment.