Merge "Fix a bug where the package stats query timeout may crash." into nyc-mr2-dev