Skip to content
This repository has been archived by the owner on Jan 26, 2024. It is now read-only.

Golfed ceilDiv and LienToken #117

Merged
merged 10 commits into from
Nov 21, 2022
Merged

Golfed ceilDiv and LienToken #117

merged 10 commits into from
Nov 21, 2022

Conversation

0xgregthedev
Copy link
Contributor

No description provided.

0xgregthedev and others added 9 commits November 20, 2022 16:25
* Fix install instructions and add markdown filetree

* Cleaned up filetree
* implement testNewLienExceeds2XEpoch()

* lien duration check

* commitToLien now caps duration at 2 weeks

* privatevault commitolienfix

* add length cap on refinance

* moved timeToSecondEpochEnd into method

* minor changes

* implement _timeToSecondEndIfPublic

* remove isValidVault check in onlyVaults function

Co-authored-by: = <santiagogregoryl@gmail.com>
* replaced transferfrom with safertransferfrom

* update ierc721

Co-authored-by: Joseph Delong <joseph@delong.me>
* lien duration check

* updates requested

Co-authored-by: Joseph Delong <joseph@delong.me>
@androolloyd androolloyd changed the base branch from develop to feature/seaport November 21, 2022 16:14
@@ -198,19 +193,12 @@ contract LienToken is ERC721, ILienToken, Auth {
uint256 newLienId
) internal returns (ILienToken.Stack[] memory newStack) {
newStack = new ILienToken.Stack[](stack.length);
for (uint256 i = 0; i < stack.length; i++) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't think this works as we aren't copying the stack anymore. We need the old stack except for the position we're replacing.

@androolloyd androolloyd merged commit d9351af into feature/seaport Nov 21, 2022
@androolloyd androolloyd deleted the golfcourse branch November 21, 2022 17:39
androolloyd added a commit that referenced this pull request Nov 22, 2022
… squashed (#112)

* seaport wip

* removed AH

* latest flow to account for insights from seaport team

* fix for testCancelAuction to be correct

* seaport wip

* royalty engine added, with mock

* add updates to loan proof gen, and seaport test dpeloyer

* remove comments, disable mock for tests, needs to be fuzzed

* remove dead code

* more cleanup, mocks dynamic, use tokenID 99 for royalties enabled

* cleanup, removing dead code, and gas golfing

* golfing

* natspec update

* more natspec cleanup

* mend

more natspec cleanup

* mend

more natspec cleanup

* mend

more natspec cleanup

* add liquidation fees calculator

* updates for warping, cleanup in general

* implemented collateraltoken errors

* Fix install instructions and add markdown filetree (#116)

* Fix install instructions and add markdown filetree

* Cleaned up filetree

* cleanup

* tests passing using a combo of match and fufillment

* tests passing - v3 changes

* move match flow down so the buffer is closer to the actual bid

* fix static values for the test

* implement testNewLienExceeds2XEpoch() (#105)

* implement testNewLienExceeds2XEpoch()

* lien duration check

* commitToLien now caps duration at 2 weeks

* privatevault commitolienfix

* add length cap on refinance

* moved timeToSecondEpochEnd into method

* minor changes

* implement _timeToSecondEndIfPublic

* remove isValidVault check in onlyVaults function

Co-authored-by: = <santiagogregoryl@gmail.com>

* replaced transferfrom with safertransferfrom (#111)

* replaced transferfrom with safertransferfrom

* update ierc721

Co-authored-by: Joseph Delong <joseph@delong.me>

* implement testFinalAuctionEnd() (#115)

* Refinance update (#110)

* lien duration check

* updates requested

Co-authored-by: Joseph Delong <joseph@delong.me>

* add sdk pointer for v3 fixes

* Golfed CeilDiv🏌

* Hole 9 on LienToken

* Finished up LienToken

* Fixed syntax

* clearing house is now a beacon

* split opensea fees apart from seaport file

* remove jsons for deploying and use compiled considerations

* rather than looping the array copy it to memory then update the position with the new lien

* removed log

* Golfed ceilDiv and LienToken (#117)

* Fix install instructions and add markdown filetree (#116)

* Fix install instructions and add markdown filetree

* Cleaned up filetree

* implement testNewLienExceeds2XEpoch() (#105)

* implement testNewLienExceeds2XEpoch()

* lien duration check

* commitToLien now caps duration at 2 weeks

* privatevault commitolienfix

* add length cap on refinance

* moved timeToSecondEpochEnd into method

* minor changes

* implement _timeToSecondEndIfPublic

* remove isValidVault check in onlyVaults function

Co-authored-by: = <santiagogregoryl@gmail.com>

* replaced transferfrom with safertransferfrom (#111)

* replaced transferfrom with safertransferfrom

* update ierc721

Co-authored-by: Joseph Delong <joseph@delong.me>

* implement testFinalAuctionEnd() (#115)

* Refinance update (#110)

* lien duration check

* updates requested

Co-authored-by: Joseph Delong <joseph@delong.me>

* Golfed CeilDiv🏌

* Hole 9 on LienToken

* Finished up LienToken

* Fixed syntax

Co-authored-by: Joseph Delong <joseph@delong.me>
Co-authored-by: = <santiagogregoryl@gmail.com>
Co-authored-by: Andrew Redden <=>

* remove reserve from the code, its unused, add validate stack guard on getMaxPotentialDebt

* fixes and tests for adding liens against invalid stacks

* fix invalid rename

* getter to get opensea fee fees and payee data

* fix typo

* updates for uni v3 liquidiator to check the underlying token amounts if mins are set

* cleanup and poitner update

* liquidationInitialAsk Issue #99 (#121)

* Added reverts for invalid liquidationInitialAsks

* Added testing for liquidationInitialAsk revert cases

* fixes and tests for adding liens against invalid stacks

* fix invalid rename

* getter to get opensea fee fees and payee data

* fix typo

* Fixed expectReverts for liquidationInitialAsk cases

Co-authored-by: Andrew Redden <=>

* Feat/exceeds initial ask (#120)

* initial incorrect implementation

* maybe broken liquidationinitialask test

* fix maxpotentialdebt and added invalid hash enum

* fix liquidationinitialask

* implemented expectreverts in reverttesting

* update testhelpers

Co-authored-by: Andrew Redden <=>
Co-authored-by: Andrew Redden <opensource@andrewredden.com>

* implement testLiquidationPaymentsOverbid and testLiquidationNftTransfer (#122)

* cleanup dead code

* cleanup

* remove unused check

* remove validator asset

* cleanup and more fixes

* remove unused interface

* remove comments

* remove dead test

* update readme

* removed comments from test helper

* more nits

Co-authored-by: Andrew Redden <=>
Co-authored-by: = <santiagogregoryl@gmail.com>
Co-authored-by: Joseph Delong <joseph@delong.me>
Co-authored-by: GregTheDev <40359730+0xgregthedev@users.noreply.github.com>
Co-authored-by: GregTheDev <mapler98@gmail.com>
dangerousfood added a commit that referenced this pull request Nov 22, 2022
… squashed (#112)

* seaport wip

* removed AH

* latest flow to account for insights from seaport team

* fix for testCancelAuction to be correct

* seaport wip

* royalty engine added, with mock

* add updates to loan proof gen, and seaport test dpeloyer

* remove comments, disable mock for tests, needs to be fuzzed

* remove dead code

* more cleanup, mocks dynamic, use tokenID 99 for royalties enabled

* cleanup, removing dead code, and gas golfing

* golfing

* natspec update

* more natspec cleanup

* mend

more natspec cleanup

* mend

more natspec cleanup

* mend

more natspec cleanup

* add liquidation fees calculator

* updates for warping, cleanup in general

* implemented collateraltoken errors

* Fix install instructions and add markdown filetree (#116)

* Fix install instructions and add markdown filetree

* Cleaned up filetree

* cleanup

* tests passing using a combo of match and fufillment

* tests passing - v3 changes

* move match flow down so the buffer is closer to the actual bid

* fix static values for the test

* implement testNewLienExceeds2XEpoch() (#105)

* implement testNewLienExceeds2XEpoch()

* lien duration check

* commitToLien now caps duration at 2 weeks

* privatevault commitolienfix

* add length cap on refinance

* moved timeToSecondEpochEnd into method

* minor changes

* implement _timeToSecondEndIfPublic

* remove isValidVault check in onlyVaults function

Co-authored-by: = <santiagogregoryl@gmail.com>

* replaced transferfrom with safertransferfrom (#111)

* replaced transferfrom with safertransferfrom

* update ierc721

Co-authored-by: Joseph Delong <joseph@delong.me>

* implement testFinalAuctionEnd() (#115)

* Refinance update (#110)

* lien duration check

* updates requested

Co-authored-by: Joseph Delong <joseph@delong.me>

* add sdk pointer for v3 fixes

* Golfed CeilDiv🏌

* Hole 9 on LienToken

* Finished up LienToken

* Fixed syntax

* clearing house is now a beacon

* split opensea fees apart from seaport file

* remove jsons for deploying and use compiled considerations

* rather than looping the array copy it to memory then update the position with the new lien

* removed log

* Golfed ceilDiv and LienToken (#117)

* Fix install instructions and add markdown filetree (#116)

* Fix install instructions and add markdown filetree

* Cleaned up filetree

* implement testNewLienExceeds2XEpoch() (#105)

* implement testNewLienExceeds2XEpoch()

* lien duration check

* commitToLien now caps duration at 2 weeks

* privatevault commitolienfix

* add length cap on refinance

* moved timeToSecondEpochEnd into method

* minor changes

* implement _timeToSecondEndIfPublic

* remove isValidVault check in onlyVaults function

Co-authored-by: = <santiagogregoryl@gmail.com>

* replaced transferfrom with safertransferfrom (#111)

* replaced transferfrom with safertransferfrom

* update ierc721

Co-authored-by: Joseph Delong <joseph@delong.me>

* implement testFinalAuctionEnd() (#115)

* Refinance update (#110)

* lien duration check

* updates requested

Co-authored-by: Joseph Delong <joseph@delong.me>

* Golfed CeilDiv🏌

* Hole 9 on LienToken

* Finished up LienToken

* Fixed syntax

Co-authored-by: Joseph Delong <joseph@delong.me>
Co-authored-by: = <santiagogregoryl@gmail.com>
Co-authored-by: Andrew Redden <=>

* remove reserve from the code, its unused, add validate stack guard on getMaxPotentialDebt

* fixes and tests for adding liens against invalid stacks

* fix invalid rename

* getter to get opensea fee fees and payee data

* fix typo

* updates for uni v3 liquidiator to check the underlying token amounts if mins are set

* cleanup and poitner update

* liquidationInitialAsk Issue #99 (#121)

* Added reverts for invalid liquidationInitialAsks

* Added testing for liquidationInitialAsk revert cases

* fixes and tests for adding liens against invalid stacks

* fix invalid rename

* getter to get opensea fee fees and payee data

* fix typo

* Fixed expectReverts for liquidationInitialAsk cases

Co-authored-by: Andrew Redden <=>

* Feat/exceeds initial ask (#120)

* initial incorrect implementation

* maybe broken liquidationinitialask test

* fix maxpotentialdebt and added invalid hash enum

* fix liquidationinitialask

* implemented expectreverts in reverttesting

* update testhelpers

Co-authored-by: Andrew Redden <=>
Co-authored-by: Andrew Redden <opensource@andrewredden.com>

* implement testLiquidationPaymentsOverbid and testLiquidationNftTransfer (#122)

* cleanup dead code

* cleanup

* remove unused check

* remove validator asset

* cleanup and more fixes

* remove unused interface

* remove comments

* remove dead test

* update readme

* removed comments from test helper

* more nits

Co-authored-by: Andrew Redden <=>
Co-authored-by: = <santiagogregoryl@gmail.com>
Co-authored-by: Joseph Delong <joseph@delong.me>
Co-authored-by: GregTheDev <40359730+0xgregthedev@users.noreply.github.com>
Co-authored-by: GregTheDev <mapler98@gmail.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants