Skip to content

Conversation

@lemunozm
Copy link
Contributor

@lemunozm lemunozm commented Oct 10, 2024

Linked to release-v2.0 branch

Currently, liquidity-pools uses Solidity 0.8.26, but in our repo, we use 0.8.28. Will this generate any issues when linking liquidity-pool stuff? Should we upgrade liquidity-pools? No

@lemunozm lemunozm self-assigned this Oct 10, 2024
@peculiarity
Copy link
Contributor

Why do you need the liquidity-pools here? Looking for a specific type? In general it's not recommended to import modules.
Also you can remove solc-version and foundry should default to using auto_detect_solc ( by default it should be true and if not you can explicitly set it to true )

@lemunozm lemunozm force-pushed the liquidity-pools-dep branch from ff6b139 to f579931 Compare October 10, 2024 08:52
@lemunozm
Copy link
Contributor Author

lemunozm commented Oct 10, 2024

Probably @hieronx can rationale this better.

But TLDR. We will use some contracts already maintained by liquidity-pools as MathLib or Auth.

Maybe a more correct solution is to factorize some common centrifuge libraries and use them from liquidity-pools and asset-pools. Because I'm not sure if explicitly, we need something of liquidity-pools itself from asset-pools

@lemunozm
Copy link
Contributor Author

lemunozm commented Oct 11, 2024

@hieronx could you give more info about my above comment?

Specially curious about whether we have this dependency because we need the common libraries from liquidity pools or if we will end up needing to call the business contract logic from liquidity-pools

@hieronx
Copy link
Contributor

hieronx commented Oct 14, 2024

Specially curious about whether we have this dependency because we need the common libraries from liquidity pools or if we will end up needing to call the business contract logic from liquidity-pools

It is both. For now, we just need the libraries (but also Auth.sol, which is not a library. And likely we'll also re-use Escrow.sol). Later though, we likely will need the interfaces from liquidity-pools as well, once we start building the interactions.

Given liquidity-pools is already audited at the current commit hash, I would use a dependency.

@lemunozm lemunozm enabled auto-merge (squash) October 14, 2024 07:40
@lemunozm lemunozm removed the request for review from ilinzweilin October 14, 2024 07:40
@lemunozm lemunozm requested review from peculiarity and removed request for peculiarity October 14, 2024 07:40
@@ -1,2 +1,3 @@
@chimera/=lib/liquidity-pools/lib/chimera/src/
forge-std/=lib/forge-std/src/
forge-gas-snapshot/=lib/forge-gas-snapshot
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this should still not be removed. Not sure why it would be. @peculiarity any ideas?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah, this shouldn't be removed @lemunozm .
I tried it locally an for some reason the command forge remappings removes it but no idea why. Will investigate further.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Could it be because it's recently archived? https://github.com/marktoda/forge-gas-snapshot

Copy link
Contributor Author

Choose a reason for hiding this comment

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

At least git submodule update --init --recursive no longer download that repo under lib/

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah cool, it was upstreamed foundry-rs/foundry#8952

Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure if that is the reason why, but it does mean we can remove the dependency, and rather just update foundry and use that going forward!

In that case, can you also remove the submodule?

Copy link
Contributor

Choose a reason for hiding this comment

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

https://github.com/marktoda/forge-gas-snapshot?tab=readme-ov-file - this is deprecated anyways. So probably we can remove it anyways .

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done. I've also called this again forge remappings > remappings.txt but with all submodules downloaded recursively

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If that's not the correct way of do this I can revert it

Copy link
Contributor

Choose a reason for hiding this comment

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

The problem comes when manually add the entry in .gitmodules

@lemunozm lemunozm merged commit 9949e39 into main Oct 14, 2024
2 checks passed
@peculiarity peculiarity deleted the liquidity-pools-dep branch October 14, 2024 09:05
peculiarity added a commit that referenced this pull request Oct 14, 2024
peculiarity added a commit that referenced this pull request Oct 14, 2024
* Revert "Add liquidity-pools as dependency (#6)"

This reverts commit 9949e39.

* fix: Remove unnecessary dep

* fix: Disable ci coveragE

* chore: copy mathlib from lp repo

* chore: Add IAuth and Auth

* chore: Enable Coverage again

* chore: Decrease coverage limit. Must be increased later.

---------

Co-authored-by: William Freudenberger <[email protected]>
@hieronx hieronx mentioned this pull request May 17, 2025
hieronx added a commit that referenced this pull request May 21, 2025
# This is the 1st commit message:

Add author

# This is the commit message #2:

Remove unused

# This is the commit message #3:

Add base decoder

# This is the commit message #4:

Add vault decoder

# This is the commit message #5:

Rename

# This is the commit message #6:

Cleanup

# This is the commit message #7:

Add interface

# This is the commit message #8:

Start working on tests

# This is the commit message #9:

Work on tests

# This is the commit message #10:

Change

# This is the commit message #11:

Add approval

# This is the commit message #12:

Fix

# This is the commit message #13:

Fix warnings

# This is the commit message #14:

Rename, add test

# This is the commit message #15:

Add manager deployment

# This is the commit message #16:

Remove factory

# This is the commit message #17:

Add methods to reset the price overrides (#375)

* Add methods to reset the price overrides

* Remove unused imports

* Update src/vaults/BalanceSheet.sol

Co-authored-by: William Freudenberger <[email protected]>

---------

Co-authored-by: William Freudenberger <[email protected]>
# This is the commit message #18:

Rename vaults to spokes, decouple vault managers and implementations (#377)

* Rename vaults to launchpad, move token

* Move vaults

* Rename to spokes

* Fix

* Remove manager dependencies from pool manager
# This is the commit message #19:

Fix `sliceZeroPadded` (#376)

* Fix sliceZeroPadded

* Cleanup

* Fix overflow error

* Fix
# This is the commit message #20:

Remove ERC20 wrapping feature (#380)

* Remove ERC20 wrapping feature

* Fix warnings
# This is the commit message #21:

Reset price in managers after overrides (#382)

* Add reset price calls

* Snapshots
# This is the commit message #22:

Fix licenses (#383)


# This is the commit message #23:

Rename `PoolManager` to `Spoke`

# This is the commit message #24:

Modify index from MessageProofId (#381)

* modify index of proof message id

* add comment
# This is the commit message #25:

Make test work

# This is the commit message #26:

MultiAdapter (#372)

* base implementation

* apply comments

* fix tests

* fix tests

* renames

* minor rename

* fix

* rename to entrypoint and missing doc refs

* adapters interfaces in its own folder

* minor rename

* apply comments

* Helper organization

* fix legacy test failing

* factorize addUnpaidMessage
# This is the commit message #27:

custom message for updating the BSM (#387)


# This is the commit message #28:

Pass tokenWards directly to the factory once. (#390)

* Pass wards once direclty in the tokenFactory

* fix tests
# This is the commit message #29:

Fix: Correct check before disputeRecovery (#391)

* correct check before dispute recovery

* rename var
# This is the commit message #30:

Missing renames from Vaults to spoke (#388)

* VaultsDeployer and related to SpokeDeployer

* docs folder rename
# This is the commit message #31:

paths spokes to spoke (#389)


# This is the commit message #32:

Add metadata

# This is the commit message #33:

ref: improve pricing precision (#392)

* ref: improve precision of pricing calc

* tests: improve precision for roundtrip tests

* chore: revert on zero reciprocal price

* tests: add and improve edge cases, split up tests further
# This is the commit message #34:

Ref: UpdateVault as independent message (#394)

* make UpdateVault an independent message

* fix comment
# This is the commit message #35:

Add token & vault update methods (#393)

* Set up token update methods

* Fix missing slash

* Remove unused imports

* Snapshots
# This is the commit message #36:

fix transferShares issue & some minor refactors (#396)


# This is the commit message #37:

Add struct

# This is the commit message #38:

Use struct in tests

# This is the commit message #39:

Factorize merkle tree lib
hieronx added a commit that referenced this pull request Jun 18, 2025
* Add merkle proof manager

* # This is a combination of 39 commits.
# This is the 1st commit message:

Add author

# This is the commit message #2:

Remove unused

# This is the commit message #3:

Add base decoder

# This is the commit message #4:

Add vault decoder

# This is the commit message #5:

Rename

# This is the commit message #6:

Cleanup

# This is the commit message #7:

Add interface

# This is the commit message #8:

Start working on tests

# This is the commit message #9:

Work on tests

# This is the commit message #10:

Change

# This is the commit message #11:

Add approval

# This is the commit message #12:

Fix

# This is the commit message #13:

Fix warnings

# This is the commit message #14:

Rename, add test

# This is the commit message #15:

Add manager deployment

# This is the commit message #16:

Remove factory

# This is the commit message #17:

Add methods to reset the price overrides (#375)

* Add methods to reset the price overrides

* Remove unused imports

* Update src/vaults/BalanceSheet.sol

Co-authored-by: William Freudenberger <[email protected]>

---------

Co-authored-by: William Freudenberger <[email protected]>
# This is the commit message #18:

Rename vaults to spokes, decouple vault managers and implementations (#377)

* Rename vaults to launchpad, move token

* Move vaults

* Rename to spokes

* Fix

* Remove manager dependencies from pool manager
# This is the commit message #19:

Fix `sliceZeroPadded` (#376)

* Fix sliceZeroPadded

* Cleanup

* Fix overflow error

* Fix
# This is the commit message #20:

Remove ERC20 wrapping feature (#380)

* Remove ERC20 wrapping feature

* Fix warnings
# This is the commit message #21:

Reset price in managers after overrides (#382)

* Add reset price calls

* Snapshots
# This is the commit message #22:

Fix licenses (#383)


# This is the commit message #23:

Rename `PoolManager` to `Spoke`

# This is the commit message #24:

Modify index from MessageProofId (#381)

* modify index of proof message id

* add comment
# This is the commit message #25:

Make test work

# This is the commit message #26:

MultiAdapter (#372)

* base implementation

* apply comments

* fix tests

* fix tests

* renames

* minor rename

* fix

* rename to entrypoint and missing doc refs

* adapters interfaces in its own folder

* minor rename

* apply comments

* Helper organization

* fix legacy test failing

* factorize addUnpaidMessage
# This is the commit message #27:

custom message for updating the BSM (#387)


# This is the commit message #28:

Pass tokenWards directly to the factory once. (#390)

* Pass wards once direclty in the tokenFactory

* fix tests
# This is the commit message #29:

Fix: Correct check before disputeRecovery (#391)

* correct check before dispute recovery

* rename var
# This is the commit message #30:

Missing renames from Vaults to spoke (#388)

* VaultsDeployer and related to SpokeDeployer

* docs folder rename
# This is the commit message #31:

paths spokes to spoke (#389)


# This is the commit message #32:

Add metadata

# This is the commit message #33:

ref: improve pricing precision (#392)

* ref: improve precision of pricing calc

* tests: improve precision for roundtrip tests

* chore: revert on zero reciprocal price

* tests: add and improve edge cases, split up tests further
# This is the commit message #34:

Ref: UpdateVault as independent message (#394)

* make UpdateVault an independent message

* fix comment
# This is the commit message #35:

Add token & vault update methods (#393)

* Set up token update methods

* Fix missing slash

* Remove unused imports

* Snapshots
# This is the commit message #36:

fix transferShares issue & some minor refactors (#396)


# This is the commit message #37:

Add struct

# This is the commit message #38:

Use struct in tests

# This is the commit message #39:

Factorize merkle tree lib

* Add author

Remove unused

Add base decoder

Add vault decoder

Rename

Cleanup

Add interface

Start working on tests

Work on tests

Change

Add approval

Fix

Fix warnings

Rename, add test

Add manager deployment

Remove factory

Add methods to reset the price overrides (#375)

* Add methods to reset the price overrides

* Remove unused imports

* Update src/vaults/BalanceSheet.sol

Co-authored-by: William Freudenberger <[email protected]>

---------

Co-authored-by: William Freudenberger <[email protected]>

Rename vaults to spokes, decouple vault managers and implementations (#377)

* Rename vaults to launchpad, move token

* Move vaults

* Rename to spokes

* Fix

* Remove manager dependencies from pool manager

Fix `sliceZeroPadded` (#376)

* Fix sliceZeroPadded

* Cleanup

* Fix overflow error

* Fix

Remove ERC20 wrapping feature (#380)

* Remove ERC20 wrapping feature

* Fix warnings

Reset price in managers after overrides (#382)

* Add reset price calls

* Snapshots

Fix licenses (#383)

Rename `PoolManager` to `Spoke`

Modify index from MessageProofId (#381)

* modify index of proof message id

* add comment

Make test work

MultiAdapter (#372)

* base implementation

* apply comments

* fix tests

* fix tests

* renames

* minor rename

* fix

* rename to entrypoint and missing doc refs

* adapters interfaces in its own folder

* minor rename

* apply comments

* Helper organization

* fix legacy test failing

* factorize addUnpaidMessage

custom message for updating the BSM (#387)

Pass tokenWards directly to the factory once. (#390)

* Pass wards once direclty in the tokenFactory

* fix tests

Fix: Correct check before disputeRecovery (#391)

* correct check before dispute recovery

* rename var

Missing renames from Vaults to spoke (#388)

* VaultsDeployer and related to SpokeDeployer

* docs folder rename

paths spokes to spoke (#389)

Add metadata

ref: improve pricing precision (#392)

* ref: improve precision of pricing calc

* tests: improve precision for roundtrip tests

* chore: revert on zero reciprocal price

* tests: add and improve edge cases, split up tests further

Ref: UpdateVault as independent message (#394)

* make UpdateVault an independent message

* fix comment

Add token & vault update methods (#393)

* Set up token update methods

* Fix missing slash

* Remove unused imports

* Snapshots

fix transferShares issue & some minor refactors (#396)

Add struct

Use struct in tests

Factorize merkle tree lib

Fix warnings

Add author

Remove unused

Add base decoder

Add vault decoder

Rename

Cleanup

Add interface

Start working on tests

Work on tests

Change

Add approval

Fix

Fix warnings

Rename, add test

Add manager deployment

Remove factory

Add methods to reset the price overrides (#375)

* Add methods to reset the price overrides

* Remove unused imports

* Update src/vaults/BalanceSheet.sol

Co-authored-by: William Freudenberger <[email protected]>

---------

Co-authored-by: William Freudenberger <[email protected]>

Rename vaults to spokes, decouple vault managers and implementations (#377)

* Rename vaults to launchpad, move token

* Move vaults

* Rename to spokes

* Fix

* Remove manager dependencies from pool manager

Fix `sliceZeroPadded` (#376)

* Fix sliceZeroPadded

* Cleanup

* Fix overflow error

* Fix

Remove ERC20 wrapping feature (#380)

* Remove ERC20 wrapping feature

* Fix warnings

Reset price in managers after overrides (#382)

* Add reset price calls

* Snapshots

Fix licenses (#383)

Rename `PoolManager` to `Spoke`

Modify index from MessageProofId (#381)

* modify index of proof message id

* add comment

Make test work

MultiAdapter (#372)

* base implementation

* apply comments

* fix tests

* fix tests

* renames

* minor rename

* fix

* rename to entrypoint and missing doc refs

* adapters interfaces in its own folder

* minor rename

* apply comments

* Helper organization

* fix legacy test failing

* factorize addUnpaidMessage

custom message for updating the BSM (#387)

Pass tokenWards directly to the factory once. (#390)

* Pass wards once direclty in the tokenFactory

* fix tests

Fix: Correct check before disputeRecovery (#391)

* correct check before dispute recovery

* rename var

Missing renames from Vaults to spoke (#388)

* VaultsDeployer and related to SpokeDeployer

* docs folder rename

paths spokes to spoke (#389)

Add metadata

ref: improve pricing precision (#392)

* ref: improve precision of pricing calc

* tests: improve precision for roundtrip tests

* chore: revert on zero reciprocal price

* tests: add and improve edge cases, split up tests further

Ref: UpdateVault as independent message (#394)

* make UpdateVault an independent message

* fix comment

Add token & vault update methods (#393)

* Set up token update methods

* Fix missing slash

* Remove unused imports

* Snapshots

fix transferShares issue & some minor refactors (#396)

Add struct

Use struct in tests

Factorize merkle tree lib

Fix warnings

* Remove unused import

* Update README

* Implement update contract for policy updates

* Cleanup

* Rename

* Add strong typing for calls

* Fix warning

* Reorganize tests

* Implement ERC7751

* Add failure tests

* Event order

* Add Circle decoder

* Fix warnings

* Change update contract to only be callable by spoke

* Check pool id coming from spoke

* Remove unused deployer param

* Use require statement

* Remove unused imports

* Add methods for claiming cancelations

* Remove unused imports

* Format

* Add factory

* Remove balance sheet dependency

* Add check unused imports script

* Add unused import as test

* Add failure code

* Remove unused import

* ci: add import checks (#455)

* feat: add --check-order to import script, ignore cached/out files

* ci: add import checks

* fix: imports for Merkle

* Remove check-unused-imports

* Add manuel's may report

* Update license

* Add version numbers

* Add 3rd burraSec report

* Start to fix PR feedback

* Format

* Update natspec

* Update order

* chore: remove unused

---------

Co-authored-by: William Freudenberger <[email protected]>
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.

4 participants