`PyPiVersionRange.from_native` not working
@amantebriwal4321 がすでに取り組んでいます。
2026年10月23日 から。
評価
調査の方向性
src/univers/version_range.py の 501〜504 行付近と、traceback に示されている from_native メソッドから始めます。issue の PEP 440 の例を実行して AssertionError を再現し、その specifiers がどのように constraints になるかを追跡します。例が assertion なしでパースされ、列挙されたすべての constraints を正しく表現できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
and PEP 440 shows an example for version specifier as follows:
~= 0.9, >= 1.0, != 1.3.4.*, < 2.0
See: https://www.python.org/dev/peps/pep-0440/#version-specifiers
Let's try:
>>> from univers.version_range import PypiVersionRange
>>> rng_from_native = PypiVersionRange.from_native("~= 0.9, >= 1.0, != 1.3.4.*, < 2.0")
---------------------------------------------------------------------------
AssertionError Traceback (most recent call last)
<ipython-input-22-af3412ff72fa> in <module>
----> 1 rng_from_native = PypiVersionRange.from_native("~= 0.9, >= 1.0, != 1.3.4.*, < 2.0")
~/Contrib/univers/src/univers/version_range.py in from_native(cls, string)
514 operator = spec.operator
515 version = spec.version
--> 516 assert isinstance(version, cls.version_class)
517 comparator = cls.vers_by_native_comparators[operator]
518 constraint = VersionConstraint(comparator=comparator, version=version)
AssertionError:
Something is not right
- 主要言語
- Python
- スター
- 50
- フォーク
- 31
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
aboutcode-org/univers のほかの issue
-
Do not allow creation of `VersionRange` with empty constraint対応中かも @MGpromax が 67 日前に担当しました。 オープンbug High-Priority
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
aboutcode-org/univers#203 ·
-
maven.py: "release" qualifier not treated as release alias対応中かも @selsky が 72 日前に担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
aboutcode-org/univers#188 ·
-
VersionRange.invert() returns a complement that excludes versions outside an enumerated range対応中かも @akashrajeev が 14 日前に担当しました。 オープン
難易度 3/5 1〜2日 初心者へのやさしさ 72/100
aboutcode-org/univers#214 · コメント 1 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 15/100
aboutcode-org/univers#206 · コメント 3 件 · リアクション 2 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 18/100
aboutcode-org/univers#205 ·
aboutcode-org/univers の issue をすべて見る
似ている issue
-
_chunk_scan_fwd launches its Triton kernel without a device guard: NaN when a model is split across GPUs対応中かも @toddwbucy が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
state-spaces/mamba#1072 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
loopj/aiovantage#414 ·
メンテナーはふだん 1 日以内に返信
-
power_mismatch_deline docstring: the rear-to-total RMAD conversion has an extra bifaciality factorオープン
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
pvlib/pvlib-python#2929 ·
メンテナーはふだん 1 日以内に返信
-
data good first issue launch-day unverified
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
BradGroux/wow-forever-mission-control#8 ·
メンテナーはふだん 1 日以内に返信
-
check bilibili falsely reports read/subtitle as broken: live_test fixture BV1GJ411x7h7 is gone (404)オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
Panniantong/Agent-Reach#889 ·
メンテナーはふだん 2 日以内に返信