lukeed / lukeed/polka

Why no throwing from middleware?

Open
#12 23 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

has fix question
Dominant language
JavaScript
Stars
5.6k
Forks
176
PR merge metrics
No merged PRs in 30d

Description

I have four questions:

- How much of a performance hit is it to catch errors in middleware?
- Doesn't this mean that an error in a route will bring down the entire server?
- Is there any way a user can re-introduce catching in middleware, short of wrapping every middleware function in a try/catch?
- What about uncaught promises?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files, tests, or entry points are named. Start by locating Polka's middleware and error-handling flow, then determine whether the questions imply a concrete change and how it should be tested; the issue does not define a clear completion condition.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
15/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.