Upgrading from rails 4.2.0 to 5.0.0 and Ruby from 2.2.4 to 2.5.8 - Circular dependency detected while autoloading constant Sub

O.k. so here’s my issue: Upgrading from rails 4.2.0 to 5.0.0 and Ruby from 2.2.4 to 2.5.8 - Circular dependency detected while autoloading constant Sub - Stack Overflow

Anyone have any idea what I’m doing wrong? This is driving me crazy.