Skip to content

Convert React Native plugin to use HTTP POST #493

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

Closed
benvinegar opened this issue Jan 28, 2016 · 5 comments
Closed

Convert React Native plugin to use HTTP POST #493

benvinegar opened this issue Jan 28, 2016 · 5 comments

Comments

@benvinegar
Copy link
Contributor

We are getting reports that React Native produces particularly long stack traces, and the HTTP GETs produced by Raven.js are causing 414 "URI too long" errors.

Unfortunately, this isn't as simple as just switching "GET" to "POST" ... The Sentry server requires CORS headers, which React Native's "emulated" XHR may not support (for example, React Native does not support withCredentials). Need to investigate.

@qbig
Copy link
Contributor

qbig commented Jan 28, 2016

@benvinegar So how is eg. python client handle the CORS headers etc ?

@benvinegar
Copy link
Contributor Author

So, if you use your secret key with a regular POST, it will work. But you're not supposed to share your secret key, and I believe the key will be visible if embedded in your React Native app.

@qbig
Copy link
Contributor

qbig commented Jan 29, 2016

Just wondering why would the key be visible ?

@qbig
Copy link
Contributor

qbig commented Jan 29, 2016

or maybe an temporary fix to limit the length of stack trace to like 1000 characters ?

@qbig
Copy link
Contributor

qbig commented Jan 29, 2016

@benvinegar Nice! I just figured out that, if I limit the length of the stacktrace message, I can get log info !

benvinegar added a commit that referenced this issue Feb 4, 2016
Change react-native plugin to use HTTP POST w/ phony Origin (fixes #493)
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

No branches or pull requests

2 participants