Closed fsteff closed 1 month ago
With version 1.0.0 the Query Parameters __iter__() function returns a list[tuple[str,str]] instead of an iterator. (previously I would call decode_parameters())
__iter__()
list[tuple[str,str]]
decode_parameters()
Example for retrieving all parameters:
def handle_query(query: zenoh.Query): params = list(query.parameters)
causes the error TypeError: iter() returned non-iterator of type 'list'
TypeError: iter() returned non-iterator of type 'list'
Currently a workaround for this is calling __iter__() manually
def handle_query(query: zenoh.Query): params = list(query.parameters.__iter__())
import zenoh list(zenoh.Parameters({'k': 'v'}))
1.0.0-rc.2
Describe the bug
With version 1.0.0 the Query Parameters
__iter__()
function returns alist[tuple[str,str]]
instead of an iterator. (previously I would calldecode_parameters()
)Example for retrieving all parameters:
causes the error
TypeError: iter() returned non-iterator of type 'list'
Currently a workaround for this is calling
__iter__()
manuallyTo reproduce
System info
1.0.0-rc.2