Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

type coercion inconsistently fails depending on order of arguments

オープン
#114 コメント 2 件 リアクション 0 件 担当者 1 名 GitHub で見る

@klarose がすでに取り組んでいます。

2026年6月1日 から。

評価

この issue はまだ評価されていません。

説明

bug

I was surprised to find that a less-than comparison failed between an integer and a float, since I thought I had seen it work earlier. Sure enough, it works if the left hand side is a float, but not if the left hand side is an int.

Example:

# good
python -m celpy -n '4.0 < 10'
true

# bad
python -m celpy -n '10 < 4.0'
ERROR: <input>:1:1 found no matching overload for 'relation_lt' applied to '(<class 'celpy.celtypes.IntType'>, <class 'celpy.celtypes.DoubleType'>)'
    | 10 < 4.0

Both of these work in golang, see cel playground

I expect both statements to properly evaluate. This appears to affect a bunch of other operators (<=, >, >=)

主要言語
Python
スター
174
フォーク
40
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトの環境構築ファイルはまだ確認していません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

cloud-custodian/cel-python のほかの issue

cloud-custodian/cel-python の issue をすべて見る

似ている issue

Python の issue をもっと見る

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

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