Skip to content

Commit

Permalink
Merge pull request #12615 from keymanapp/fix/linux/missingDependencies
Browse files Browse the repository at this point in the history
fix(linux): properly check for missing dependencies
  • Loading branch information
ermshiperete authored Nov 5, 2024
2 parents 6f8920d + 0688c43 commit e3d5ef4
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions linux/keyman-config/km-config
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ from keyman_config import (
_, __versionwithtag__, __pkgversion__, add_standard_arguments,
are_requirements_missing, initialize_logging, initialize_sentry,
verify_dbus_running)
from keyman_config.handle_install import download_and_install_package
from keyman_config.ibus_util import verify_ibus_daemon
from keyman_config.view_installed import ViewInstalledWindow


if __name__ == '__main__':
Expand Down Expand Up @@ -50,12 +47,18 @@ if __name__ == '__main__':
logging.error('Missing requirements. Please install python3-fonttools.')
else:
dialog = Gtk.MessageDialog(
None, 0, Gtk.MessageType.ERROR,
Gtk.ButtonsType.OK, _("Missing requirements. Please install python3-fonttools."))
parent=None, flags=0, message_type=Gtk.MessageType.ERROR,
buttons=Gtk.ButtonsType.OK,
text=_("Missing requirements. Please install python3-fonttools."))
dialog.run()
dialog.destroy()
sys.exit(1)

# Add these imports only after the check for missing dependencies!
from keyman_config.handle_install import download_and_install_package
from keyman_config.ibus_util import verify_ibus_daemon
from keyman_config.view_installed import ViewInstalledWindow


logging.info('Keyman version %s %s', __versionwithtag__, __pkgversion__)

Expand Down

0 comments on commit e3d5ef4

Please sign in to comment.