EOF in multi line statement!!??

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sirdeltalot
    New Member
    • Jun 2008
    • 7

    EOF in multi line statement!!??

    Hi
    I keep on getting an errror saying 'EOF in multi-line statement' when i run my code. I'm just learning python and it keeps getting in the way. What could be the cause of the error?
    Thanks
    Iz
  • sirdeltalot
    New Member
    • Jun 2008
    • 7

    #2
    I found out the problem-i'd forgotten to close a pair of double brackets lol.
    BTW-why does this error stem from that?

    Comment

    • rodnaz
      New Member
      • Nov 2018
      • 3

      #3
      I found this just now and it helped me so here is my explaination as to why it happens:
      if you don't put in a final bracket eg
      self.refresh_da ta_bindings(
      """This method is called when the link is clicked"""

      would make the compiler keep looking for the closing bracket but reach the end of the file, called reaching EOF, while still looking for the closing bracket in what it thinks must be a statement running across multiple lines. Perhaps it can happen with some other types of paired symbols in the code too?
      Cheers Nigel

      Comment

      Working...