Skip to content

Commit

Permalink
Update to contact list to account for non-backward compatible changes…
Browse files Browse the repository at this point in the history
… and to multisig update to account for KeyStateRecord changes. (WebOfTrust#742)

Remove development branch from CI

Signed-off-by: pfeairheller <[email protected]>
  • Loading branch information
pfeairheller authored Apr 5, 2024
1 parent 0565d24 commit ce618b0
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
1 change: 0 additions & 1 deletion .github/workflows/python-app-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ on:
push:
branches:
- 'main'
- 'development'
pull_request:
workflow_dispatch:

Expand Down
11 changes: 9 additions & 2 deletions src/keri/app/cli/commands/contacts/list.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

from hio import help
from hio.base import doing
from keri import kering

from keri.app import connecting
from keri.app.cli.common import existing
Expand Down Expand Up @@ -53,8 +54,14 @@ def list(tymth, tock=0.0, **opts):

challenges = []
for said in valid:
exn = hby.db.exns.get(keys=(said,))
challenges.append(dict(dt=exn.ked['dt'], words=exn.ked['a']['words']))
try:
exn = hby.db.exns.get(keys=(said,))
except kering.ValidationError:
val = hby.db.getVal(db=hby.db.exns.sdb, key=hby.db.exns._tokey((said,)))
d = json.loads(bytes(val).decode("utf-8"))
challenges.append(dict(dt=d['dt'], words=d['a']['words']))
else:
challenges.append(dict(dt=exn.ked['dt'], words=exn.ked['a']['words']))

c["challenges"] = challenges

Expand Down
4 changes: 2 additions & 2 deletions src/keri/app/cli/commands/multisig/update.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ def updateDo(self, tymth, tock=0.0, **opts):
print("")

witstate = self.hab.db.ksns.get((saider.qb64,))
if witstate.sn != self.sn and witstate.ked['d'] != self.said:
print(f"Witness state ({witstate.sn}, {witstate.ked['d']}) does not match requested state.")
if int(witstate.s, 16) != self.sn and witstate.d != self.said:
print(f"Witness state ({witstate.s}, {witstate.d}) does not match requested state.")
self.remove(self.toRemove)

return
Expand Down

0 comments on commit ce618b0

Please sign in to comment.