from __future__ import absolute_import

from contextlib import contextmanager

from sentry.digests.backends.base import Backend


class DummyBackend(Backend):
    def add(self, key, record):
        pass

    @contextmanager
    def digest(self, key):
        yield []

    def schedule(self, deadline):
        return
        yield  # make this a generator

    def maintenance(self, deadline):
        pass

from __future__ import absolute_import

from contextlib import contextmanager

from sentry.digests.backends.base import Backend


class DummyBackend(Backend):
    def add(self, key, record, increment_delay=None, maximum_delay=None):
        pass

    @contextmanager
    def digest(self, key, minimum_delay=None):
        yield []

    def schedule(self, deadline):
        return
        yield  # make this a generator

    def maintenance(self, deadline):
        pass

Fix digests `DummyBackend` method signatures.
Fix digests `DummyBackend` method signatures.

This makes them consistent with the base backend API.

RIP @tkaemming, stung by dynamic typing.
