Tool, service and variable get requests omit configured headers
还没有人认领这个 Issue。
评估
调研方向
从 ToolServiceVariableBaseQuery.get 开始,将其请求循环与 Query.get、Query.results 和 Query.hits 进行比较。使用 Requests 的 send 拦截来验证 ToolQuery、ServiceQuery 和 VariableQuery 中配置的请求头,包括分页和空结果。完成的标准是聚焦的离线用例通过,同时分页、输出格式和 HTTP 错误传播保持不变。
由索引模型根据 Issue 内容生成。
描述
Problem
On develop at 9f7648ccb925b9c0eb50241e35f15d6454e89505, ToolServiceVariableBaseQuery.get omits the configured request headers. The shared implementation affects ToolQuery, ServiceQuery and VariableQuery.
Setting headers through either supported token method, or directly through the public headers mapping, works for the base Query methods but has no effect on the specialized get requests. The request loop supplies only its URL and pagination parameters.
Reproduction
Create any of the three query classes, configure a header, and call get with Requests' send method intercepted. The prepared request does not contain the configured header. This reproduces on every page. No live request is needed.
Expected behavior
Forward the query's headers on every get request, consistent with Query.get, Query.results and Query.hits. Preserve current pagination, output-format handling, empty results and HTTP error propagation.
A focused production fix and 18 offline test cases are prepared. Twelve fail on the original implementation and six controls pass. The complete 147-test suite passes with the fix using the repository-locked HTTP/VCR versions, as do mypy and the repository's gating lint checks. No real credentials or live CMR calls are used.
- 主要语言
- Python
- 星标
- 29
- 派生
- 32
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
我们还没有检查这个项目的环境配置文件。先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
nasa/python_cmr 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 78/100
nasa/python_cmr#123 ·
-
难度 2/5 1-3 小时 新手友好度 78/100
nasa/python_cmr#108 ·
-
难度 3/5 1-2 天 新手友好度 52/100
nasa/python_cmr#104 ·
-
enhancement
难度 3/5 1-2 天 新手友好度 38/100
nasa/python_cmr#95 · 1 条评论 ·
-
enhancement
难度 3/5 1-2 天 新手友好度 45/100
nasa/python_cmr#94 ·
相似的 Issue
-
[Bug] @deck.gl/arcgis dist import resolves to unpublished @deck.gl/core source path (9.3.11, 9.4.0)未关闭
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
workflow: a tick's dispatch counts as 'only this step', and no review self-grants a round unattended未关闭workflow
难度 2/5 1-3 小时 新手友好度 85/100
kristofdegrave/homeassistant-smart-charging#1505 ·
维护者通常 1 天内回复
-
metadata submission
难度 2/5 1-3 小时 新手友好度 82/100
-
bug
难度 2/5 1-3 小时 新手友好度 65/100
canonical/content-cache-operator#163 · 1 条评论 ·
维护者通常 1 天内回复
-
[submission]未关闭submission
难度 1/5 1 小时以内 新手友好度 65/100
leanprover/lean-eval-submissions#1852 ·
维护者通常 1 天内回复