Skip to content

Commit 4c60230

Browse files
committed
Update exclusions to match the API documentation generator's
1 parent 8d577ec commit 4c60230

File tree

4 files changed

+3
-115
lines changed

4 files changed

+3
-115
lines changed

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ all: $(OUTDIR)/accountability.py \
2525
$(OUTDIR)/upgrade_manager.py
2626

2727
$(OUTDIR)/accountability.py: $(call gentargets,Accountability)
28-
$(call abigen,$^) --exclude distributeRewards,finalize,setEpochPeriod >$@
28+
$(call abigen,$^) --exclude distributeRewards,finalize,handleEvent,setEpochPeriod >$@
2929

3030
$(OUTDIR)/acu.py: $(call gentargets,ACU)
3131
$(call abigen,$^) --exclude setOperator,setOracle,update >$@
@@ -46,13 +46,13 @@ $(OUTDIR)/non_stakable_vesting.py: $(call gentargets,NonStakableVesting)
4646
$(call abigen,$^) --exclude unlockTokens >$@
4747

4848
$(OUTDIR)/oracle.py: $(call gentargets,Oracle)
49-
$(call abigen,$^) --exclude finalize,setOperator,setVoters >$@
49+
$(call abigen,$^) --exclude finalize,setOperator,setVoters,vote >$@
5050

5151
$(OUTDIR)/stabilization.py: $(call gentargets,Stabilization)
5252
$(call abigen,$^) --exclude setOperator,setOracle >$@
5353

5454
$(OUTDIR)/supply_control.py: $(call gentargets,SupplyControl)
55-
$(call abigen,$^) --exclude setOperator >$@
55+
$(call abigen,$^) --exclude burn,mint,setOperator >$@
5656

5757
$(OUTDIR)/upgrade_manager.py: $(call gentargets,UpgradeManager)
5858
$(call abigen,$^) --exclude setOperator >$@

autonity/contracts/accountability.py

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -329,43 +329,6 @@ def get_validator_faults(
329329
for elem in return_value
330330
]
331331

332-
def handle_event(
333-
self,
334-
_event: Event,
335-
) -> contract.ContractFunction:
336-
"""Binding for `handleEvent` on the Accountability contract.
337-
338-
Handle an accountability event. Need to be called by a registered validator
339-
account as the treasury-linked account will be used in case of a successful
340-
slashing event. todo(youssef): rethink modifiers here, consider splitting this
341-
into multiple functions.
342-
343-
Parameters
344-
----------
345-
_event : Event
346-
347-
Returns
348-
-------
349-
web3.contract.contract.ContractFunction
350-
A contract function instance to be sent in a transaction.
351-
"""
352-
return self._contract.functions.handleEvent(
353-
(
354-
_event.chunks,
355-
_event.chunk_id,
356-
int(_event.event_type),
357-
int(_event.rule),
358-
_event.reporter,
359-
_event.offender,
360-
_event.raw_proof,
361-
_event.id,
362-
_event.block,
363-
_event.epoch,
364-
_event.reporting_block,
365-
_event.message_hash,
366-
),
367-
)
368-
369332
def slashing_history(
370333
self,
371334
key0: eth_typing.ChecksumAddress,

autonity/contracts/oracle.py

Lines changed: 0 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -335,39 +335,6 @@ def symbols(
335335
).call()
336336
return str(return_value)
337337

338-
def vote(
339-
self,
340-
_commit: int,
341-
_reports: typing.List[int],
342-
_salt: int,
343-
) -> contract.ContractFunction:
344-
"""Binding for `vote` on the Oracle contract.
345-
346-
Vote for the current period. In order to save gas, if (reports[i] ==
347-
INVALID_PRICE)g the symbols. if the validator leave consensus committee then his
348-
vote is discarded. if a validator joins the consensus committee then his first
349-
vote is not taken into account. Only allowed to vote once per round.
350-
351-
Parameters
352-
----------
353-
_commit : int
354-
hash of the new reports _reports reveal of the reports for the
355-
previous cycle. _salt slat value which was used to generate last
356-
round commitment
357-
_reports : typing.List[int]
358-
_salt : int
359-
360-
Returns
361-
-------
362-
web3.contract.contract.ContractFunction
363-
A contract function instance to be sent in a transaction.
364-
"""
365-
return self._contract.functions.vote(
366-
_commit,
367-
_reports,
368-
_salt,
369-
)
370-
371338
def vote_period(
372339
self,
373340
) -> int:

autonity/contracts/supply_control.py

Lines changed: 0 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -66,48 +66,6 @@ def available_supply(
6666
return_value = self._contract.functions.availableSupply().call()
6767
return int(return_value)
6868

69-
def burn(
70-
self,
71-
) -> contract.ContractFunction:
72-
"""Binding for `burn` on the SupplyControl contract.
73-
74-
Burn Auton by taking it out of circulation. Only the stabilizer is authorized to
75-
burn Auton.
76-
77-
Returns
78-
-------
79-
web3.contract.contract.ContractFunction
80-
A contract function instance to be sent in a transaction.
81-
"""
82-
return self._contract.functions.burn()
83-
84-
def mint(
85-
self,
86-
recipient: eth_typing.ChecksumAddress,
87-
amount: int,
88-
) -> contract.ContractFunction:
89-
"""Binding for `mint` on the SupplyControl contract.
90-
91-
Mint Auton and send it to the recipient. Only the stabilizer is authorized to
92-
mint Auton. The recipient cannot be the stabilizer or the zero address.
93-
94-
Parameters
95-
----------
96-
recipient : eth_typing.ChecksumAddress
97-
Recipient of the Auton
98-
amount : int
99-
Amount of Auton to mint (non-zero)
100-
101-
Returns
102-
-------
103-
web3.contract.contract.ContractFunction
104-
A contract function instance to be sent in a transaction.
105-
"""
106-
return self._contract.functions.mint(
107-
recipient,
108-
amount,
109-
)
110-
11169
def set_stabilizer(
11270
self,
11371
stabilizer_: eth_typing.ChecksumAddress,

0 commit comments

Comments
 (0)