-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
feat(trace): pretty print trace errors to logs #9367
Conversation
Deployment failed with the following error:
|
Deployment failed with the following error:
|
Deployment failed with the following error:
|
Deployment failed with the following error:
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
8 Skipped Deployments
|
5106592
to
53b2478
Compare
} | ||
|
||
impl TraceResult { | ||
pub fn emit_errors(&self) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So do proc macros mess up unused code detection? Could you add a decl to silence that warning?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's actually the combination binary/library crate that's causing this. Because from the binary's perspective this is unused
@@ -80,7 +80,8 @@ pub async fn run( | |||
// If the arg starts with "query" or "mutation", and ends in a bracket, it's | |||
// likely a direct query If it doesn't, it's a file path, so we need to | |||
// read it | |||
let query = if (trimmed_query.starts_with("query") || trimmed_query.starts_with("mutation")) | |||
let query = if (trimmed_query.starts_with("query") | |||
|| trimmed_query.starts_with("mutation") | trimmed_query.starts_with('{')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm surprised there isn't an warning for using bitor
|| trimmed_query.starts_with("mutation") | trimmed_query.starts_with('{')) | |
|| trimmed_query.starts_with("mutation") || trimmed_query.starts_with('{')) |
9857197
to
7e7fc15
Compare
7e7fc15
to
ca839d2
Compare
Description
To help debug trace, pretty print the errors to stderr by default. Includes fancy error messages either via SWC or our own miette infrastructure
Testing Instructions
Try using trace and hit an error