Not easy to get the number of methods llhttp has
維護者通常 6 天內回覆
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 54/100
- Issue 類型
- 功能
- 描述清晰度
- 基本清楚
- 活躍度
- 冷清
- 技術堆疊
- c, typescript
研究方向
從 api.c:222 開始,追蹤 llhttp_method_name 如何處理方法 ID,以及支援的方法表是如何定義的。檢視現有 API 和 issue 中連結的 aiohttp 範例,然後判斷哪種列舉行為是適當的。完成的標準是:呼叫端無需硬編碼數量或中止查找,即可發現每個受支援的方法,包括新加入的方法。
由索引模型根據 Issue 內容生成。
描述
In aiohttp, we need to create an array of all the method names that llhttp supports for caching purposes.
The problem is that llhttp_method_name abort()s on an out-of-range id (api.c:222), our old code therefore just had a hardcoded constant set to 46 and iterated over them. But, this means when llhttp added the QUERY method, our code didn't pick it up.
Would it be reasonable to add something to llhttp to trivially get this information? Either allowing llhttp_method_name to return NULL rather than abort(), or adding a constant that tells us how many methods are available.
Without something like that, I've had to add this awkward thing to extract the names directly:
https://github.com/aio-libs/aiohttp/pull/13174/changes#diff-061b5abe803b659aa544700e4065e1fbff6e83112315e345ea2d2e31ad1d6ca7R106-R117
- 主要語言
- TypeScript
- 星號
- 2k
- 分支
- 236
- 平均合併
- 5 天 2 小時
- 30 天內合併 PR
- 1
環境準備
- 提供 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
nodejs/llhttp 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 6 天內回覆
-
難度 4/5 3-5 天 新手友好度 55/100
維護者通常 6 天內回覆
-
難度 4/5 3-5 天 新手友好度 52/100
維護者通常 6 天內回覆
-
Should there be a way to block requests with multiple hosts or none are sent?可能已有人在做 @Vizonex 於 201 天前認領。 未關閉
難度 5/5 一週以上 新手友好度 32/100
維護者通常 6 天內回覆
-
難度 2/5 1-3 小時 新手友好度 45/100
nodejs/llhttp#782 · 2 則留言 · 4 個 reaction ·
維護者通常 6 天內回覆
相似的 Issue
-
Native Web
難度 1/5 1 小時以內 新手友好度 80/100
digitalfabrik/integreat-app#4517 ·
維護者通常 2 天內回覆
-
TLS guide repeats certs/ in the certificate directory可能已有人在做 @maheshrijal 今天認領。 未關閉
難度 1/5 1 小時以內 新手友好度 92/100
prometheus/docs#3156 ·
維護者通常 2 天內回覆
-
難度 2/5 1-3 小時 新手友好度 83/100
medusajs/dtc-starter#90 ·
維護者通常 1 天內回覆
-
usability
難度 2/5 1-3 小時 新手友好度 72/100
inmanta/web-console#7632 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 68/100
zaidmukaddam/scira#261 ·