def file_key_retire( blockchain_id, file_key, config_path=CONFIG_PATH, wallet_keys=None ):
config_dir = os.path.dirname(config_path)<EOL>url = file_url_expired_keys( blockchain_id )<EOL>proxy = blockstack_client.get_default_proxy( config_path=config_path )<EOL>old_key_bundle_res = blockstack_client.data_get( url, wallet_keys=wallet_keys, proxy=proxy )<EOL>if '<STR_LIT:error>' in old_key_bundle_res:<EOL><INDENT>log.warn('<STR_LIT>' % old_key_bundle_res['<STR_LIT:error>'])<EOL>old_key_list = []<EOL><DEDENT>else:<EOL><INDENT>old_key_list = old_key_bundle_res['<STR_LIT:data>']['<STR_LIT>']<EOL>for old_key in old_key_list:<EOL><INDENT>if old_key['<STR_LIT>'] == file_key['<STR_LIT>']:<EOL><INDENT>log.warning("<STR_LIT>" % file_key['<STR_LIT>'])<EOL>return {'<STR_LIT:status>': True}<EOL><DEDENT><DEDENT><DEDENT>old_key_list.insert(<NUM_LIT:0>, file_key )<EOL>res = blockstack_client.data_put( url, {'<STR_LIT>': old_key_list}, wallet_keys=wallet_keys, proxy=proxy )<EOL>if '<STR_LIT:error>' in res:<EOL><INDENT>log.error("<STR_LIT>" % res['<STR_LIT:error>'])<EOL>return {'<STR_LIT:error>': '<STR_LIT>'}<EOL><DEDENT>return {'<STR_LIT:status>': True}<EOL>
Retire the given key.  Move it to the head of the old key bundle list
@file_key should be data returned by file_key_lookup
Return {'status': True} on success
Return {'error': ...} on error