mirror of
https://github.com/alexgo-io/stacks-puppet-node.git
synced 2026-04-24 03:45:38 +08:00
better error message for when we can't load a profile due to a signature mismatch
This commit is contained in:
@@ -313,13 +313,17 @@ def get_profile(name, zonefile_storage_drivers=None, profile_storage_drivers=Non
|
||||
urls=urls, drivers=profile_storage_drivers, decode=decode_profile,
|
||||
return_public_key=True
|
||||
)
|
||||
|
||||
if user_profile_res is None:
|
||||
log.error("Failed to get profile for {}".format(name))
|
||||
return {'error': 'Failed in parsing and fetching profile for {}'.format(name)}
|
||||
|
||||
user_profile = user_profile_res['data']
|
||||
user_profile_pubkey = user_profile_res['public_key']
|
||||
|
||||
except Exception as e:
|
||||
log.exception(e)
|
||||
return {'error' : 'Failure in parsing and fetching profile'}
|
||||
return {'error' : 'Failure in parsing and fetching profile for {}'.format(name)}
|
||||
|
||||
if user_profile is None or json_is_error(user_profile):
|
||||
if user_profile is None:
|
||||
|
||||
Reference in New Issue
Block a user