package_list performance fix and sorting