throw exception when json isn't returned