Thermogravitational and hybrid convection in an obstructed compact cavity