2

Every time I try to run a script with pythonw instead of python, it'll show up in the task manager for a split second and then crash. I am currently working on a discord bot and have the bot message the server every time the script successfully runs, and the bot never says anything but it does when I use normal python to open it

NinjaNube008
  • 43
  • 1
  • 8

2 Answers2

1

For others who arrive here because they have the same "pythonw shows up in Task Manager briefly and then crashes" problem, it's worth noting that this will happen if you try to execute invalid Python code with pythonw.exe. No errors are displayed, but errors are displayed if you try to run invalid Python code with python.exe, as shown in this screenshot: example of difference between Python and Pythonw error handling

Doug Mahugh
  • 624
  • 6
  • 15
0

A Discord bot isn't something suitable to run with pythonw. All of the context is in the terminal. I used heroku to host my discord bot. I also used this video to help with the setup.

NinjaNube008
  • 43
  • 1
  • 8