InjectiveLabs / sdk-python

Injective Exchange API for Python clients
Apache License 2.0
41 stars 27 forks source link

Test fails with protobuf 4.24.4 #298

Closed MementoRC closed 8 months ago

MementoRC commented 9 months ago

TestIndexerGrpcExplorerApi fails with protobuf=4.24.4 with:

============================================================================================================ short test summary info ============================================================================================================
FAILED tests/client/indexer/grpc/test_indexer_grpc_explorer_api.py::TestIndexerGrpcExplorerApi::test_fetch_validators - TypeError: Can only compare repeated composite fields against other repeated composite fields.
FAILED tests/client/indexer/grpc/test_indexer_grpc_explorer_api.py::TestIndexerGrpcExplorerApi::test_fetch_validator - TypeError: Can only compare repeated composite fields against other repeated composite fields.
FAILED tests/client/indexer/grpc/test_indexer_grpc_explorer_api.py::TestIndexerGrpcExplorerApi::test_fetch_wasm_contract_by_address - TypeError: Can only compare repeated composite fields against other repeated composite fields.

A possible fix:

        assert sorted(result_wasm_contract) == sorted(expected_wasm_contract)
aarmoa commented 8 months ago

In PR #301 protobuf version was upgraded to 4.25.2. The validation workflow that runs all unit tests is configured to run using Python 3.9, 3.10 and 3.11 in Windows, Mac and Ubuntu machines. We are sure the issues is not present.

MementoRC commented 8 months ago

from pyproject.toml: protobuf = "*" As a FYI, running the tests (optional) for the conda-forge recipe still fails for 1.3.0 without a local patch

Also, anyone is welcome to be added as a co-maintainer of the conda-forge recipe