Unexpected EOF While Parsing [solved]

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
ArizaLuca
Veteran
Posts: 241
Joined: Tue Feb 20, 2018 12:59 pm
Completed: Through the Screen, Riddle Me This, Trust Fall, Phobias, Another Adventure
Projects: The Souls in the Seams, Fata Morgana, Minecraft: Story Mode - Behind the Scenes
Organization: Astral Autumn Games
Tumblr: astralautumngames
Deviantart: ArizaLuca
itch: astralautumngames
Contact:

Unexpected EOF While Parsing [solved]

#1 Post by ArizaLuca »

I'm trying to make a confirm screen to continue the game; so I have this code:

Code: Select all

call screen confirm(message="Choosing this option will mean you will not be able to continue exploring. Continue anyway?", yes_action=jump alister_fireplace, no_action=jump alister_1_search)
When I try to run this line of code, this error occurs:

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/Alister.rpy", line 224, in script
    call screen confirm(message="Choosing this option will mean you will not be able to continue exploring. Continue anyway?", yes_action=jump alister_fireplace, no_action=jump alister_1_search)
  File "renpy/common/000statements.rpy", line 514, in execute_call_screen
    args, kwargs = a.evaluate()
SyntaxError: unexpected EOF while parsing (Alister.rpy, line 224)

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "game/Alister.rpy", line 224, in script
    call screen confirm(message="Choosing this option will mean you will not be able to continue exploring. Continue anyway?", yes_action=jump alister_fireplace, no_action=jump alister_1_search)
  File "/Users/arizaluca/Desktop/renpy-6.99.13-sdk/renpy/ast.py", line 1861, in execute
    self.call("execute")
  File "/Users/arizaluca/Desktop/renpy-6.99.13-sdk/renpy/ast.py", line 1849, in call
    return renpy.statements.call(method, parsed, *args, **kwargs)
  File "/Users/arizaluca/Desktop/renpy-6.99.13-sdk/renpy/statements.py", line 203, in call
    return method(parsed, *args, **kwargs)
  File "renpy/common/000statements.rpy", line 514, in execute_call_screen
    args, kwargs = a.evaluate()
  File "/Users/arizaluca/Desktop/renpy-6.99.13-sdk/renpy/ast.py", line 184, in evaluate
    kwargs[k] = renpy.python.py_eval(v, locals=scope)
  File "/Users/arizaluca/Desktop/renpy-6.99.13-sdk/renpy/python.py", line 1942, in py_eval
    code = py_compile(code, 'eval')
  File "/Users/arizaluca/Desktop/renpy-6.99.13-sdk/renpy/python.py", line 674, in py_compile
    raise e
SyntaxError: unexpected EOF while parsing (Alister.rpy, line 224)

Darwin-18.0.0-x86_64-i386-64bit
Ren'Py 7.1.3.1092
DollGame 1.0
Mon Feb  4 21:45:18 2019
Any help?
Last edited by ArizaLuca on Tue Feb 05, 2019 9:50 am, edited 1 time in total.

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3792
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Unexpected EOF While Parsing

#2 Post by Imperf3kt »

Check your file for any errant "

EOF means end of file, and is most likely caused by one too many or too few "

This link might help.
https://www.codecademy.com/en/forum_que ... da610009b5
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

User avatar
IrinaLazareva
Veteran
Posts: 399
Joined: Wed Jun 08, 2016 1:49 pm
Projects: Legacy
Organization: SunShI
Location: St.Petersburg, Russia
Contact:

Re: Unexpected EOF While Parsing

#3 Post by IrinaLazareva »

yes_action and no_action are screen actions() not control flow.

https://renpy.org/doc/html/screen_actio ... ol-actions

so

Code: Select all

    call screen confirm(message="Choosing this option will mean you will not be able to continue exploring. Continue anyway?", 
        yes_action=Jump('alister_fireplace'), 
        no_action=Jump('alister_1_search')
        )

ArizaLuca
Veteran
Posts: 241
Joined: Tue Feb 20, 2018 12:59 pm
Completed: Through the Screen, Riddle Me This, Trust Fall, Phobias, Another Adventure
Projects: The Souls in the Seams, Fata Morgana, Minecraft: Story Mode - Behind the Scenes
Organization: Astral Autumn Games
Tumblr: astralautumngames
Deviantart: ArizaLuca
itch: astralautumngames
Contact:

Re: Unexpected EOF While Parsing

#4 Post by ArizaLuca »

Thank you very much!

User avatar
Bum_McFluff
Regular
Posts: 45
Joined: Sat Aug 18, 2018 8:15 pm
Contact:

Re: Unexpected EOF While Parsing [solved]

#5 Post by Bum_McFluff »

So then what does this mean? It was working, but now is not. Nothing had changed with this part of the coding since the last successful playthrough.

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/script.rpy", line 11, in script call
    call hotel_01_scene
  File "game/scripts/locations/hotel/hotel_01.rpy", line 34, in script
    z "Hi. You look lost."
SyntaxError: unexpected EOF while parsing (<none>, line 1)

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "game/script.rpy", line 11, in script call
    call hotel_01_scene
  File "game/scripts/locations/hotel/hotel_01.rpy", line 34, in script
    z "Hi. You look lost."
  File "renpy/ast.py", line 715, in execute
    renpy.exports.say(who, what, *args, **kwargs)
  File "renpy/exports.py", line 1393, in say
    who(what, *args, **kwargs)
  File "renpy/character.py", line 1176, in __call__
    who = renpy.python.py_eval(who)
  File "renpy/python.py", line 2247, in py_eval
    code = py_compile(code, 'eval')
  File "renpy/python.py", line 835, in py_compile
    raise e
SyntaxError: unexpected EOF while parsing (<none>, line 1)

Windows-10-10.0.19041
Ren'Py 7.4.4.1439
Trainer Aftermath 1.0.1
Sun May  2 14:52:55 2021
What, spy on our spy as he searches for their spy? Why not, sounds rather like fun.

User avatar
IrinaLazareva
Veteran
Posts: 399
Joined: Wed Jun 08, 2016 1:49 pm
Projects: Legacy
Organization: SunShI
Location: St.Petersburg, Russia
Contact:

Re: Unexpected EOF While Parsing [solved]

#6 Post by IrinaLazareva »

Bum_McFluff wrote: Sun May 02, 2021 12:57 am So then what does this mean? It was working, but now is not. Nothing had changed with this part of the coding since the last successful playthrough.

Code: Select all

  File "game/script.rpy", line 11, in script call
    call hotel_01_scene
  File "game/scripts/locations/hotel/hotel_01.rpy", line 34, in script
    z "Hi. You look lost."
SyntaxError: unexpected EOF while parsing (<none>, line 1)
Well, hard to say without code.
Maybe the problem is born somewhere in the area of hotel_01_scene's label...

User avatar
Bum_McFluff
Regular
Posts: 45
Joined: Sat Aug 18, 2018 8:15 pm
Contact:

Re: Unexpected EOF While Parsing [solved]

#7 Post by Bum_McFluff »

No, I found it. It was simply an extra space when I defined the character. My own fault.
What, spy on our spy as he searches for their spy? Why not, sounds rather like fun.

Post Reply

Who is online

Users browsing this forum: No registered users