LogosLinuxInstaller icon indicating copy to clipboard operation
LogosLinuxInstaller copied to clipboard

If Completed/Installed Config Exists but Logos EXE is Missing, Program Fails

Open thw26 opened this issue 1 year ago • 2 comments

We need code to check if the config is valid, else the program breaks. Ideally we should notify the user if the config can't find the declared install and offer either to install or prompt for the user to check their config.

Make sure config paths are relative so that the install is self-contained and can be moved freely; that is, make sure the config doesn't break if someone moves their install from their initial install dir. cf. https://github.com/FaithLife-Community/LogosLinuxInstaller/issues/13.

thw26 avatar Jul 30 '24 00:07 thw26

I ran into this while testing, and it's not clear what the precise conditions are to make this happen. In my testing I had a proper Logos Dir, etc., except that Logos itself wasn't installed within the wine prefix. The curses UI would just return to the initial screen when choosing either "Install Logos" or "Exit".

Removing the config file was the solution, but it doesn't seem to be related to bad config variables but rather something about the timing of when the config file is looked for when LLI runs. This needs more testing for sure.

n8marti avatar Aug 13 '24 13:08 n8marti

Somehow this function is probably involved:

https://github.com/FaithLife-Community/LogosLinuxInstaller/blob/b472f4f85443e5ce64f05565df2cc8133c9a4fed/tui_app.py#L525

This function is run first in tui_app line 198 and is supposed to be rerun when the install is done, see tui_app line 268.

The major issue would likely be line 268. The process of that function being:

  • Set the new Logos version subtitle line to reflect the newly installed Logos version
  • Recreate the console screen
  • Set the TUI app's main menu options, since we now have a new Logos install
  • Switch the screen from the current screen back to the main menu screen. This should be accomplished by dropping either the write new/update config screen or the install is running screen.

I would think the most likely source of problem is the last step. Perhaps the main menu screen is not properly switched to/dropped, and so the existing options are broken?

I did update the code recently to try to reset the main menu's options, as the tui app was remembering the first run of a menu's chosen option and wasn't resetting that. I'm pretty sure that needs to be done for additional/every other menu.

thw26 avatar Aug 13 '24 18:08 thw26