Change to syntax to compile?
Posted: Mon Mar 25, 2024 10:20 am
I know I've seen this in an update log somewhere, but I can't for the life of me find it now. Moving up from RenPy 8.1.3 to the latest version, I get this error in the inventory code. I think it's something to do with the way the -> format has changed and simply requires a syntax change to some lines of code, but I can't remember where I saw the fix and can't find it now. Can anyone help?
Code: Select all
I'm sorry, but an uncaught exception occurred.
While running game code:
File "game/inventory.rpy", line 676, in script
init python:
File "game/inventory.rpy", line 676, in script
init python:
File "game/inventory.rpy", line 684, in <module>
def findLast(l: list, val) -> Optional[int]:
NameError: name 'Optional' is not defined