Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Armachat coding problem
#2
You forgot to post the error message. You only posted the stack trace. The error message says what happened. The stack trace says where it happened.

The error is not in label, that is just where the error causes the program to crash. The error will be in the code you selected to run. It tried to make a label but passed a bad argument.

There is no <string> file. This would be the menu option you selected. The program reads the associated file into a str, and passes that to exec()
exec(open(menu_options[selected]).read())
# filename = menu_options[selected]
# <string> = open(filename).read()
# exec(<string>)
gad969 likes this post
Reply


Messages In This Thread
Armachat coding problem - by gad969 - Mar-08-2023, 12:08 PM
RE: Armachat coding problem - by deanhystad - Mar-08-2023, 04:23 PM
RE: Armachat coding problem - by gad969 - Mar-09-2023, 04:38 PM
RE: Armachat coding problem - by deanhystad - Mar-09-2023, 05:11 PM
RE: Armachat coding problem - by gad969 - Mar-12-2023, 03:12 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Coding problem portfolio grade max70990 1 775 Dec-11-2022, 12:30 PM
Last Post: Larz60+
  coding problem from older book teddfirth 3 2,228 Mar-06-2021, 03:51 PM
Last Post: teddfirth
  Begginer coding problem wiktor 2 3,295 Jan-26-2018, 06:24 PM
Last Post: wiktor
  IR coding problem DPaul 3 2,838 Jan-09-2018, 08:02 AM
Last Post: DPaul
  new user coding problem mattkrebs 1 3,080 Mar-21-2017, 12:45 PM
Last Post: buran
  Coding problem VISHU 3 4,911 Mar-16-2017, 06:54 AM
Last Post: Larz60+
  Incredibly basic coding problem AndyF 12 8,703 Feb-11-2017, 03:52 PM
Last Post: AndyF

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020