-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
🐛 [Bug]: Wrong handlers execution order in some mount cases #2460
Labels
Comments
@sadfun it really seems to be a bug i assume it is a problem when i replace the mounted app Lines 214 to 218 in c56b4e6
will fix it in the next days and release it on friday |
ReneWerner87
added a commit
that referenced
this issue
May 16, 2023
ReneWerner87
added a commit
that referenced
this issue
May 16, 2023
ReneWerner87
added a commit
that referenced
this issue
May 16, 2023
ReneWerner87
added a commit
that referenced
this issue
May 17, 2023
ReneWerner87
added a commit
that referenced
this issue
May 17, 2023
ReneWerner87
added a commit
that referenced
this issue
May 17, 2023
* 🐛 [Bug-fix]: Wrong handlers execution order in some mount cases #2460 * 🐛 [Bug-fix]: Wrong handlers execution order in some mount cases #2460 * 🐛 [Bug-fix]: Wrong handlers execution order in some mount cases #2460 * [Bug-fix]: Wrong handlers execution order in some mount cases #2460 * [Bug-fix]: Wrong handlers execution order in some mount cases #2460
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug Description
In some rare cases, fiber can wrongly build
app.treeStack
, breaking the execution chain. For example, it can call a handler from a mounted app before it calls a middleware specified at the top level earlier.How to Reproduce
In attached code snippet, fiber thinks that middleware printing
"i'm ignored!"
should be executed after/methods/test
handler.I think there are many more cases when this happens, but for now I'm able to reproduce only this one.
Expected Behavior
Handlers execute in correct order.
Fiber Version
2.45.0
Code Snippet (optional)
Checklist:
The text was updated successfully, but these errors were encountered: