Skip to content
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

Catch Error if JSON.Stringify Fails for Engine Trace #1668

Merged
merged 3 commits into from
Sep 14, 2018
Merged

Catch Error if JSON.Stringify Fails for Engine Trace #1668

merged 3 commits into from
Sep 14, 2018

Conversation

nmchaves
Copy link
Contributor

@nmchaves nmchaves commented Sep 14, 2018

Fixes #1667

When I make these changes locally, I see this in the Query Variables section of Engine's Inspector:
screen shot 2018-09-13 at 9 45 36 pm
where file was the name of a mutation variable of type Upload.

Of course, for those variables that can be stringified, you'll still be able to see the actual value.

@ghost ghost added the ✋ blocking Prevents production or dev due to perf, bug, build error, etc.. label Sep 14, 2018
@@ -214,11 +214,11 @@ export class EngineReportingAgent<TContext = any> {
message.byteOffset,
message.byteLength,
);
gzip(messageBuffer, (err, compressed) => {
gzip(messageBuffer, (err, gzipResult) => {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes were not related to this PR. They were tslint errors (no-shadowed-variable)

@evans evans merged commit 91afcc7 into apollographql:master Sep 14, 2018
@evans
Copy link
Contributor

evans commented Sep 14, 2018

@nmchaves Thank you so much! We'll get it release straight away

@nmchaves nmchaves deleted the fix-reporting-circ-reference branch September 14, 2018 17:31
@nmchaves
Copy link
Contributor Author

@evans My pleasure, thanks for the quick review! I'll be sure to test it out once it's released

@nmchaves
Copy link
Contributor Author

Update: @evans Thanks for getting this released so quickly 🚀! After upgrading to apollo-server-express v2.0.7, the issue is fixed. I can now use the Upload type in mutations while using Apollo Engine. Everything else continues to work like before. I can still see the value of other query/mutation variables in Engine's Inspector view.

@abernix abernix removed the ✋ blocking Prevents production or dev due to perf, bug, build error, etc.. label Sep 3, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Engine throws error when serializing trace data for file uploads
3 participants