Crash report: `TypeError: Cannot read properties of undefined (reading 'current')`
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 5.5k
- Forks
- 5.4k
- PR merge metrics
- No merged PRs in 30d
Description
URL
https://app.uniswap.org/#/swap
swap state
{
"INPUT": {
"currencyId": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"
},
"OUTPUT": {
"currencyId": null
},
"independentField": "INPUT",
"typedValue": "",
"recipient": null
}
Error
TypeError: Cannot read properties of undefined (reading 'current')
Stacktrace
TypeError: Cannot read properties of undefined (reading 'current')
at https://app.uniswap.org/static/js/main.fd2499c6.chunk.js:1:994349
at Object.Qa [as useMemo] (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3693758)
at t.useMemo (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3518814)
at O (https://app.uniswap.org/static/js/main.fd2499c6.chunk.js:1:994197)
at fe (https://app.uniswap.org/static/js/main.fd2499c6.chunk.js:1:836406)
at Sa (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3689347)
at Pf (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3701035)
at Ss (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3747442)
at gu (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3735495)
at mu (https://app.uniswap.org/static/js/7.30a4123e.chunk.js:2:3735423)
Device data
{
"ua": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36",
"browser": {
"name": "Chrome",
"version": "106.0.0.0",
"major": "106"
},
"engine": {
"name": "Blink",
"version": "106.0.0.0"
},
"os": {
"name": "Windows",
"version": "10"
},
"device": {},
"cpu": {
"architecture": "amd64"
}
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the crash at https://app.uniswap.org/#/swap with the reported swap state, then use the main.fd2499c6.chunk.js stack entry and the useMemo call as the initial trace. Done means the swap page loads without the undefined-current TypeError for this state.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- blockchain, frontend, web-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100