-
Notifications
You must be signed in to change notification settings - Fork 14
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
diff: audit #194
Closed
Closed
diff: audit #194
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This commit moves orderInfo to a subfield of the Dutch quote response to avoid continuously overloading it as a union type as we require more items in the response. It also adds the slippage tolerance field to the response :) BREAKING CHANGE: response shape
* use same nonce for synthetic * add tests * pull out util * nonce on failure of get nonce
for Dutch it is always defined because we override it with default, this commit types it this way so we dont have to do null checks in other places
This commit uses an enum for error codes. It also adds a NoQuotesAvailable custom error
* feat: cleanup slippage tolerance for Dutch it is always defined because we override it with default, this commit types it this way so we dont have to do null checks in other places * feat: make slippage tolerance a percent string This unifies it with the classic inputs * fix: remove only
This commit cleans up a few things about permitData response handling: Permits should be returned quote-level, not top-level as they apply to each quote. It's not clear from the current framing which quote the data refers to. The function for fetching permits should not be on the quote interface. Different quote types will fetch permits in different ways and require different inputs. This is already clear from the current implementation where the fn had a weird parameter that was only used by classic and completely ignored in dutch. This commit removes the field and allows each quote type to handle it however they please Move existing allowance fetch to context level. Again this is something specific to AllowanceTransfer quote types, so should be handled under the classic context rather than in the global handler Smaller changes: - remove _.isEqual in tests as it creates very unreadable logs - rename permit to permit2 where relevant
* fix: integ test the order info is now inside quote.orderInfo * remove improvement --------- Co-authored-by: ConjunctiveNormalForm <zhiyuan.zach.yang@gmail.com>
so rfq can test TODO: revert later
This commit adds requestId to the response field Closes #148
This commit adds a one-block buffer to the deadline to ensure there is always one block where the order resolves to endAmount It also returns this buffer so any consumers doing reparameterization can consume it
This commit lowers synthetic quotes so we can test fill rate in isolation of parameterization
This reverts commit 851ee48.
* feat: use gas adjustment for synthetic end amounts * fix: clean up adjustment applications Each adjustment should be applied on given values, not assuming as much about relation to the quote values
* feat: update UR-sdk This uses the latest UR address so integ tests should pass again :) * update UR addr * use addr defined in UR-SDK --------- Co-authored-by: ConjunctiveNormalForm <zhiyuan.zach.yang@gmail.com>
* add trade type and permitNonce on response * update ur sdk * slippage in classic response * exact in and out change * remove permit nonce as not needed * update consts to string * update lock file * permit first to used
* feat: properly handle pre-swap fixed costs Costs such as the user wrapping ETH into WETH before a gouda swap should not be handled like other gas adjustments since they are _required_ to be paid by the user up-front. They should be factored into the startAmount and used in the decision making process between gouda and classic * fix: add tests * fix: tests * fix: dont double count routing gas
This commit updates to gouda-sdk 1.0.0-alpha.4 and updates the code accordingly. Mostly naming changes
To allow for easier testing of ETH input TODO: REVERT!
* feat: bump default token list * reduce calls to resolveToken
* bump universal router sdk * bump sor
* feat: add timings * fix: promises * fix: add chainId * feat: add internal handler latency
* feat: changes for ETH output * remove synthetic token list check
This commit lowers the uniswapx gas threshold so we dont send orders where gas makes up over 10% of the trade size
* fix: surface routing api 5xx and 429
Co-authored-by: Siyu Jiang <siyu.jiang@CORN-Siyu-217.local>
* URA supports fastquote * address feedback
* fix: stop filtering out RFQ eth out quotes
* fix: skip flaky test * chore: use internalApiKey for integ tests
Basically to account for the UX cost of wrapping weth
* feat: fetch synthetic status from UPA This commit adds a dynamic switch-on for synthetic UniswapX quotes using the UPA enabled endpoint. It will automatically consider or reject synthetic quotes depending on the response from this endpoint * feat: add tests * feat: update api key * feat: return false default on error
* bump provisioned concurrency to 500 to match routing-api * reduce prov conc due to recent routing api change * remove old lambda env vars
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
since 050c204