mirror of https://github.com/nucypher/nucypher.git
exposes new coordinator views for getParticipantProviders and isProviderParticipating
parent
9405a35b31
commit
5e834c6330
|
@ -797,6 +797,11 @@ class CoordinatorAgent(EthereumContractAgent):
|
|||
participants.append(participant)
|
||||
return participants
|
||||
|
||||
@contract_api(CONTRACT_CALL)
|
||||
def get_participant_providers(self, ritual_id: int) -> List[ChecksumAddress]:
|
||||
result = self.contract.functions.getParticipantProviders(ritual_id).call()
|
||||
return result
|
||||
|
||||
@contract_api(CONTRACT_CALL)
|
||||
def get_provider_public_key(
|
||||
self, provider: ChecksumAddress, ritual_id: int
|
||||
|
@ -827,6 +832,15 @@ class CoordinatorAgent(EthereumContractAgent):
|
|||
)
|
||||
return participant
|
||||
|
||||
@contract_api(CONTRACT_CALL)
|
||||
def is_provider_participating(
|
||||
self, ritual_id: int, provider: ChecksumAddress
|
||||
) -> bool:
|
||||
result = self.contract.functions.isProviderParticipating(
|
||||
ritual_id, provider
|
||||
).call()
|
||||
return result
|
||||
|
||||
@contract_api(CONTRACT_CALL)
|
||||
def is_encryption_authorized(
|
||||
self, ritual_id: int, evidence: bytes, ciphertext_header: bytes
|
||||
|
|
Loading…
Reference in New Issue