teemtee / fmf

Flexible Metadata Format
GNU General Public License v2.0
22 stars 28 forks source link

py3.13 - `fmf ls --condition 'float(release) >= 7'` broken #246

Closed lukaszachy closed 5 months ago

lukaszachy commented 5 months ago

Used in tests/unit/test_cli.py - test_conditions. Can be reproduced easily:

$ cd examples/conditions
$ fmf ls --condition 'flaot(release) >= 7'

On python3.12 and older it prints 3 tests. On python3.13 the output is empty.

Simplified reproducer is:

cd $(mktemp -d)
fmf init
echo 'foo: 1.0' > f.fmf
fmf ls --condition 'float(foo) > 0'

Blocks fedora rawhide - https://bugzilla.redhat.com/show_bug.cgi?id=2279994

lukaszachy commented 5 months ago

And the reason of the change is https://docs.python.org/3.13/whatsnew/3.13.html#whatsnew313-locals-semantics