You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Popis:
Spravení error handlingu z
```py
if error_handling(answers):
return await message.edit(embed=PollEmbedBase(error_handling(answers)))
```
na
```py
if len(answer) > Poll.MAX_OPTIONS:
raise TooManyOptionsError(f"Zadal jsi příliš mnoho odpovědí, můžeš maximálně {Poll.MAX_OPTIONS}!")
```
## Proč?
Zvýšení čtitelnosti, jednodušší práce s error handlingem a přehlednost.
## Co dodělat?
- [x] #16
Hlavní pull-request na to, aby se nakonec všechny věci zrecenzovaly a
byly na jednom místě, než tyto věci dáme na produkci.
Co je nového?
- #16
- #21
- #23
- #24
- Optimalizace hlasování - #29
- Vytvořena CI pipeline
Co dál dělat?
- Počkat, až bude PR #24 hotový, teprve pak můžeme kód otestovat a
mergnout ho.
Kdo si zaslouží dík?
- @Martian-0007 Díky moc! :)
Projekt nemá žádné pěkné formátování ohledně error handlingu. Příklad je v poll_command.py, kde error handling je řešen tímto:
přijít ideálně na způsob, aby to bylo řešeno
raise
keywordem, takže ideálně takto:a následně do chatu zaslalo embed s errorem.
The text was updated successfully, but these errors were encountered: