Skip to content

Commit

Permalink
aio.api.aspell/
Browse files Browse the repository at this point in the history
  • Loading branch information
phlax committed Feb 8, 2022
1 parent 702f0a5 commit 36dc22a
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions aio.api.aspell/aio/api/aspell/abstract/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,22 +118,14 @@ async def pipe(self):
async def listener(self):
print(f"MESSAGE RCVD: {stdout} {stderr}")

async def spellcheck(self, message):
pipe = await self.pipe
return await pipe.write(message)

async def start(self):
await self.session

async def compile_dictionary(self, dictionary):
words = ["asdfasfdafds", "cabbage"]
async def spellcheck(self, line):
session = await self.session
for word in words:
response = await session(f"{word}\n".encode("utf-8"))
if str(response[0]).strip() == "*":
print(f"{word} is a good word")
else:
print(f"{word} is a bad word")
response = await session(f"{line}\n".encode("utf-8"))
if str(response[0]).strip() != "*":
return line

async def stop(self):
pass

0 comments on commit 36dc22a

Please sign in to comment.