-
Notifications
You must be signed in to change notification settings - Fork 1
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
Explicitly assert on badged errors instead of ignoring badged errors @eps1lon #6
base: errorenv
Are you sure you want to change the base?
Conversation
This is attached to our custom Error "sub class" on the receiving side which also includes digest. DEV-only.
This way this helper can use component stacks when available.
That way your typical log of an error that originated on the Server gets a `[Server]` badge. Unfortunately because defaultOnUncaughtError and defaultOnRecoverableError doesn't use custom logging but goes through reportError. There's no place for us to add this kind of formatted badging to the logs. It's also unfortunate that you'd have to replicate this in user space.
@@ -841,6 +841,10 @@ describe('ReactFlightDOM', () => { | |||
expectedGamesValue, | |||
); | |||
|
|||
if (gate(flags => flags.enableOwnerStacks)) { |
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 was expecting enableServerComponentLogs
but the behavior is not actually behind this flag. Using enableServerComponentLogs
would fail CI.
@@ -841,6 +841,10 @@ describe('ReactFlightDOM', () => { | |||
expectedGamesValue, | |||
); | |||
|
|||
if (gate(flags => flags.enableOwnerStacks)) { | |||
// TODO: assertConsoleServerErrorDev |
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.
Probably best to use a dedicated assertConsoleBadgedErrorDev
matcher with the badge name. That way we could also test switching environment names halfway through.
No description provided.