File: py3.9-fix.patch

package info (click to toggle)
python-boltons 19.1.0-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,184 kB
  • sloc: python: 11,411; makefile: 159
file content (35 lines) | stat: -rw-r--r-- 1,213 bytes parent folder | download
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
Description: Pull upstream fixes for python 3.9
Author: Nilesh Patra <npatra974@gmail.com>
Forwarded: not-needed
Last-Changed: Dec 16, 2020
--- a/boltons/dictutils.py
+++ b/boltons/dictutils.py
@@ -1029,7 +1029,7 @@
         "raises a TypeError, because FrozenDicts are immutable"
         raise TypeError('%s object is immutable' % self.__class__.__name__)
 
-    __setitem__ = __delitem__ = update = _raise_frozen_typeerror
+    __ior__ = __setitem__ = __delitem__ = update = _raise_frozen_typeerror
     setdefault = pop = popitem = clear = _raise_frozen_typeerror
 
     del _raise_frozen_typeerror
--- a/tests/test_dictutils.py
+++ b/tests/test_dictutils.py
@@ -1,5 +1,6 @@
 # -*- coding: utf-8 -*-
 
+import sys
 import pytest
 
 from boltons.dictutils import OMD, OneToOne, ManyToMany, FrozenDict, subdict, FrozenHashError
@@ -431,8 +432,10 @@
                        '__lt__',
                        '__ne__',
                        '__new__',
+                       '__or__',
                        '__reduce__',
                        '__reversed__',
+                       '__ror__',
                        '__setattr__',
                        '__sizeof__',
                        '__str__',