From bc2255dc188d1995be36f3c012bbdb2ed2720593 Mon Sep 17 00:00:00 2001 From: mdipierro Date: Sat, 2 May 2020 20:47:55 -0700 Subject: [PATCH] version 20200502.1, fixed IS_STRONG for py2 --- pydal/__init__.py | 2 +- pydal/validators.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pydal/__init__.py b/pydal/__init__.py index 5cb73c057..b7022fc90 100644 --- a/pydal/__init__.py +++ b/pydal/__init__.py @@ -1,4 +1,4 @@ -__version__ = "20200429.4" +__version__ = "20200502.1" from .base import DAL from .objects import Field diff --git a/pydal/validators.py b/pydal/validators.py index 0667391c8..8548b6968 100644 --- a/pydal/validators.py +++ b/pydal/validators.py @@ -4455,7 +4455,7 @@ def validate(self, value, record_id=None): numberset = frozenset(b"0123456789") sym1set = frozenset(b"!@#$%^&*() ") sym2set = frozenset(b"~`-_=+[]{}\\|;:'\",.<>?/") -otherset = frozenset(b"".join(chr(x).encode() for x in range(256))) +otherset = frozenset(b"".join(chr(x) if PY2 else chr(r).encode() for x in range(256))) def calc_entropy(string):