Python Forum
SyntaxError: invalid syntax at run .py
Thread Rating:
  • 1 Vote(s) - 3 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SyntaxError: invalid syntax at run .py
#9
(Aug-22-2018, 03:14 PM)tuxo9999 Wrote: i don´t understand why i can not run it because if i just write run sales.py it runs correctly, it´s when i put it in the while when it does not work

If you just put run sales.py, as you say, then it will still give an error. run doesn't mean anything in python, and will be an error always.

If you have some code that works without the while loop, please share it. It sounds like you're confusing python and shell scripts, and trying to mix them together into an unholy perl-like abomination.
Reply


Messages In This Thread
RE: SyntaxError: invalid syntax at run .py - by nilamo - Aug-22-2018, 07:42 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Invalid syntax Slome 2 2,007 May-13-2022, 08:31 PM
Last Post: Slome
  print(f"{person}:") SyntaxError: invalid syntax when running it AryaIC 11 16,502 Nov-07-2020, 10:17 AM
Last Post: snippsat
  Invalid syntax error, where? tucktuck9 2 3,447 May-03-2020, 09:40 AM
Last Post: pyzyx3qwerty
  Invalid syntax defining a dictionary? ep595 6 5,160 Nov-19-2019, 08:06 PM
Last Post: ThomasL
  Syntax Error: Invalid Syntax in a while loop sydney 1 4,118 Oct-19-2019, 01:40 AM
Last Post: jefsummers
  [split] Please help with SyntaxError: invalid syntax Mason 1 2,219 Apr-28-2019, 06:58 PM
Last Post: Yoriz
  SyntaxError: Invalid syntax in a while loop ludegrae 3 14,800 Dec-18-2018, 04:12 PM
Last Post: Larz60+
  Homework: Invalid syntax using if statements chehortop 3 3,686 Mar-01-2018, 04:38 AM
Last Post: micseydel
  invalid syntax error penlemon 4 3,877 Jan-27-2018, 02:46 PM
Last Post: sparkz_alot
  Invalid syntax: string index out of range darkreaper1959 6 6,211 Jan-22-2017, 06:24 PM
Last Post: nilamo

Forum Jump:

User Panel Messages

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