Handle MiddlewareError gracefully on manual plugin install

Ticket:	#6229