bug fix: group by subscription_id