Closed NastyLad closed 3 years ago
There's an edge-case for if no bot token is provided in terminal, and there also isn't a token file, but I don't think that's much of a problem.
Do we need to handle that scenario? If there is no file, and you refrain from providing a token via the command line, you'd be given an error there automatically.
Errors should have been fixed now. I've tried running Sonica on my machine and it reports no errrors. I might change the code to make use of callback functions at a later time, but for now, it works according to intention.
I think current commit just ends in some error if there is neither a terminal argument nor a file. I think typer
maybe intercepts the error somehow, because when testing, the error that was previously raised from bot_token_auto()
turned into an AttributeError at bot.run(api)
, instead of the RuntimeError
that it should have been.
Initial fix for #11. Adds the possibility of excluding deez_ARL and bot_tokens from command line when starting Sonica if you have them specified in .deezerARL and .botToken files.