-
Notifications
You must be signed in to change notification settings - Fork 101
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: hook-store): create bundle hooks tenderly simulation #4943
(feat: hook-store): create bundle hooks tenderly simulation #4943
Conversation
@yvesfracari is attempting to deploy a commit to the cow Team on Vercel. A member of the Team first needs to authorize it. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
apps/cowswap-frontend/src/modules/hooksStore/pure/AppliedHookItem/styled.tsx
Show resolved
Hide resolved
Hey everyone! I've refactored this to work with the However, I am wondering if the bundle simulation feature would work better on a separate page after the swap definition. I believe we should revalidate on token amount changes, but this would trigger many requests in my opinion. For now, I'm just revalidating the simulation on token and hook changes (not amounts). I look forward to your ideas. |
apps/cowswap-frontend/src/modules/hooksStore/pure/AppliedHookItem/index.tsx
Outdated
Show resolved
Hide resolved
apps/cowswap-frontend/src/modules/tenderly/hooks/useTenderlyBundleSimulation.ts
Outdated
Show resolved
Hide resolved
apps/cowswap-frontend/src/modules/tenderly/utils/bundleSimulation.ts
Outdated
Show resolved
Hide resolved
apps/cowswap-frontend/src/modules/tenderly/hooks/useTenderlyBundleSimulation.ts
Outdated
Show resolved
Hide resolved
apps/cowswap-frontend/src/modules/tenderly/hooks/useTenderlyBundleSimulation.ts
Outdated
Show resolved
Hide resolved
🚨 Potential security issues detected. Learn more about Socket for GitHub ↗︎ To accept the risk, merge this PR and you will not be notified again.
Next stepsWhat is protestware?This package is a joke, parody, or includes undocumented or hidden behavior unrelated to its primary function. Consider that consuming this package may come along with functionality unrelated to its primary purpose. What is a critical CVE?Contains a Critical Common Vulnerability and Exposure (CVE). Remove or replace dependencies that include known critical CVEs. Consumers can use dependency overrides or npm audit fix --force to remove vulnerable dependencies. Take a deeper look at the dependencyTake 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 packageIf 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 riskTo ignore an alert, reply with a comment starting with
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One more comment, otherwise looks good
apps/cowswap-frontend/src/modules/tenderly/hooks/useTenderlyBundleSimulation.ts
Outdated
Show resolved
Hide resolved
apps/cowswap-frontend/src/modules/tenderly/state/topTokenHolders.ts
Outdated
Show resolved
Hide resolved
Report too large to display inline |
Summary
Add bundle simulations on the hook store feature. This enhances the hooks simulations by considering all the previous hooks and the swap (in case of post hooks).
https://www.loom.com/share/37cf070b4f7b41f896966c469941c406?sid=c183f6f3-f611-4d2f-8d7d-0015bb8d374a
To Test
Since we still don't have a Tenderly account, it is expected to have to login on Tenderly to see the simulation links.
Run the bff locally on port 3001. For more information check: Add simulation and token holder endpoints bff#88
Change the bff connection by editing the file:
libs/common-const/src/bff.ts
. Change the default URL tohttp://localhost:3001
Run the cowswap app locally.
Go to the hooks tab of the swap widget and add some hooks.
Background
@alfetopito @shoom3301 In order to merge this PR we will have to add the .env keys. Let me know if you think that we should wait for the refactoring to the backend for the frontend repo.