main2
Bob Mottram 2019-10-01 13:50:06 +01:00
parent c1acbf0deb
commit 5c6ca46d8b
1 changed files with 25 additions and 29 deletions

View File

@ -993,16 +993,14 @@ def receiveAnnounce(session,handle: str,baseDir: str, \
lookupActor=postJsonObject['object']['attributedTo']
if lookupActor:
if debug:
print('DEBUG: Obtaining actor for announce post from cache '+lookupActor)
if not getPersonFromCache(baseDir,lookupActor,personCache):
print('DEBUG: retrieve actor for announce post '+lookupActor)
for tries in range(3):
print('DEBUG: Obtaining actor for announce post '+lookupActor)
for tries in range(6):
pubKey= \
getPersonPubKey(baseDir,session,lookupActor, \
personCache,debug, \
__version__,httpPrefix,domain)
if pubKey:
print('DEBUG: public key: '+str(pubKey))
print('DEBUG: public key obtained for announce: '+str(pubKey))
break
if debug:
@ -1193,15 +1191,13 @@ def obtainAvatarForReplyPost(session,baseDir: str,httpPrefix: str,domain: str,pe
if lookupActor:
if debug:
print('DEBUG: Obtaining actor for reply post '+lookupActor)
if not getPersonFromCache(baseDir,lookupActor,personCache):
print('DEBUG: retrieve actor for announce post '+lookupActor)
for tries in range(3):
for tries in range(6):
pubKey= \
getPersonPubKey(baseDir,session,lookupActor, \
personCache,debug, \
__version__,httpPrefix,domain)
if pubKey:
print('DEBUG: public key: '+str(pubKey))
print('DEBUG: public key obtained for reply: '+str(pubKey))
break
if debug: