We could.  The panics were added as a way of forcing things to fail fast in
the prototyping phase.  It is my plan to remove them once we reach the
final parts of the review stage.
Am 08.03.2013 13:33 schrieb "juliusv" <notifications@github.com>:

> In storage/metric/memory.go:
>
> > +func (s stream) add(timestamp time.Time, value model.SampleValue) {
> > +	s.values.Set(skipListTime(timestamp), singletonValue(value))
> > +}
> > +
> > +func (s stream) forEach(decoder storage.RecordDecoder, filter storage.RecordFilter, operator storage.RecordOperator) (scannedEntireCorpus bool, err error) {
> > +	if s.values.Len() == 0 {
> > +		return
> > +	}
> > +	iterator := s.values.SeekToLast()
> > +
> > +	defer iterator.Close()
> > +
> > +	for !(iterator.Key() == nil || iterator.Value() == nil) {
> > +		decodedKey, decodeErr := decoder.DecodeKey(iterator.Key())
> > +		if decodeErr != nil {
> > +			continue
>
> should we make these panic()s instead?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/prometheus/prometheus/pull/84/files#r3304561>
> .
>