- Version: 5.31.3
- Python: 3.10.6
- OS: osx/linux
I am connected to an Infura node.
When I call w3.eth.get_logs({"fromBlock": x, "toBlock": y})
I very sporadically get this error. Calling the same get_logs
call again with the same parameters resolves as expected. This is the error:
ValueError: The provided value did not satisfy any of the formatter conditions
File "run_radar.py", line 29, in main
radar.start(scan_config)
File "radar/radar.py", line 114, in start
scan_output = _scan(scan_config, contracts)
File "utils.py", line 20, in wrapper
return cast(R, fn(*args, **kwargs))
File "newrelic/api/background_task.py", line 117, in wrapper
return wrapped(*args, **kwargs)
File "radar/radar.py", line 221, in _scan
logs, start_block, end_block, is_caught_up = _get_logs(
File "utils.py", line 20, in wrapper
return cast(R, fn(*args, **kwargs))
File "newrelic/api/background_task.py", line 117, in wrapper
return wrapped(*args, **kwargs)
File "radar/radar.py", line 153, in _get_logs
logs, adjusted_end_block = _get_logs_chunk(
File "utils.py", line 20, in wrapper
return cast(R, fn(*args, **kwargs))
File "newrelic/api/background_task.py", line 117, in wrapper
return wrapped(*args, **kwargs)
File "radar/radar.py", line 206, in _get_logs_chunk
raise e
File "radar/radar.py", line 178, in _get_logs_chunk
return provider.get_logs(start_block, end_block), end_block
File "radar/provider.py", line 20, in get_logs
return w3.eth.get_logs(
File "web3/module.py", line 57, in caller
result = w3.manager.request_blocking(method_str,
File "web3/manager.py", line 197, in request_blocking
response = self._make_request(method, params)
File "web3/manager.py", line 150, in _make_request
return request_func(method, params)
File "web3/middleware/formatting.py", line 94, in middleware
response = make_request(method, params)
File "web3/middleware/gas_price_strategy.py", line 90, in middleware
return make_request(method, params)
File "web3/middleware/formatting.py", line 94, in middleware
response = make_request(method, params)
File "web3/middleware/attrdict.py", line 33, in middleware
response = make_request(method, params)
File "web3/middleware/formatting.py", line 96, in middleware
return _apply_response_formatters(method=method, response=response, **formatters)
File "web3/middleware/formatting.py", line 51, in _apply_response_formatters
return _format_response("result", result_formatters[method])
File "web3/middleware/formatting.py", line 47, in _format_response
response, response_type, method_response_formatter(appropriate_response)
File "cytoolz/functoolz.pyx", line 249, in cytoolz.functoolz.curry.call
File "eth_utils/applicators.py", line 116, in apply_one_of_formatters
raise ValueError(