better fault checking in the stream definitions