Subclassed decorator methods not working
维护者通常 4 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
- Issue 类型
- 缺陷
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 技术栈
- python
调研方向
Start by reproducing the reported example using attr.s, attr.ib, and the inherited value.default decorator. Trace how subclassed attributes and decorator methods are handled, then establish the intended behavior for TestClass before adding a regression test and confirming the example works.
由索引模型根据 Issue 内容生成。
描述
My framework relies on (smart) subclassing, but I've also got it to work with attrs mostly. Running into a problem like the following.
@attr.s
class BaseClass():
value = attr.ib(default=10)
@attr.s
class TestClass(BaseClass):
@value.default
def _not_value(self):
return 20
- 主要语言
- Python
- 星标
- 5.8k
- 派生
- 480
- 平均合并
- 2 小时 15 分钟
- 30 天内合并 PR
- 2
环境准备
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
python-attrs/attrs 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 78/100
python-attrs/attrs#1627 ·
维护者通常 4 天内回复
-
难度 5/5 一周以上 新手友好度 20/100
python-attrs/attrs#1620 ·
维护者通常 4 天内回复
-
难度 3/5 1-2 天 新手友好度 55/100
python-attrs/attrs#1596 · 2 条评论 · 1 个 reaction ·
维护者通常 4 天内回复
-
难度 4/5 3-5 天 新手友好度 35/100
python-attrs/attrs#1549 · 3 条评论 ·
维护者通常 4 天内回复
-
难度 4/5 3-5 天 新手友好度 38/100
python-attrs/attrs#1543 · 2 条评论 ·
维护者通常 4 天内回复
查看 python-attrs/attrs 的全部 Issue
相似的 Issue
-
good first issue
难度 2/5 1-3 小时 新手友好度 88/100
-
难度 2/5 1-3 小时 新手友好度 88/100
vllm-project/vllm-metal#822 ·
维护者通常 1 天内回复
-
vector-store
难度 1/5 1-3 小时 新手友好度 90/100
维护者通常 1 天内回复
-
[Bug]: chunk_span_bounds and _validated_chunk_spans reject Pydantic models ChunkSpan and AudioFile未关闭
难度 2/5 1-3 小时 新手友好度 78/100
BasedHardware/omi#19047 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复