From 32982b880bd4e76b158442e444c001f8ebd8bb06 Mon Sep 17 00:00:00 2001 From: Daniel Girtler Date: Sat, 22 Apr 2023 16:04:36 +1000 Subject: Fix import and configuration loading issues (#1764) * Fix import and configuration loading issues * Fix mypy --------- Co-authored-by: Daniel Girtler --- archinstall/lib/profile/profiles_handler.py | 44 ++++++++++++++--------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'archinstall/lib/profile') diff --git a/archinstall/lib/profile/profiles_handler.py b/archinstall/lib/profile/profiles_handler.py index 063b12ea..a8b5cc22 100644 --- a/archinstall/lib/profile/profiles_handler.py +++ b/archinstall/lib/profile/profiles_handler.py @@ -71,28 +71,28 @@ class ProfileHandler: else: self._import_profile_from_url(url_path) - if custom := profile_config.get('custom', None): - from archinstall.default_profiles.custom import CustomTypeProfile - custom_types = [] - - for entry in custom: - custom_types.append( - CustomTypeProfile( - entry['name'], - entry['enabled'], - entry.get('packages', []), - entry.get('services', []) - ) - ) - - self.remove_custom_profiles(custom_types) - self.add_custom_profiles(custom_types) - - # this doesn't mean it's actual going to be set as a selection - # but we are simply populating the custom profile with all - # possible custom definitions - if custom_profile := self.get_profile_by_name('Custom'): - custom_profile.set_current_selection(custom_types) + # if custom := profile_config.get('custom', None): + # from archinstall.default_profiles.custom import CustomTypeProfile + # custom_types = [] + # + # for entry in custom: + # custom_types.append( + # CustomTypeProfile( + # entry['name'], + # entry['enabled'], + # entry.get('packages', []), + # entry.get('services', []) + # ) + # ) + # + # self.remove_custom_profiles(custom_types) + # self.add_custom_profiles(custom_types) + # + # # this doesn't mean it's actual going to be set as a selection + # # but we are simply populating the custom profile with all + # # possible custom definitions + # if custom_profile := self.get_profile_by_name('Custom'): + # custom_profile.set_current_selection(custom_types) if main := profile_config.get('main', None): profile = self.get_profile_by_name(main) if main else None -- cgit v1.2.3-54-g00ecf