chore(multi-collateral): add time tick and apply interest abis#180
chore(multi-collateral): add time tick and apply interest abis#180MohammadNassar1 merged 1 commit intodevfrom
Conversation
odednaor
left a comment
There was a problem hiding this comment.
@odednaor made 1 comment.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @ishay-starkware and @MohammadNassar1).
docs/spec.md line 3360 at r1 (raw file):
6. Initialize forced action timelock with `forced_action_timelock`. 7. Initialize premium cost with `premium_cost`. 8. Initialize last system time to zero.
I suggest initializing it to the current block time.
Code quote:
Initialize last system time to zero.
odednaor
left a comment
There was a problem hiding this comment.
@odednaor made 1 comment.
Reviewable status: 0 of 1 files reviewed, 2 unresolved discussions (waiting on @ishay-starkware and @MohammadNassar1).
docs/spec.md line 3736 at r1 (raw file):
**Logic:** 1. Run validations
We still don't know if need to perform a health check or not.
e26cfce to
5597a9e
Compare
MohammadNassar1
left a comment
There was a problem hiding this comment.
@MohammadNassar1 made 2 comments.
Reviewable status: 0 of 1 files reviewed, 2 unresolved discussions (waiting on @ishay-starkware and @odednaor).
docs/spec.md line 3360 at r1 (raw file):
Previously, odednaor wrote…
I suggest initializing it to the current block time.
Done.
docs/spec.md line 3736 at r1 (raw file):
Previously, odednaor wrote…
We still don't know if need to perform a health check or not.
Added a TODO.
aa29588 to
0515883
Compare
0515883 to
9c6c7fd
Compare
9c6c7fd to
0d0999e
Compare
ishay-starkware
left a comment
There was a problem hiding this comment.
@ishay-starkware reviewed all commit messages and made 1 comment.
Reviewable status: 0 of 1 files reviewed, 3 unresolved discussions (waiting on @MohammadNassar1 and @odednaor).
docs/spec.md line 3717 at r2 (raw file):
ref self: ContractState, operator_nonce: u64, position_id: PositionId,
Let's do a list of positions?
0d0999e to
bbbc187
Compare
MohammadNassar1
left a comment
There was a problem hiding this comment.
@MohammadNassar1 made 1 comment.
Reviewable status: 0 of 1 files reviewed, 3 unresolved discussions (waiting on @ishay-starkware, @MohammadNassar1, and @odednaor).
docs/spec.md line 3717 at r2 (raw file):
Previously, ishay-starkware wrote…
Let's do a list of positions?
Done.
bbbc187 to
16d9eec
Compare
16d9eec to
e51c739
Compare
odednaor
left a comment
There was a problem hiding this comment.
@odednaor resolved 2 discussions.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @ishay-starkware and @MohammadNassar1).
e51c739 to
95f6b8f
Compare
95f6b8f to
da677a4
Compare
da677a4 to
1dec30c
Compare
8bf966e to
a13db2f
Compare
a13db2f to
559a56b
Compare
MohammadNassar1
left a comment
There was a problem hiding this comment.
@MohammadNassar1 resolved 2 discussions.
Reviewable status: 0 of 1 files reviewed, 2 unresolved discussions (waiting on @ishay-starkware and @RoeeGross).
559a56b to
0c448cb
Compare
MohammadNassar1
left a comment
There was a problem hiding this comment.
@MohammadNassar1 resolved 1 discussion.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @ishay-starkware and @RoeeGross).
0c448cb to
e833948
Compare
RoeeGross
left a comment
There was a problem hiding this comment.
@RoeeGross reviewed 1 file and all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @ishay-starkware).
ishay-starkware
left a comment
There was a problem hiding this comment.
@ishay-starkware reviewed 1 file and all commit messages, and resolved 1 discussion.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @MohammadNassar1).
Note
Adds core primitives for interest application and time management, updating storage, events, and multiple flows.
update_system_time(Time Tick) with monotonic checks; addssystem_timeto storage andTimeTickevent; constructor initializes itapply_intereststo batch-apply interest to positions; emitsInterestAppliedprocess_deposit,withdraw,transfer(sender/receiver amounts),trade,liquidate,deleverage,reduce_asset_position,redeem_from_vault,liquidate_vault_shares,invest_in_vaultDepositProcessed,Transfer,AssetPositionReduced, vault-related functions; adds range validations and timestamp updates where interest is appliedPositionstorage note on initial interest update behaviorWritten by Cursor Bugbot for commit e833948. This will update automatically on new commits. Configure here.
This change is