bpo-37394: Fix pure Python implementation of the queue module (GH-14351)

(cherry picked from commit 3f5b9088b0ed08e1442cca37df78f609d5cd8c3c)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
diff --git a/Lib/queue.py b/Lib/queue.py
index ef07957..5bb0431 100644
--- a/Lib/queue.py
+++ b/Lib/queue.py
@@ -14,7 +14,7 @@
 
 try:
     from _queue import Empty
-except AttributeError:
+except ImportError:
     class Empty(Exception):
         'Exception raised by Queue.get(block=0)/get_nowait().'
         pass