ci(release): publish latest release

parent 367be52f
IPFS hash of the deployment:
- CIDv0: `QmbrVRA32CDwC4dhB4NStnreoYJ2xEaX3SoMW8kU5TuE7s`
- CIDv1: `bafybeigiztmprfce7w24v25bv65hos5sz464njnrahj37irfxp255e434i`
- CIDv0: `QmdrE1xXozbrZCb5iS5iGpjWkdJh4y7iBGHqSC1rGPcH6i`
- CIDv1: `bafybeihgolhp73f4twnioaonb2dvdyu2t44mxjdqx7pvnxfb7ibcosxcam`
The latest release is always mirrored at [app.uniswap.org](https://app.uniswap.org).
......@@ -10,10 +10,15 @@ You can also access the Uniswap Interface from an IPFS gateway.
Your Uniswap settings are never remembered across different URLs.
IPFS gateways:
- https://bafybeigiztmprfce7w24v25bv65hos5sz464njnrahj37irfxp255e434i.ipfs.dweb.link/
- https://bafybeigiztmprfce7w24v25bv65hos5sz464njnrahj37irfxp255e434i.ipfs.cf-ipfs.com/
- [ipfs://QmbrVRA32CDwC4dhB4NStnreoYJ2xEaX3SoMW8kU5TuE7s/](ipfs://QmbrVRA32CDwC4dhB4NStnreoYJ2xEaX3SoMW8kU5TuE7s/)
- https://bafybeihgolhp73f4twnioaonb2dvdyu2t44mxjdqx7pvnxfb7ibcosxcam.ipfs.dweb.link/
- https://bafybeihgolhp73f4twnioaonb2dvdyu2t44mxjdqx7pvnxfb7ibcosxcam.ipfs.cf-ipfs.com/
- [ipfs://QmdrE1xXozbrZCb5iS5iGpjWkdJh4y7iBGHqSC1rGPcH6i/](ipfs://QmdrE1xXozbrZCb5iS5iGpjWkdJh4y7iBGHqSC1rGPcH6i/)
### 5.50.3 (2024-10-09)
### 5.50.4 (2024-10-10)
### Bug Fixes
* **web:** pass account to getSigner instead of using default [prod] (#12883) 688582d
web/5.50.3
\ No newline at end of file
web/5.50.4
\ No newline at end of file
......@@ -54,10 +54,8 @@ import {
import { isClassic } from 'uniswap/src/features/transactions/swap/utils/routing'
import { getClassicQuoteFromResponse } from 'uniswap/src/features/transactions/swap/utils/tradingApi'
import { createSaga } from 'uniswap/src/utils/saga'
import { errorToString } from 'utilities/src/errors'
import { percentFromFloat } from 'utilities/src/format/percent'
import { logger } from 'utilities/src/logger/logger'
import { LoggerErrorContext } from 'utilities/src/logger/types'
import { didUserReject } from 'utils/swapErrorToUserReadableMessage'
interface HandleSwapStepParams extends Omit<HandleOnChainStepParams, 'step' | 'info'> {
......@@ -208,7 +206,9 @@ function* classicSwap(
}
} catch (error) {
const displayableError = getDisplayableError(error, step)
logSwapError(displayableError, { tags: { file: 'swapSaga', function: 'classicSwap' } })
if (displayableError) {
logger.error(displayableError, { tags: { file: 'swapSaga', function: 'classicSwap' } })
}
onFailure(displayableError)
return
}
......@@ -256,7 +256,9 @@ function* uniswapXSwap(
}
} catch (error) {
const displayableError = getDisplayableError(error, step)
logSwapError(displayableError, { tags: { file: 'swapSaga', function: 'uniswapXSwap' } })
if (displayableError) {
logger.error(displayableError, { tags: { file: 'swapSaga', function: 'uniswapXSwap' } })
}
onFailure(displayableError)
return
}
......@@ -265,21 +267,6 @@ function* uniswapXSwap(
yield* call(onSuccess)
}
function logSwapError(error: TransactionError | undefined, captureContext: LoggerErrorContext) {
if (error instanceof TransactionStepFailedError) {
logger.error(
{
...error,
step: JSON.stringify(error.step),
originalError: errorToString(error.originalError),
},
captureContext,
)
} else if (error) {
logger.error(error, captureContext)
}
}
function getDisplayableError(error: Error, step: TransactionStep): TransactionError | undefined {
// If the user rejects a request, or it's a known interruption e.g. trade update, we handle gracefully / do not show error UI
if (didUserReject(error) || error instanceof HandledTransactionInterrupt) {
......
......@@ -42,18 +42,19 @@ import { signTypedData } from 'utils/signing'
import { getConnectorClient } from 'wagmi/actions'
export interface HandleSignatureStepParams<T extends SignatureTransactionStep = SignatureTransactionStep> {
account: AccountMeta
step: T
setCurrentStep: SetCurrentStepFn
ignoreInterrupt?: boolean
}
export function* handleSignatureStep({ setCurrentStep, step, ignoreInterrupt }: HandleSignatureStepParams) {
export function* handleSignatureStep({ setCurrentStep, step, ignoreInterrupt, account }: HandleSignatureStepParams) {
// Add a watcher to check if the transaction flow is interrupted during this step
const { throwIfInterrupted } = yield* watchForInterruption(ignoreInterrupt)
// Trigger UI prompting user to accept
setCurrentStep({ step, accepted: false })
const signer = yield* call(getSigner)
const signer = yield* call(getSigner, account.address)
const signature = yield* call(signTypedData, signer, step.domain, step.types, step.values) // TODO(WEB-5077): look into removing / simplifying signTypedData
// If the transaction flow was interrupted, throw an error after the step has completed
yield* call(throwIfInterrupted)
......@@ -78,7 +79,7 @@ export interface HandleOnChainStepParams<T extends OnChainTransactionStep = OnCh
export function* handleOnChainStep<T extends OnChainTransactionStep>(params: HandleOnChainStepParams<T>) {
const { account, step, setCurrentStep, info, allowDuplicativeTx, ignoreInterrupt, onModification } = params
const { chainId } = step.txRequest
const signer = yield* call(getSigner)
const signer = yield* call(getSigner, account.address)
// Avoid sending prompting a transaction if the user already submitted an equivalent tx, e.g. by closing and reopening a transaction flow
const duplicativeTx = yield* findDuplicativeTx(info, account, chainId, allowDuplicativeTx)
......@@ -236,8 +237,8 @@ async function getProvider(): Promise<Web3Provider> {
return provider
}
async function getSigner(): Promise<JsonRpcSigner> {
return (await getProvider()).getSigner()
async function getSigner(account: string): Promise<JsonRpcSigner> {
return (await getProvider()).getSigner(account)
}
type SwapInfo = ExactInputSwapTransactionInfo | ExactOutputSwapTransactionInfo
......
......@@ -21,6 +21,7 @@ export class TransactionStepFailedError extends TransactionError {
step: TransactionStep
isBackendRejection: boolean
originalError?: Error
stringified?: string
constructor({
message,
......@@ -38,6 +39,10 @@ export class TransactionStepFailedError extends TransactionError {
this.step = step
this.isBackendRejection = isBackendRejection
this.originalError = originalError
try {
this.stringified = JSON.stringify(this, null, 2) // provides more insight to sentry logs
} catch {}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment