0xPlaygrounds / 0xPlaygrounds/subgrounds

Syntax Sugar for `._select`

オープン 初心者向け
#32 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
enhancement good first issue
主要言語
Python
スター
73
フォーク
12
PR マージ指標
30日以内にマージされた PR はありません

説明

**Is your feature request related to a problem? Please describe.**
`._select` is pretty verbose, especially when forced to use it with keywords like `"from"`

```py
subgraph.Query.snapshots._select("from")
```

**Describe the solution you'd like**
Use the `subscript` helpers for a cleaner syntax (and more intuitive)!

```py
subgraph.Query.snapshots["from"]
```

**Implementation checklist**
- [ ] Add `__setitem__` and `__getitem__`
- [ ] Add tests for those!

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

Look at the `_select` method in the codebase, likely in a class like `Query` or `Field`. Implement `__getitem__` and `__setitem__` to allow subscript syntax. Write tests to ensure the new syntax works correctly, especially with reserved keywords like 'from'. Check existing tests for `_select` to understand the expected behavior.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
api
issue の種類
機能追加
難易度
2/5
見積もり時間
1〜3時間
活発さ
停滞
明瞭さ
明確に書かれている
初心者へのやさしさ
70/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。