@@ -155,40 +155,28 @@ def run_activity_browser():
155155
156156
157157def run_activity_browser_no_launcher ():
158- import sys
158+ pre_flight_checks ()
159+ setup_ab_logging ()
159160
160- from activity_browser import settings , actions
161- import bw2data as bd
161+ modules = ModuleThread ()
162+ modules . run ()
162163
163164 from .ui .widgets import MainWindow , CentralTabWidget
164165 from .layouts import panes , pages
165- from .logger import setup_ab_logging
166-
167- setup_ab_logging ()
166+ from activity_browser .bwutils import AB_metadata
167+ from activity_browser import signals
168168
169169 application .main_window = MainWindow ()
170- application .main_window .setPanes ([panes .DatabasesPane , panes .ImpactCategoriesPane , panes .CalculationSetupsPane ])
171-
172170 central_widget = CentralTabWidget (application .main_window )
173171 central_widget .addTab (pages .WelcomePage (), "Welcome" )
174172 central_widget .addTab (pages .ParametersPage (), "Parameters" )
175173
176174 application .main_window .setCentralWidget (central_widget )
177175
178- if settings .ab_settings .settings :
179- from pathlib import Path
180-
181- base_dir = Path (settings .ab_settings .current_bw_dir )
182- project_name = settings .ab_settings .startup_project
183- bd .projects .change_base_directories (base_dir , project_name = project_name , update = False )
184-
185- if not bd .projects .twofive :
186- log .warning (f"Project: { bd .projects .current } is not yet BW25 compatible" )
187- actions .ProjectSwitch .set_warning_bar ()
188-
189- log .info (f"Brightway2 data directory: { bd .projects ._base_data_dir } " )
190- log .info (f"Brightway2 current project: { bd .projects .current } " )
176+ settings = SettingsThread ()
177+ settings .run ()
191178
179+ application .main_window .sync ()
192180 application .main_window .show ()
193181
194182 sys .exit (application .exec_ ())
@@ -248,5 +236,8 @@ def check_pypi_update():
248236
249237if "--no-launcher" in sys .argv :
250238 run_activity_browser_no_launcher ()
239+ elif sys .version_info [1 ] == 10 :
240+ log .info ("Running Activity Browser without launcher for Python 3.10" )
241+ run_activity_browser_no_launcher ()
251242else :
252243 run_activity_browser ()
0 commit comments