Closed mabelmabelmabelmabel closed 2 years ago
um. update on the issue, the slash commands are working completely fine now (turns out i actually did have to wait an hour like the message said) but i think this still counts as a bug bc i had to rewrite config to do it, which is probably not intentional behavior
Hey there, yes I'm aware of this bug, someone reported this to me earlier today. I didn't come across this myself because I rely on the default values, so I intentionally take those settings out.
I'm working on a fix right now and I expect to upload it later tonight.
I'm having the same issue. I changed the code a bit for our own discord, we have some smaller channels where there is a user limit but the bot should get into them, so deleted that lines. Maybe a new feature? However i tried updating them, got the same error when trying to add the slash commands, i don't know if it does it automaticly if you build a docker image and run that one afterwards?
Maybe a new feature?
I actually don't understand what feature it is that you were suggesting.
As for the Docker thing, technically I can't make it so that it deploys automatically because the deployer needs the discord token.
On the docker case, you should be able to deploy it by running:
docker run -it --rm -e DISCORD_TOKEN="your_token" -e DISCORD_ENABLE_TTS_CHANNELS="true/false" moonstarx/discord-tts-bot npm run deploy
Thanks will try you suggested command in a minute
For the feature i suggest is. If you give a bot or user move users it can avoid a user limit unless stated otherwise in the code. So what i did is remove these lines.
if (channel.full) { return 'error.channel.full'; }
Ah I see, I was not aware that that happened with the move users permission.
In any case you can also avoid it by making the bot join another channel then moving it to the actual channel you want to use, though I would see how it would get annoying quick. I'll think about it because I remember that feature was made by someone else.
Also, if you try to run that command you'll still find the bug from this issue. I'm planning on updating this today at night so chances are you can try this tomorrow with an updated docker image.
This should be fixed in #62.
You should update your bot now and expect to deploy the commands without the need to change your config as a workaround.
:bug: Describe the Bug
deploying the slash command with the settings configured as in the readme gives me a bunch of errors that look like this:
TypeError: false in config for key OWNER_REPORTING does not conform to type string.
out of curiosity i tried converting it to a string with quotation marks, and it wanted a bunch of other stuff turned to strings too, so i did that, and eventually the command ran fine, but then gave me this error when i ran npm start:
TypeError: false in config for key OWNER_REPORTING does not conform to type boolean.
which makes sense, because i messed with the config, but the way it was working before didn't work either. i put it back to the way it was, and it opened and ran, but it won't recognize any slash commands, possibly because i had to change the config around to get the slash commands deployed and then put them back for the actual bot.
:pencil2: Steps to Reproduce
npm run deploy (after installing dependencies but not dev dependencies, if that matters?) in discord-tts-bot
:confused: Expected Behavior
bot lets me deploy slash commands and run it with the same config settings
:scroll: Log
uhhh i dont know, is this anything?
$ npm run deploy
C:\Users\Mabel\discord-tts-bot\node_modules\@greencoast\discord.js-extended\dist\classes\config\ConfigValidator.js:62 throw new TypeError(
${value} in config for key ${key} does not conform to type ${type}.
); ^TypeError: false in config for key OWNER_REPORTING does not conform to type string. at C:\Users\Mabel\discord-tts-bot\node_modules\@greencoast\discord.js-extended\dist\classes\config\ConfigValidator.js:62:23 at Array.forEach ()
at ConfigValidator.validate (C:\Users\Mabel\discord-tts-bot\node_modules\@greencoast\discord.js-extended\dist\classes\config\ConfigValidator.js:45:29)
at new ConfigProvider (C:\Users\Mabel\discord-tts-bot\node_modules\@greencoast\discord.js-extended\dist\classes\config\ConfigProvider.js:81:24)
at Object. (C:\Users\Mabel\discord-tts-bot\src\command-deployer.js:5:16)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
:camera: Screenshots
:question: Other Information
thank you for developing this bot and sorry if this is just me being clueless and not actually a bug