Sortlist unfinished.Blocked by python scope problem