Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

UK metadata: moduleName is empty for every variable, and modelled_policies is a file path

未关闭
#3,956 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 3 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
57/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
python
领域
api

调研方向

Start by tracing the UK metadata response for GET /uk/metadata and compare it with the US response, focusing on how variables' module paths populate moduleName and how programs.yaml is loaded into modelled_policies. Check the relevant API tests and add coverage for both fields. Done means UK variables expose module names and modelled_policies contains parsed YAML data.

由索引模型根据 Issue 内容生成。

描述

Problem

Two fields in GET /uk/metadata (policyengine-uk 2.130.1) differ from /us/metadata:

  1. moduleName is empty for every UK variable. All 1,163 variables have moduleName: "". For the US, 6,104 of 6,167 variables have it (for example household.income.person.tip_income). The app groups household inputs by module, so every UK input lands in one "Other" group.
  2. modelled_policies is a file path, not data. It is the string /opt/venv/lib/python3.12/site-packages/policyengine_uk/programs.yaml. For the US it is the parsed object. It looks like the path to programs.yaml is returned without the file being loaded.

Request

  1. Fill moduleName for UK variables the same way as for the US (from the variable's module path in policyengine-uk).
  2. Return the parsed programs.yaml content in modelled_policies for the UK.

Context

The app works around (1) with a list of UK inputs keyed by name, and skips (2), in PolicyEngine/policyengine-app-v2.

主要语言
Python
星标
18
派生
33
平均合并
2 天 18 小时
30 天内合并 PR
36

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

PolicyEngine/policyengine-api 的其他 Issue

查看 PolicyEngine/policyengine-api 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。