summaryrefslogtreecommitdiff
path: root/dev-python/pytables/files/pytables-3.6.1-py310.patch
blob: 600516d16396d4ef999e13e826bc5ba3ecc732a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
From 2431150d691f5ccdb3da204a46e346c156ea2523 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Mon, 16 Nov 2020 10:53:05 +0100
Subject: [PATCH] doctest: adjust __init__ TypeError formatting

Python3.10 includes the class name in the TypeError string for
__init__(), so the literal match does not work anymore.
---
 tables/atom.py    | 4 ++--
 tables/filters.py | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/tables/atom.py b/tables/atom.py
index 81d37c54..9cfd8609 100644
--- a/tables/atom.py
+++ b/tables/atom.py
@@ -569,10 +569,10 @@ class Atom(metaclass=MetaAtom):
             >>> atom3 = atom1.copy(shape=(2, 2))
             >>> print(atom3)
             Int32Atom(shape=(2, 2), dflt=0)
-            >>> atom1.copy(foobar=42)
+            >>> atom1.copy(foobar=42) #doctest: +ELLIPSIS
             Traceback (most recent call last):
             ...
-            TypeError: __init__() got an unexpected keyword argument 'foobar'
+            TypeError: ...__init__() got an unexpected keyword argument 'foobar'
 
         """
         newargs = self._get_init_args()
diff --git a/tables/filters.py b/tables/filters.py
index f809ce77..7cb9b02d 100644
--- a/tables/filters.py
+++ b/tables/filters.py
@@ -432,10 +432,10 @@ class Filters:
             Filters(complevel=0, shuffle=False, bitshuffle=False, fletcher32=False, least_significant_digit=None)
             >>> print(filters3)
             Filters(complevel=1, complib='zlib', shuffle=False, bitshuffle=False, fletcher32=False, least_significant_digit=None)
-            >>> filters1.copy(foobar=42)
+            >>> filters1.copy(foobar=42) #doctest: +ELLIPSIS
             Traceback (most recent call last):
             ...
-            TypeError: __init__() got an unexpected keyword argument 'foobar'
+            TypeError: ...__init__() got an unexpected keyword argument 'foobar'
 
         """
 
-- 
2.32.0