python-hyper / python-hyper/uritemplate
Potential bug/Unspecified behaviour
まだ誰も着手していません。
- 主要言語
- Python
- スター
- 246
- フォーク
- 39
- 平均マージ
- 13時間 38分
- マージ済み PR(30日)
- 1
説明
Let's look at a template like this:
http://example.com/dictionary/{term:1}
We have two different behaviours depending upon the value used to expand term.
>>> import uritemplate
>>> u = uritemplate.URITemplate('http://example.com/dictionary/{term:1}')
>>> u.expand(term='foo')
'http://example.com/dictionary/f'
>>> u.expand(term=['foo', 'bar', 'bogus'])
'http://example.com/dictionary/foo,bar,bogus'
A simplified version of this is simply
{term:1}
In other words:
>>> import uritemplate
>>> u = uritemplate.URITemplate('{term:1}')
>>> u.expand(term='foo')
'f'
>>> u.expand(term=['foo', 'bar', 'bogus'])
'foo,bar,bogus'
All versions of uritemplate (and uritemplate.py) exhibit this behaviour and the RFC does not provide clear guidance.
I have not investigated how other implementations in other languages handle this, though. There do not appear to be any examples in the RFC that combine lists with length limitations.
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
Issue にある URITemplate.expand の例と RFC 6570 のプレフィックス修飾子の規則から始め、次にスカラー値とリスト値の展開を比較します。Issue ではリポジトリのファイルも既存のテストも指定されていません。完了とは、リスト値について合意された解釈と、両方の形式に対する回帰カバレッジが得られていることを意味します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- backend-api-design
- issue の種類
- バグ
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 25/100