question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Running into uncaught exceptions when trying to extract from flow

See original GitHub issue

When trying to extract from flow, I get the following uncaught exception:

{ Error: (client) ../src/button/button.js (../node_modules/extract-react-types-loader!../src/button/button.js)
Module build failed (from ../node_modules/extract-react-types-loader/index.js):
TypeError: Cannot read property 'kind' of undefined
    at props.members.forEach.p ($/node_modules/extract-react-types/index.js:52:29)
    at Array.forEach (<anonymous>)
    at getPropFromObject ($/node_modules/extract-react-types/index.js:45:17)
    at getProp ($/node_modules/extract-react-types/index.js:74:12)
    at defaultProps.forEach.property ($/node_modules/extract-react-types/index.js:237:18)
    at Array.forEach (<anonymous>)
    at addDefaultProps ($/node_modules/extract-react-types/index.js:232:16)
    at convertReactComponentClass ($/node_modules/extract-react-types/index.js:263:10)
    at converters.Program ($/node_modules/extract-react-types/index.js:182:19)
    at convert ($/node_modules/extract-react-types/index.js:1433:16)
    at extractReactTypes ($/node_modules/extract-react-types/index.js:1470:10)
    at Object.extractReactTypesLoader ($/node_modules/extract-react-types-loader/index.js:65:17)

Repro: https://github.com/uber-web/baseui/pull/714/files#diff-6fabde4439377979ef1bfcd17147b620R43

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
gergelykecommented, Jan 8, 2019

So it seems that once I move the default props into the button.js file, the error goes away - any chance you can point me to where I should look for the bug in the codebase? Happy to work on a fix

1reaction
Novinycommented, Jan 8, 2019

Looking into it quickly, it’s struggling to resolve the defaultProps. At a guess it’s the spread and the property, though it could also be a failure to grab the information from the other file.

Line 52 (or something around it) will need to be updated, but if you’re looking for the fastest way forward, I’d try some different configurations for this line as well as just checking that removing the defaults resolves the problem you are facing.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Flow software fails to run after unhandled exception - TechNet
Flow software is a .net based app with a SQLCE database running on pc's in this case Win 10. After a data import...
Read more >
How to Solve Salesforce Flow Errors
An “unhandled fault” is thrown when something happens inside your Flow that goes against what Salesforce is expecting. This could be something ...
Read more >
Fault Connector & Exception Handling in Salesforce Flows
When a flow fails, the user running the flow gets this error message. ... 'Unhandled Fault' message in your screen flows again!
Read more >
Customize What Happens When a Flow Fails - Salesforce Help
As a best practice, we recommend displaying a better message to your user than “An unhandled fault has occurred in this flow”.
Read more >
android - Need to handle uncaught exception and send log file
Handle uncaughtException in your Application subclass. After catching an exception, start a new activity to ask the user to send a log. Extract...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found