If anyone is getting errors with options = options + db["encouragements"]
Try replacing it with: options = options.extend(db["encouragements"])
And if that doesn't work try: options += db["encouragements"]
File "main.py", line 63, in on_message await message.channel.send(random.choice(options)) File "/usr/lib/python3.8/random.py", line 288, in choice i = self._randbelow(len(seq))TypeError: object of type 'NoneType' has no len()
anyone has this issue?
helppp i dont know how
"WARNING: This is a development server. Do not use it in a production deployment." - Uptime RobotWill this be an issue, once our bot crosses 100+ servers and reaches the verification stage.
[SolverProblemError]Because replit (3.0.0) depends on flask (>=1.1.2,<2.0.0) and no versions of replit match >3.0.0,<4.0.0, replit (>=3.0.0,<4.0.0) requires flask (>=1.1.2,<2.0.0).So, because repl-python3-botibo2 depends on both replit (^3.0.0) and flask (^2.0.0), version solving failed.exit status 1Repl.it: Package operation failed.
Hello guys, I have a problem like tihs.Could someone help me?
Ignoring exception in on_messageTraceback (most recent call last): File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 343, in _run_event await coro(*args, **kwargs) File "main.py", line 58, in on_message options = options + db["encouragements"]TypeError: can only concatenate list (not "ObservedList") to list
whenever, I try to delete a encouraging messsage $del 0 the following ObservedList(value=) has been appearing in my server instead of showing what got deleted which should be something like this ['You are amazing.', 'You are so amazing and cool.'] . did any encounter this type of situation ? can you please help how to solve this ?
The quote part is not working anymore for some reason.. it doesn't return any error but it doesn't return a quote either when I type "$inspire"; I copied that part of the code from here to make sure and It still didn't work.
Hi Beau! Thank you for the tutorial, it was super helpful and I learned a lot from your video! I have been trying to create my own version of the bot using the Evil Insult Generator, but I have no idea how to implement it here to this code. https://evilinsult.com/api/ any advise would really help!
When I type $list I see this:ObservedList(value=['You are amazing.', 'You are so amazing and cool.', 'You are the doing great, keep your head up!'])
instead of just:['You are amazing.', 'You are so amazing and cool.', 'You are the doing great, keep your head up!']
any tips to help fix this?
Okay, those guys who cant get their tokens correct, first go left bar and click on lock icon [Secrets(Environment Variables)]. it will ask for token name and key. Paste the copied key in key section and give token name as TOKEN(you can choose any name here). after that it import os and add the following line client.run(os.environ['TOKEN']) It will work
How to fix this error? Do anyone have any idea? I need Urgent Help!
Ignoring exception in on_messageTraceback (most recent call last): File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord/client.py", line 343, in _run_event await coro(*args, **kwargs) File "main.py", line 58, in on_message if db["responding"]: File "/opt/virtualenvs/python3/lib/python3.8/site-packages/replit/database/database.py", line 434, in getitem raw_val = self.get_raw(key) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/replit/database/database.py", line 474, in get_raw raise KeyError(key)KeyError: 'responding'
Really like your tutorial and code. Thank you so much to you and freecodecamp.(This is not a self ad. Because this is not my server. I have an error. after joining this server they solve it and by this server I started to make new customize bots. Join it if you have any problemo: https://discord.gg/V8HpbEuEtK )
hi, how do i add a second command to a bot? i added one command, and it worked fine, I added another command, and that command does not work. If someone could help me, that would be awesome! ; D
when i put the code in it says...Traceback (most recent call last):File "main.py", line 7 in from keep_alive import keep_aliveModuleNotFoundError: No module named 'keep_alive'
Can someone help?