Attachment downloads ignore request URL and header overrides
評估
研究方向
Start by reading Client.attachments.download(...), download_bytes(...), and _execute_download_request, then check the _build_request argument order. Use the mocked requests.request boundary to verify both public methods honor the API URI and header overrides, omit the bodyless GET Content-type header, and report the overridden URL on timeout.
由索引模型根據 Issue 內容生成。
描述
Both Client.attachments.download(..., overrides=...) and download_bytes(...) pass their options through _execute_download_request, which currently calls _build_request("GET", path, headers, query_params, overrides) positionally. The fifth argument is request_body, not overrides.
For example, a call with overrides={"api_uri": "https://override.example.test", "headers": {"X-Test": "custom"}} still uses the original API URL and omits the custom header. Any nonempty overrides also cause a JSON Content-type header on the bodyless download GET. Timeout selection itself works, but a timeout error reports the original URL when the caller supplied a different API URI.
Reproduced using both public attachment download methods, the real HTTP client, and a mocked requests.request boundary. No live API or account calls. Fourteen regression/control cases:12 fail and2 pass on main. I have a focused keyword-argument fix and tests ready.
- 主要語言
- Python
- 星號
- 109
- 分支
- 85
- 平均合併
- 8 小時 41 分鐘
- 30 天內合併 PR
- 3
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
nylas/nylas-python 的其他 Issue
-
bug
難度 2/5 1-3 小時 新手友好度 48/100
nylas/nylas-python#455 ·
-
Bug: drafts.create() fails with TypeError for multipart requests (attachments > 3MB)可能已有人在做 @benjaminwhtan 於 267 天前認領。 未關閉
nylas/nylas-python#454 · 3 則留言 · 已指派 1 人 ·
-
UnicodeEncodeError when sending e-mails with some iso-8859 characters (€ symbol)可能重新可做 @pengfeiye 於 278 天前認領,目前沒有進行中的 PR。 未關閉bug
nylas/nylas-python#448 · 1 則留言 · 已指派 2 人 ·
-
Create an async version of the client可能重新可做 @AaronDDM 於 496 天前認領,目前沒有進行中的 PR。 未關閉enhancement
nylas/nylas-python#412 · 1 則留言 · 5 個 reaction · 已指派 1 人 ·
-
bug
難度 3/5 1-2 天 新手友好度 38/100
nylas/nylas-python#402 · 1 個 reaction ·
查看 nylas/nylas-python 的全部 Issue
相似的 Issue
-
changelog investigate
難度 2/5 1-3 小時 新手友好度 65/100
ramnes/notion-sdk-py#423 ·
-
難度 2/5 1-3 小時 新手友好度 77/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
難度 1/5 1-3 小時 新手友好度 89/100
duckdb/duckdb-web#7514 ·
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 72/100
jbacalso24/mimry#525 ·
維護者通常 1 天內回覆