Enable get_all_packages function to filter packages by their extension