From cc70a9cd80b645674e5b2c5fe9f9e98c635362fb Mon Sep 17 00:00:00 2001
From: Jean-Paul Calderone <exarkun@twistedmatrix.com>
Date: Wed, 5 Jan 2022 14:27:33 -0500
Subject: [PATCH] Drop the workaround for the problem with older
 prometheus_client

---
 src/_zkapauthorizer/_storage_server.py | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/src/_zkapauthorizer/_storage_server.py b/src/_zkapauthorizer/_storage_server.py
index 73e4d55..b2e45e2 100644
--- a/src/_zkapauthorizer/_storage_server.py
+++ b/src/_zkapauthorizer/_storage_server.py
@@ -68,20 +68,6 @@ from .storage_common import (
     slot_testv_and_readv_and_writev_message,
 )
 
-
-# The last Python 2-supporting prometheus_client nevertheless tries to use
-# FileNotFoundError, an exception type from Python 3.  Since that release,
-# prometheus_client has dropped Python 2 support entirely so there is little
-# hope of ever having this fixed upstream.  When ZKAPAuthorizer is ported to
-# Python 3, this should no longer be necessary.
-def _prometheus_client_fix():
-    import prometheus_client.exposition
-
-    prometheus_client.exposition.FileNotFoundError = IOError
-
-
-_prometheus_client_fix()
-
 # See allmydata/storage/mutable.py
 SLOT_HEADER_SIZE = 468
 LEASE_TRAILER_SIZE = 4
-- 
GitLab