File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed
Misc/NEWS.d/next/Tools-Demos Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 1+ Make redemo work with Python 3.6 and newer versions.
2+
3+ In Python 3.6, flags like re.DOTALL became members of an enum.IntFlag so
4+ usages like ``getattr(re, 'DOTALL') `` are invalid.
5+
6+ Also, remove the ``LOCALE `` option since it doesn't work with string
7+ patterns in Python 3.
8+
9+ Patch by Christoph Sarnowski.
Original file line number Diff line number Diff line change @@ -75,15 +75,14 @@ def addoptions(self):
7575 self .boxes = []
7676 self .vars = []
7777 for name in ('IGNORECASE' ,
78- 'LOCALE' ,
7978 'MULTILINE' ,
8079 'DOTALL' ,
8180 'VERBOSE' ):
8281 if len (self .boxes ) % 3 == 0 :
8382 frame = Frame (self .master )
8483 frame .pack (fill = X )
8584 self .frames .append (frame )
86- val = getattr (re , name )
85+ val = getattr (re , name ). value
8786 var = IntVar ()
8887 box = Checkbutton (frame ,
8988 variable = var , text = name ,
You can’t perform that action at this time.
0 commit comments