From 83ee3af698c328222c3c2cab8bdc60d71db600ee Mon Sep 17 00:00:00 2001 From: Jean-Paul Calderone <exarkun@twistedmatrix.com> Date: Thu, 28 May 2020 09:06:49 -0400 Subject: [PATCH] You can tell we make no effort because no effort is made. If SpendingController develops some internal state it should really remain internal, anyway. Don't make _plugin.py worry about this. --- src/_zkapauthorizer/_plugin.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/_zkapauthorizer/_plugin.py b/src/_zkapauthorizer/_plugin.py index 0315910..8f9b629 100644 --- a/src/_zkapauthorizer/_plugin.py +++ b/src/_zkapauthorizer/_plugin.py @@ -174,12 +174,6 @@ class ZKAPAuthorizer(object): from twisted.internet import reactor redeemer = self._get_redeemer(node_config, announcement, reactor) store = self._get_store(node_config) - - # Unlike our handling of the store, we make no effort to ensure there - # is only ever one SpendingController per database. - # SpendingController has no instance state so we can perfectly safely - # use several of them, pointing at the same underlying data set, - # concurrently without causing problems. controller = SpendingController.for_store( tokens_to_passes=redeemer.tokens_to_passes, store=store, -- GitLab