alexmojaki / alexmojaki/sorcery

Support walrus operator assignments

未关闭
#15 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
Python
星标
429
派生
22
PR 合并指标
30 天内没有已合并 PR

描述

...such as this:

```
if (some_key := unpack_keys(dict(some_key=42))):
print(some_key)
```

currently this raises

```
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.11/site-packages/sorcery/core.py", line 185, in __call__
assert executing.node, "Failed to find call node"
AssertionError: Failed to find call node
```

while it would be magical if `sorcery` could handle this walrus assignment expression, too, wouldn't it?

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

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