From 40939d207e2d74c014571984c5f302425b49eebc Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Thu, 26 Dec 2019 11:43:17 +0000 Subject: Added more logging --- archinstall.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/archinstall.py b/archinstall.py index 50fb161a..0bbe364b 100644 --- a/archinstall.py +++ b/archinstall.py @@ -720,12 +720,15 @@ def get_local_instructions(target): def get_instructions(target, *positionals, **kwargs): instructions = oDict() + log(f'Fetching instructions for {target}', level=4, origin='get_instructions') if get_default_gateway_linux(): try: instructions = grab_url_data('{}/{}.json'.format(args['profiles-path'], target)).decode('UTF-8') + log(f'Found net-deploy instructions for {target}', level=4, origin='get_instructions') print('[N] Found net-deploy instructions called: {}'.format(target)) except urllib.error.HTTPError: print('[N] Could not find remote instructions. Trying local instructions under ./deployments') + log(f'Could not find remote instructions. Trying local instructions under ./deployments', level=4, origin='get_instructions') isntructions = get_local_instructions(target, *positionals) else: isntructions = get_local_instructions(target, *positionals) @@ -734,10 +737,12 @@ def get_instructions(target, *positionals, **kwargs): try: instructions = json.loads(instructions, object_pairs_hook=oDict) except: + log(f'JSON syntax error in: {target}', level=4, origin='get_instructions') print('[E] JSON syntax error in {}'.format('{}/{}.json'.format(args['profiles-path'], target))) traceback.print_exc() exit(1) + log(f'Final instructions are: {instructions}', level=4, origin='get_instructions') return instructions def merge_dicts(d1, d2, before=True, overwrite=False): -- cgit v1.2.3-70-g09d2