Skip to content

Decryption Mediator Rework#353

Merged
keithrfung merged 7 commits intointegration/stateful-refactorfrom
feature/decryption-mediator
Apr 19, 2021
Merged

Decryption Mediator Rework#353
keithrfung merged 7 commits intointegration/stateful-refactorfrom
feature/decryption-mediator

Conversation

@keithrfung
Copy link
Copy Markdown
Contributor

@keithrfung keithrfung commented Apr 9, 2021

🚨 Please review the guidelines for contributing to this repository.

Issue

Fixes #354

Description

This is the removal of the the guardians from being within the Decryption Mediator.

  • Created MEDIATOR_ID type
  • Removed ballots (multiple) in favor of only ballots (singular) methods
  • Remove AVAILABLE_GUARDIAN_ID and MISSING_GUARDIAN_ID to reduce exports
  • Add compute share methods to Guardian
  • Update tests after decryption mediator changes

Testing

The existing test suite had to be modified but the test coverage should showcase the changes.
end_to_end and decryption tests should be focused on.

@keithrfung keithrfung force-pushed the feature/decryption-mediator branch 3 times, most recently from 86c9c4d to 7db39f6 Compare April 9, 2021 18:13
@lgtm-com
Copy link
Copy Markdown

lgtm-com Bot commented Apr 9, 2021

This pull request introduces 2 alerts when merging 7db39f6 into f0659eb - view on LGTM.com

new alerts:

  • 2 for Wrong number of arguments in a call

@keithrfung keithrfung changed the title Feature/decryption mediator Decryption Mediator Rework Apr 9, 2021
@keithrfung keithrfung force-pushed the feature/decryption-mediator branch from 7db39f6 to c2f8c60 Compare April 9, 2021 20:27
@lgtm-com
Copy link
Copy Markdown

lgtm-com Bot commented Apr 9, 2021

This pull request introduces 3 alerts when merging c2f8c60 into f0659eb - view on LGTM.com

new alerts:

  • 2 for Wrong number of arguments in a call
  • 1 for Unused import

Replace methods for simpler single ballot methods that can then be iterated through. This reduces down the scope and gives individuals more flexibility on collections without the use of DataStore
Create a decryption helper to assist in explaining how to perform the decryption ceremony without the repeated code in various sections
To reduce the amount of typing here and replace with a singular name instead of adding extra types to exports
Guardian is now in charge of its own shares and uses the functional methods instead of referencing some internal methods. A guardian must perform their own shares and send to mediator
Major change to decryption mediator. The mediator now only handles the brief exchanges of shares and reconstructs the missing guardian shares. 

Missing guardians now also have to be announced separately. 

Other tests updated to match.
@keithrfung keithrfung force-pushed the feature/decryption-mediator branch from c2f8c60 to 72fa0fe Compare April 14, 2021 18:30
@keithrfung keithrfung merged commit eca4a6d into integration/stateful-refactor Apr 19, 2021
@keithrfung keithrfung deleted the feature/decryption-mediator branch April 19, 2021 19:47
@keithrfung keithrfung linked an issue Apr 20, 2021 that may be closed by this pull request
keithrfung added a commit that referenced this pull request Apr 20, 2021
* ♻️ Add MEDIATOR_ID type

* 🔥 Remove methods forcing multiplicity on ballots

Replace methods for simpler single ballot methods that can then be iterated through. This reduces down the scope and gives individuals more flexibility on collections without the use of DataStore

* ⚠️  Create a Decryption Helper

Create a decryption helper to assist in explaining how to perform the decryption ceremony without the repeated code in various sections

* ♻️ Remove available / missing name 

To reduce the amount of typing here and replace with a singular name instead of adding extra types to exports

* ✅  Update decryption test for a single ballot

* ✨ Update Guardian to perform own shares

Guardian is now in charge of its own shares and uses the functional methods instead of referencing some internal methods. A guardian must perform their own shares and send to mediator

* ✨ Update Decryption Mediator

Major change to decryption mediator. The mediator now only handles the brief exchanges of shares and reconstructs the missing guardian shares. 

Missing guardians now also have to be announced separately. 

Other tests updated to match.
keithrfung added a commit that referenced this pull request Apr 21, 2021
* ♻️ Add MEDIATOR_ID type

* 🔥 Remove methods forcing multiplicity on ballots

Replace methods for simpler single ballot methods that can then be iterated through. This reduces down the scope and gives individuals more flexibility on collections without the use of DataStore

* ⚠️  Create a Decryption Helper

Create a decryption helper to assist in explaining how to perform the decryption ceremony without the repeated code in various sections

* ♻️ Remove available / missing name 

To reduce the amount of typing here and replace with a singular name instead of adding extra types to exports

* ✅  Update decryption test for a single ballot

* ✨ Update Guardian to perform own shares

Guardian is now in charge of its own shares and uses the functional methods instead of referencing some internal methods. A guardian must perform their own shares and send to mediator

* ✨ Update Decryption Mediator

Major change to decryption mediator. The mediator now only handles the brief exchanges of shares and reconstructs the missing guardian shares. 

Missing guardians now also have to be announced separately. 

Other tests updated to match.
Remove commented lines
keithrfung added a commit that referenced this pull request Apr 21, 2021
* ♻️ Add MEDIATOR_ID type

* 🔥 Remove methods forcing multiplicity on ballots

Replace methods for simpler single ballot methods that can then be iterated through. This reduces down the scope and gives individuals more flexibility on collections without the use of DataStore

* ⚠️  Create a Decryption Helper

Create a decryption helper to assist in explaining how to perform the decryption ceremony without the repeated code in various sections

* ♻️ Remove available / missing name 

To reduce the amount of typing here and replace with a singular name instead of adding extra types to exports

* ✅  Update decryption test for a single ballot

* ✨ Update Guardian to perform own shares

Guardian is now in charge of its own shares and uses the functional methods instead of referencing some internal methods. A guardian must perform their own shares and send to mediator

* ✨ Update Decryption Mediator

Major change to decryption mediator. The mediator now only handles the brief exchanges of shares and reconstructs the missing guardian shares. 

Missing guardians now also have to be announced separately. 

Other tests updated to match.
Remove commented lines
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Decryption Rework

2 participants