diff --git a/plugins/inara.py b/plugins/inara.py index 5a1e18c5..dc39d530 100644 --- a/plugins/inara.py +++ b/plugins/inara.py @@ -370,25 +370,21 @@ def journal_entry( # noqa: C901, CCR001 :return: str - empty if no error, else error string. """ if not monitor.is_live_galaxy(): - # This only applies after Update 14, which as of 2022-11-27 is scheduled - # for 2022-11-29, with the game servers presumably being down around - # 09:00 - if datetime.now(timezone.utc) >= datetime.fromisoformat("2022-11-27T09:00:00+00:00"): - # Update 14 ETA has passed, so perform the check - if ( - ( - this.legacy_galaxy_last_notified is None - or (datetime.now(timezone.utc) - this.legacy_galaxy_last_notified) > timedelta(seconds=300) - ) - and config.get_int('inara_out') and not is_beta and not this.multicrew and credentials(cmdr) - ): - # LANG: The Inara API only accepts Live galaxy data, not Legacy galaxy data - logger.info(_("Inara only accepts Live galaxy data")) - # this.parent.children['status']['text'] = - this.legacy_galaxy_last_notified = datetime.now(timezone.utc) - return _("Inara only accepts Live galaxy data") + # Since Update 14 on 2022-11-29 Inara only accepts Live data. + if ( + ( + this.legacy_galaxy_last_notified is None + or (datetime.now(timezone.utc) - this.legacy_galaxy_last_notified) > timedelta(seconds=300) + ) + and config.get_int('inara_out') and not is_beta and not this.multicrew and credentials(cmdr) + ): + # LANG: The Inara API only accepts Live galaxy data, not Legacy galaxy data + logger.info(_("Inara only accepts Live galaxy data")) + # this.parent.children['status']['text'] = + this.legacy_galaxy_last_notified = datetime.now(timezone.utc) + return _("Inara only accepts Live galaxy data") - return '' + return '' should_return, new_entry = killswitch.check_killswitch('plugins.inara.journal', entry, logger) if should_return: