Skip to content

Support mixed eval & non-eval stack traces - #97

Merged
davidpfahler merged 1 commit into
commissure:masterfrom
LachlanStuart:master
Jun 2, 2017
Merged

davidpfahler merged 1 commit into
commissure:masterfrom
LachlanStuart:master

Conversation

@LachlanStuart

Copy link
Copy Markdown
Contributor

This builds on the change in #94 to support stack traces that contain both eval and non-eval lines. I suspect these mixed stack traces are coming from my vendor bundle having been built with source-map, while my application bundle is built with cheap-module-eval-source-map.

Example JSONified stackLines that is only supported after this change:

[
" at _default (eval at ./src/routes.js (http://localhost:3000/app.js?ef9dba4c6d4b1c818e5b:11663:1), :357:171)",
" at new Root (eval at ./src/containers/Root.js (http://localhost:3000/app.js?ef9dba4c6d4b1c818e5b:8598:1), :27:94)",
" at eval (eval at ./node_modules/react-proxy/modules/createClassProxy.js (http://localhost:3000/app.js?ef9dba4c6d4b1c818e5b:4180:1), :95:24)",
" at instantiate (eval at ./node_modules/react-proxy/modules/createClassProxy.js (http://localhost:3000/app.js?ef9dba4c6d4b1c818e5b:4180:1), :103:9)",
" at Root (eval at proxyClass (eval at ./node_modules/react-proxy/modules/createClassProxy.js (http://localhost:3000/app.js?ef9dba4c6d4b1c818e5b:4180:1)), :4:17)",
" at eval (webpack:///./~/react-dom/lib/ReactCompositeComponent.js?:306:16)",
" at measureLifeCyclePerf (webpack:///./~/react-dom/lib/ReactCompositeComponent.js?:75:12)",
" at ReactCompositeComponentWrapper._constructComponentWithoutOwner (webpack:///./~/react-dom/lib/ReactCompositeComponent.js?:305:14)",
" at ReactCompositeComponentWrapper._constructComponent (webpack:///./~/react-dom/lib/ReactCompositeComponent.js?:280:21)",
" at ReactCompositeComponentWrapper.mountComponent (webpack:///./~/react-dom/lib/ReactCompositeComponent.js?:188:21)"
]

@borela

borela commented Jun 1, 2017

Copy link
Copy Markdown
Contributor

You could add a // TODO: ... comment there too so that in the future we remember to look at a way to load even mixed stacks.

@davidpfahler

Copy link
Copy Markdown
Member

Looks good to me. @borela? Now if you could change your commit message to something that starts with feat: I think this is ready to go live.

@borela

borela commented Jun 1, 2017 •

Copy link
Copy Markdown
Contributor

Looks good to me too, I was just saying that in the future this could be upgraded to try to load the source maps too. It is not trivial to code but possible.

@LachlanStuart

Copy link
Copy Markdown
Contributor Author

I have amended the commit by adding a // TODO and prepending feat: to the commit message.

@davidpfahler
davidpfahler merged commit 50c8ccc into commissure:master Jun 2, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants