-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Labels
Description
2 tests currently fail only on python 3.13/3.12, but not on 3.9. See the output of a failed test.
Maybe the python3.9 environment including dependencies is cached, and some installed libraries are from a different (older version). We currently define click>=8 and pytest dependencies, which don't guarantee a specific version.
Upgrading click locally to click=8.2.0 update from last week make my tests fail locally as well.
Options are parsed in a different way according to the changelog. Not sure how to resolve, let's stick to click==8.1.8 for now..
=================================== FAILURES ===================================
_____________________________ test_create_geojson ______________________________
out_folder = '/tmp/tmpkpghq63c'
def test_create_geojson(out_folder):
path = "tests/data-files/inspire.parquet"
runner = CliRunner()
result = runner.invoke(create_geojson, [path, "-o", out_folder, "-f"])
assert result.exit_code == 0, result.output
assert "Found 1 feature" in result.output
assert "Files written to" in result.output
out_file = os.path.join(out_folder, "6467974.json")
> assert os.path.exists(out_file)
E AssertionError: assert False
E + where False = <function exists at 0x7f7b01b82a20>('/tmp/tmpkpghq63c/6467974.json')
E + where <function exists at 0x7f7b01b82a20> = <module 'posixpath' (frozen)>.exists
E + where <module 'posixpath' (frozen)> = os.path
tests/test_create_geojson.py:26: AssertionError
________________________________ test_validate _________________________________
def test_validate():
path = "tests/data-files/inspire.parquet"
runner = CliRunner()
result = runner.invoke(validate, [path, "--data"])
assert result.exit_code == 0, result.output
assert "Validating tests/data-files/inspire.parquet" in result.output
assert "- https://fiboa.github.io/inspire-extension/v0.2.0/schema.yaml" in result.output
> assert "Data was not validated" not in result.output
E AssertionError: assert 'Data was not validated' not in 'fiboa CLI 0...=> VALID\n\n'
E
E 'Data was not validated' is contained here:
E .yaml
E ? ^
E - Data was not validated as the --data parameter was not provided
E ? ^^^^^^ +++++++++++++++++
E
E => VALID
tests/test_validate.py:13: AssertionError
=============================== warnings summary ===============================
../../../../../opt/hostedtoolcache/Python/3.13.3/x64/lib/python3.13/site-packages/geopandas/_compat.py:7
/opt/hostedtoolcache/Python/3.13.3/x64/lib/python3.13/site-packages/geopandas/_compat.py:7: DeprecationWarning: The 'shapely.geos' module is deprecated, and will be removed in a future version. All attributes of 'shapely.geos' are available directly from the top-level 'shapely' namespace (since shapely 2.0.0).
import shapely.geos
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
FAILED tests/test_create_geojson.py::test_create_geojson - AssertionError: assert False
+ where False = <function exists at 0x7f7b01b82a20>('/tmp/tmpkpghq63c/6467974.json')
+ where <function exists at 0x7f7b01b82a20> = <module 'posixpath' (frozen)>.exists
+ where <module 'posixpath' (frozen)> = os.path
FAILED tests/test_validate.py::test_validate - AssertionError: assert 'Data was not validated' not in 'fiboa CLI 0...=> VALID\n\n'
'Data was not validated' is contained here:
.yaml
? ^
- Data was not validated as the --data parameter was not provided
? ^^^^^^ +++++++++++++++++
=> VALID
=================== 2 failed, [37](https://github.com/fiboa/cli/actions/runs/15089067983/job/4241530
m-mohr