Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#57112 - [renpy] Missing tmp directory results in the creation of broken new projects
Attached to Project:
Community Packages
Opened by Klaus Borges (spaceporn) - Tuesday, 16 January 2018, 14:46 GMT
Last edited by Maxime Gauduin (Alucryd) - Wednesday, 13 June 2018, 21:01 GMT
Opened by Klaus Borges (spaceporn) - Tuesday, 16 January 2018, 14:46 GMT
Last edited by Maxime Gauduin (Alucryd) - Wednesday, 13 June 2018, 21:01 GMT
|
DetailsDescription:
Ren'Py's built-in launcher fails when creating a project and after raising an exception leaves an incomplete new project which fails to load. The output of running renpy on a terminal shows that `/usr/share/renpy/tmp` doesn't exist; creating the missing directory with `sudo` raises a permission error. I believe the workaround relies on creating the directory via PKGBUILD and setting the correct permissions. Additional info: Exception raised with no prior steps taken: I'm sorry, but an uncaught exception occurred. While running game code: File "launcher/game/gui7.rpy", line 440, in script call call update_renpy_strings_common File "launcher/game/translations.rpy", line 310, in script python: File "launcher/game/translations.rpy", line 316, in <module> renpy.translation.extract.extract_strings_core(language, get_strings_json()) File "launcher/game/translations.rpy", line 65, in get_strings_json with open(write_test, "w"): IOError: [Errno 2] No such file or directory: u'/usr/share/renpy/tmp/writetest.txt' -- Full Traceback ------------------------------------------------------------ Full traceback: File "launcher/game/gui7.rpy", line 440, in script call call update_renpy_strings_common File "launcher/game/translations.rpy", line 310, in script python: File "/usr/share/renpy/renpy/ast.py", line 827, in execute renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store) File "/usr/share/renpy/renpy/python.py", line 1764, in py_exec_bytecode exec bytecode in globals, locals File "launcher/game/translations.rpy", line 316, in <module> renpy.translation.extract.extract_strings_core(language, get_strings_json()) File "launcher/game/translations.rpy", line 65, in get_strings_json with open(write_test, "w"): IOError: [Errno 2] No such file or directory: u'/usr/share/renpy/tmp/writetest.txt' Linux-4.14.13-1-ARCH-x86_64-with-glibc2.2.5 Ren'Py 6.99.13.2919 Ren'Py Launcher 6.99.13.2919 Exception raised after creating the missing directory with root permissions: I'm sorry, but an uncaught exception occurred. While running game code: File "launcher/game/gui7.rpy", line 440, in script call call update_renpy_strings_common File "launcher/game/translations.rpy", line 310, in script python: File "launcher/game/translations.rpy", line 316, in <module> renpy.translation.extract.extract_strings_core(language, get_strings_json()) File "launcher/game/translations.rpy", line 65, in get_strings_json with open(write_test, "w"): IOError: [Errno 13] Permission denied: u'/usr/share/renpy/tmp/writetest.txt' -- Full Traceback ------------------------------------------------------------ Full traceback: File "launcher/game/gui7.rpy", line 440, in script call call update_renpy_strings_common File "launcher/game/translations.rpy", line 310, in script python: File "/usr/share/renpy/renpy/ast.py", line 827, in execute renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store) File "/usr/share/renpy/renpy/python.py", line 1764, in py_exec_bytecode exec bytecode in globals, locals File "launcher/game/translations.rpy", line 316, in <module> renpy.translation.extract.extract_strings_core(language, get_strings_json()) File "launcher/game/translations.rpy", line 65, in get_strings_json with open(write_test, "w"): IOError: [Errno 13] Permission denied: u'/usr/share/renpy/tmp/writetest.txt' Linux-4.14.13-1-ARCH-x86_64-with-glibc2.2.5 Ren'Py 6.99.13.2919 Ren'Py Launcher 6.99.13.2919 Steps to reproduce: |
This task depends upon
Closed by Maxime Gauduin (Alucryd)
Wednesday, 13 June 2018, 21:01 GMT
Reason for closing: Fixed
Additional comments about closing: 6.99.14.3-1
Wednesday, 13 June 2018, 21:01 GMT
Reason for closing: Fixed
Additional comments about closing: 6.99.14.3-1
Please file an upstream bugreport, as this seems like incredibly wrong behavior altogether.
For reference, even though I don't have a desktop environment, my environment seems sane enough:
% echo $XDG_DATA_HOME
/home/klaus/.local/share
% echo $HOME
/home/klaus
Upon further inspection of the codebase, I found:
basedir = None [1]
Which resides on a config.py file that is imported and called on the following try block:
try:
tempdir = os.path.join(config.basedir, "tmp") [2]
I will file the bug report upstream, I left the details here since I don't know if it's necessary to re-tag this report somehow.
[1]: https://github.com/renpy/renpy/blob/c3b9db09eda159f7d99ac6c2d3eaa9830056bfd7/renpy/config.py#L383
[2]: https://github.com/renpy/renpy/blob/c3b9db09eda159f7d99ac6c2d3eaa9830056bfd7/launcher/game/translations.rpy#L53
[1] https://github.com/renpy/renpy/issues/1357#issuecomment-364270059
[2] https://github.com/renpy/renpy/commit/3846bcdeb9238eea2047dbe6098a35bde970a6ea