TypeError when using sort on result from search

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

TypeError when using sort on result from search

fiveop
result = world.search(...)
result.sort()

leads to 'TypeError: must use keyword argument for key function'. This can be fixed by chaning

return self.sort(key, reverse)

to

return self.sort(key=key, reverse=reverse)

in _LazyListMixin#sort
Reply | Threaded
Open this post in threaded view
|

Re: TypeError when using sort on result from search

Jiba
Administrator
Hi,

Thank you for reporting and fixing this problem.

I integrated your fix in the devlopment version.

Jiba