Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: V4 Quoter Integration #10844

Open
wants to merge 14 commits into
base: develop
Choose a base branch
from
Open

feat: V4 Quoter Integration #10844

wants to merge 14 commits into from

Conversation

chefjackson
Copy link
Collaborator

@chefjackson chefjackson commented Oct 21, 2024


PR-Codex overview

This PR introduces support for v4 liquidity pools in the smart-router package, enhancing the routing capabilities for decentralized exchanges by adding new pool types and updating various functionalities to accommodate these changes.

Detailed summary

  • Added support for v4 pool types: V4CL and V4BIN.
  • Exported new constants and types related to v4 pools.
  • Updated interfaces and functions to handle v4 pools in routing logic.
  • Modified tests to include v4 functionality.
  • Introduced new query functions for fetching v4 candidate pools.
  • Enhanced error handling and validation for v4 routes.
  • Updated the package dependencies to include v4-sdk.

The following files were skipped due to too many changes: packages/smart-router/evm/abis/ICLQuoter.ts, packages/smart-router/evm/abis/IBinQuoter.ts, packages/smart-router/evm/abis/IBinPoolManager.ts

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Copy link

changeset-bot bot commented Oct 21, 2024

🦋 Changeset detected

Latest commit: 15035a8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 33 packages
Name Type
@pancakeswap/swap-sdk-core Minor
@pancakeswap/price-api-sdk Major
@pancakeswap/smart-router Minor
@pancakeswap/aptos-swap-sdk Patch
@pancakeswap/farms Patch
@pancakeswap/hooks Patch
@pancakeswap/pcsx-sdk Patch
@pancakeswap/routing-sdk Patch
@pancakeswap/stable-swap-sdk Patch
@pancakeswap/swap-sdk-evm Patch
@pancakeswap/sdk Patch
@pancakeswap/token-lists Patch
@pancakeswap/v2-sdk Patch
@pancakeswap/v3-sdk Patch
@pancakeswap/v4-sdk Patch
@pancakeswap/widgets-internal Patch
@pancakeswap/routing-sdk-addon-quoter Patch
@pancakeswap/routing-sdk-addon-stable-swap Patch
@pancakeswap/routing-sdk-addon-v2 Patch
@pancakeswap/routing-sdk-addon-v3 Patch
@pancakeswap/universal-router-sdk Patch
routing-api Patch
@pancakeswap/uikit Patch
games Patch
@pancakeswap/gauges Patch
@pancakeswap/ifos Patch
@pancakeswap/multicall Patch
@pancakeswap/permit2-sdk Patch
@pancakeswap/position-managers Patch
@pancakeswap/prediction Patch
@pancakeswap/tokens Patch
@pancakeswap/pools Patch
playground Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

vercel bot commented Oct 21, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
aptos-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 25, 2024 9:25am
gamification ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 25, 2024 9:25am
web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 25, 2024 9:25am
4 Skipped Deployments
Name Status Preview Comments Updated (UTC)
blog ⬜️ Ignored (Inspect) Visit Preview Oct 25, 2024 9:25am
bridge ⬜️ Ignored (Inspect) Visit Preview Oct 25, 2024 9:25am
games ⬜️ Ignored (Inspect) Visit Preview Oct 25, 2024 9:25am
uikit ⬜️ Ignored (Inspect) Visit Preview Oct 25, 2024 9:25am

Copy link

socket-security bot commented Oct 21, 2024

👍 Dependency issues cleared. Learn more about Socket for GitHub ↗︎

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

Ignoring: npm/@sentry/node@5.30.0, npm/@testing-library/react@12.1.5, npm/@parcel/watcher-wasm@2.3.0, npm/@testing-library/dom@8.20.1, npm/@testing-library/react@13.4.0, npm/@nomicfoundation/solidity-analyzer@0.1.1, npm/@reduxjs/toolkit@1.9.7, npm/@tanstack/react-query@4.36.1, npm/@tanstack/query-core@4.36.1, npm/@tanstack/query-persist-client-core@4.36.1, npm/@tanstack/react-query-devtools@4.36.1, npm/@stylelint/postcss-css-in-js@0.37.3, npm/@tinyhttp/app@1.3.0, npm/@tinyhttp/etag@1.3.0, npm/@tinyhttp/send@1.3.0, npm/@rushstack/node-core-library@3.61.0, npm/@rushstack/rig-package@0.5.1, npm/@rushstack/ts-command-line@4.17.1, npm/@storybook/components@7.5.3, npm/@storybook/csf-plugin@7.5.3, npm/@storybook/csf-tools@7.5.3, npm/@storybook/node-logger@7.5.3, npm/@storybook/theming@7.5.3, npm/@storybook/core-common@7.5.3, npm/@storybook/router@7.5.3, npm/@storybook/builder-manager@7.5.3, npm/@storybook/builder-vite@7.5.3, npm/@storybook/cli@7.5.3, npm/@storybook/codemod@7.5.3, npm/@storybook/core-server@7.5.3, npm/@storybook/react-vite@7.5.3, npm/@storybook/telemetry@7.5.3, npm/@snapshot-labs/snapshot.js@0.4.110, npm/@solana/web3.js@1.87.6, npm/@pythnetwork/price-service-client@1.8.2, npm/@nomiclabs/hardhat-etherscan@3.1.8, npm/@react-native/babel-preset@0.73.21, npm/@react-native/metro-babel-transformer@0.73.15, npm/@react-native-community/cli@12.3.6, npm/@react-native-community/cli-platform-android@12.3.6, npm/@react-native-community/cli-platform-ios@12.3.6, npm/@react-native-community/cli-clean@12.3.6, npm/@react-native-community/cli-config@12.3.6, npm/@react-native-community/cli-doctor@12.3.6, npm/@react-native-community/cli-hermes@12.3.6, npm/@react-native-community/cli-server-api@12.3.6, npm/@react-native-community/cli-tools@12.3.6, npm/@sentry/cli@2.32.1, npm/@rollup/plugin-commonjs@26.0.1, npm/@redocly/openapi-core@1.16.0, npm/@opentelemetry/instrumentation@0.52.1, npm/@opentelemetry/core@1.25.1, npm/@opentelemetry/resources@1.25.1, npm/@sentry/bundler-plugin-core@2.20.1, npm/@prisma/instrumentation@5.16.1, npm/@sentry/node@8.16.0, npm/@sentry/nextjs@8.16.0, npm/@sentry/vercel-edge@8.16.0, npm/@orbs-network/twap-ui@0.11.2, npm/@tanstack/query-core@5.52.0

View full report↗︎

Next steps

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of ecosystem/package-name@version specifiers. e.g. @SocketSecurity ignore npm/foo@1.0.0 or ignore all packages with @SocketSecurity ignore-all

@chefjackson
Copy link
Collaborator Author

@SocketSecurity ignore npm/@sentry/node@5.30.0
@SocketSecurity ignore npm/@cspotcode/source-map-support@0.8.1
@SocketSecurity ignore npm/@emotion/is-prop-valid@0.8.8
@SocketSecurity ignore npm/@emotion/use-insertion-effect-with-fallbacks@1.0.1
@SocketSecurity ignore npm/@manypkg/find-root@1.1.0
@SocketSecurity ignore npm/@manypkg/get-packages@1.1.3
@SocketSecurity ignore npm/@changesets/types@4.1.0
@SocketSecurity ignore npm/@emotion/babel-plugin@11.11.0
@SocketSecurity ignore npm/@emotion/is-prop-valid@1.2.1
@SocketSecurity ignore npm/@cypress/xvfb@1.2.4
@SocketSecurity ignore npm/@material-ui/core@4.12.4
@SocketSecurity ignore npm/@material-ui/styles@4.11.5
@SocketSecurity ignore npm/@material-ui/system@4.12.2
@SocketSecurity ignore npm/@material-ui/utils@4.11.3
@SocketSecurity ignore npm/@nicolo-ribaudo/chokidar-2@2.1.8-no-fsevents.3
@SocketSecurity ignore npm/@cypress/request@2.88.12
@SocketSecurity ignore npm/@parcel/watcher-wasm@2.3.0
@SocketSecurity ignore npm/@microsoft/tsdoc-config@0.16.2
@SocketSecurity ignore npm/@nomicfoundation/solidity-analyzer@0.1.1
@SocketSecurity ignore npm/@json-rpc-tools/provider@1.7.6
@SocketSecurity ignore npm/@json-rpc-tools/utils@1.7.6
@SocketSecurity ignore npm/@json-rpc-tools/types@1.7.6
@SocketSecurity ignore npm/@babel/register@7.22.15
@SocketSecurity ignore npm/@lit-labs/ssr-dom-shim@1.1.2
@SocketSecurity ignore npm/@motionone/vue@10.16.4
@SocketSecurity ignore npm/@gnosis.pm/safe-react-gateway-sdk@3.5.2
@SocketSecurity ignore npm/@esbuild-plugins/node-globals-polyfill@0.1.1
@SocketSecurity ignore npm/@esbuild-plugins/node-modules-polyfill@0.1.4
@SocketSecurity ignore npm/@rushstack/node-core-library@3.61.0
@SocketSecurity ignore npm/@rushstack/rig-package@0.5.1
@SocketSecurity ignore npm/@humanwhocodes/config-array@0.11.13
@SocketSecurity ignore npm/@miniflare/cli-parser@2.13.0
@SocketSecurity ignore npm/@miniflare/core@2.13.0
@SocketSecurity ignore npm/@miniflare/d1@2.13.0
@SocketSecurity ignore npm/@miniflare/http-server@2.13.0
@SocketSecurity ignore npm/@miniflare/runner-vm@2.13.0
@SocketSecurity ignore npm/@miniflare/shared@2.13.0
@SocketSecurity ignore npm/@miniflare/storage-file@2.13.0
@SocketSecurity ignore npm/@miniflare/watcher@2.13.0
@SocketSecurity ignore npm/@rushstack/ts-command-line@4.17.1
@SocketSecurity ignore npm/@eslint/eslintrc@2.1.3
@SocketSecurity ignore npm/@storybook/components@7.5.3
@SocketSecurity ignore npm/@storybook/csf-plugin@7.5.3
@SocketSecurity ignore npm/@storybook/csf-tools@7.5.3
@SocketSecurity ignore npm/@storybook/node-logger@7.5.3
@SocketSecurity ignore npm/@storybook/core-common@7.5.3
@SocketSecurity ignore npm/@storybook/builder-manager@7.5.3
@SocketSecurity ignore npm/@storybook/builder-vite@7.5.3
@SocketSecurity ignore npm/@storybook/cli@7.5.3
@SocketSecurity ignore npm/@storybook/codemod@7.5.3

@chefjackson
Copy link
Collaborator Author

@SocketSecurity ignore npm/@storybook/core-server@7.5.3
@SocketSecurity ignore npm/@floating-ui/react-dom-interactions@0.12.0
@SocketSecurity ignore npm/@ledgerhq/iframe-provider@0.4.3
@SocketSecurity ignore npm/@babel/preset-env@7.23.3
@SocketSecurity ignore npm/@snapshot-labs/snapshot.js@0.4.110
@SocketSecurity ignore npm/@solana/web3.js@1.87.6
@SocketSecurity ignore npm/@pythnetwork/price-service-client@1.8.2
@SocketSecurity ignore npm/@changesets/read@0.6.0
@SocketSecurity ignore npm/@changesets/git@3.0.0
@SocketSecurity ignore npm/@changesets/apply-release-plan@7.0.0
@SocketSecurity ignore npm/@changesets/config@3.0.0
@SocketSecurity ignore npm/@changesets/pre@2.0.0
@SocketSecurity ignore npm/@changesets/write@0.3.0
@SocketSecurity ignore npm/@changesets/cli@2.27.1
@SocketSecurity ignore npm/@nomiclabs/hardhat-etherscan@3.1.8
@SocketSecurity ignore npm/@react-native/babel-preset@0.73.21
@SocketSecurity ignore npm/@react-native/metro-babel-transformer@0.73.15
@SocketSecurity ignore npm/@mui/base@5.0.0-beta.36
@SocketSecurity ignore npm/@mui/system@5.15.9
@SocketSecurity ignore npm/@mui/utils@5.15.9
@SocketSecurity ignore npm/@mui/private-theming@5.15.9
@SocketSecurity ignore npm/@mui/styled-engine@5.15.9
@SocketSecurity ignore npm/@mui/material@5.15.10
@SocketSecurity ignore npm/@react-native-community/cli@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-platform-android@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-platform-ios@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-clean@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-config@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-doctor@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-hermes@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-server-api@12.3.6
@SocketSecurity ignore npm/@react-native-community/cli-tools@12.3.6
@SocketSecurity ignore npm/@emotion/react@11.11.4
@SocketSecurity ignore npm/@emotion/is-prop-valid@1.2.2
@SocketSecurity ignore npm/@defi.org/web3-candies@4.20.17
@SocketSecurity ignore npm/@nomicfoundation/edr@0.3.3
@SocketSecurity ignore npm/@emotion/styled@11.11.5
@SocketSecurity ignore npm/@emotion/serialize@1.1.4
@SocketSecurity ignore npm/@next/eslint-plugin-next@14.2.3
@SocketSecurity ignore npm/@sentry/cli@2.32.1
@SocketSecurity ignore npm/@rollup/plugin-commonjs@26.0.1
@SocketSecurity ignore npm/@redocly/openapi-core@1.16.0
@SocketSecurity ignore npm/@opentelemetry/instrumentation@0.52.1
@SocketSecurity ignore npm/@opentelemetry/core@1.25.1
@SocketSecurity ignore npm/@opentelemetry/resources@1.25.1
@SocketSecurity ignore npm/@sentry/bundler-plugin-core@2.20.1
@SocketSecurity ignore npm/@prisma/instrumentation@5.16.1
@SocketSecurity ignore npm/@sentry/node@8.16.0
@SocketSecurity ignore npm/@sentry/nextjs@8.16.0
@SocketSecurity ignore npm/@sentry/vercel-edge@8.16.0

@chefjackson
Copy link
Collaborator Author

@SocketSecurity ignore npm/@orbs-network/twap-ui@0.11.2
@SocketSecurity ignore npm/@metamask/sdk-communication-layer@0.28.2

@chefjackson
Copy link
Collaborator Author

@SocketSecurity ignore npm/@testing-library/react@12.1.5
@SocketSecurity ignore npm/@testing-library/dom@8.20.1
@SocketSecurity ignore npm/@testing-library/react@13.4.0
@SocketSecurity ignore npm/@reduxjs/toolkit@1.9.7
@SocketSecurity ignore npm/@tanstack/react-query@4.36.1
@SocketSecurity ignore npm/@tanstack/query-core@4.36.1
@SocketSecurity ignore npm/@tanstack/query-persist-client-core@4.36.1
@SocketSecurity ignore npm/@tanstack/react-query-devtools@4.36.1
@SocketSecurity ignore npm/@stylelint/postcss-css-in-js@0.37.3
@SocketSecurity ignore npm/@tinyhttp/app@1.3.0
@SocketSecurity ignore npm/@tinyhttp/etag@1.3.0
@SocketSecurity ignore npm/@tinyhttp/send@1.3.0
@SocketSecurity ignore npm/@storybook/theming@7.5.3
@SocketSecurity ignore npm/@storybook/router@7.5.3
@SocketSecurity ignore npm/@storybook/react-vite@7.5.3
@SocketSecurity ignore npm/@storybook/telemetry@7.5.3
@SocketSecurity ignore npm/@tanstack/query-core@5.52.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants