Repository navigation
Loosen assertion so it matches any production error - #8907
Conversation
sophiebits
left a comment
There was a problem hiding this comment.
I guess this is fine, but does this mean the message is different?
|
I would assume it means it is crashing for a different reason. |
sophiebits
left a comment
There was a problem hiding this comment.
Can we figure out why this is different?
The exact error code isn't important.
|
It was because the message was slightly different, which I fixed in 2afcf6e I figured loosening the invariant made sense, anyway. Although after rebasing, now I'm having a different problem where the error code transform isn't picking up that invariant, but works for other invariants in the same file. Weird. |
|
Ah, the message is the same as Stack but the template string passed to Also, we haven't run |
|
I guess it happens before release so it's not a big deal. (Or does it...?) |
|
Yea, it's in the release guide so shouldn't be necessary. |
The production error code system depends on the exact template string that is passed to `invariant`. This changes the Fiber templates to match the Stack ones.
0936484 to
ea2aa6e
Compare
|
@spicyj Going to assume this is good to merge now that we know why the codes were different (they're the same now), since you approved it earlier. |
|
I don't think we should loosen this unnecessarily – even if format changes are okay, problems building the URL or similar could surface and be caught by the old test. Can we revert this? (If I rescind my acceptance then please don't consider a PR accepted.) |
|
Ok I'll revert it and open a separate PR without the change to the test. |
|
And sorry, I didn't intentionally ignore your review... I thought it was ambiguous whether you had "rescinded" it or not, since there were two reviews, hence my comment :D |
|
Latest review wins. :) |
Loosen assertion so it matches any production error
Loosen assertion so it matches any production error
This test was failing because the error code didn't match. The specific error code isn't important.