diff options
author | anentropic <ego@anentropic.com> | 2014-02-03 14:19:42 +0000 |
---|---|---|
committer | anentropic <ego@anentropic.com> | 2014-02-03 14:19:42 +0000 |
commit | 595c47244b0bfce3023c14908c0cc6b6bb4e0aec (patch) | |
tree | 9eb5c5afbcb3ea8d7d8a49a4960a0ec128db9e76 /factory | |
parent | 420bd3703717623491e710cc63ba57fa1561ab8e (diff) | |
download | factory-boy-595c47244b0bfce3023c14908c0cc6b6bb4e0aec.tar factory-boy-595c47244b0bfce3023c14908c0cc6b6bb4e0aec.tar.gz |
Make safe repr more safe
Diffstat (limited to 'factory')
-rw-r--r-- | factory/utils.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/factory/utils.py b/factory/utils.py index 276977a..7b48a1e 100644 --- a/factory/utils.py +++ b/factory/utils.py @@ -101,7 +101,7 @@ def import_object(module_name, attribute_name): def _safe_repr(obj): try: obj_repr = repr(obj) - except UnicodeError: + except: return '<bad_repr object at %s>' % id(obj) try: # Convert to "text type" (= unicode) |