File python-faker-use-unidecode.patch of Package python-faker
From 3aa2308d967087f9d535d2e3f1b72185ed033f46 Mon Sep 17 00:00:00 2001
From: Oleg Girko <ol@infoserver.lv>
Date: Fri, 26 Apr 2019 17:15:46 +0100
Subject: [PATCH] Revert "Close #628. Switch to text-unidecode"
This reverts commit e32a0cd73d7e1f42e12593bf6024ba7607454f54.
The text-unidecode package is released under Artistic license that is
not an approved opensource license.
Hence, it can't be shipped with opensource Linux distributions
like Fedora.
Depending on unidecode package that is under GPL is OK, though.
---
faker/providers/internet/__init__.py | 4 ++--
setup.py | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/faker/providers/internet/__init__.py b/faker/providers/internet/__init__.py
index 282fe96..1e56601 100644
--- a/faker/providers/internet/__init__.py
+++ b/faker/providers/internet/__init__.py
@@ -1,7 +1,7 @@
# coding=utf-8
from __future__ import unicode_literals
-from text_unidecode import unidecode
+import unidecode
from .. import BaseProvider
@@ -125,7 +125,7 @@ class Provider(BaseProvider):
for search, replace in self.replacements:
string = string.replace(search, replace)
- string = unidecode(string)
+ string = unidecode.unidecode(string)
return string
@lowercase
diff --git a/setup.py b/setup.py
index 2f3831a..dca0003 100644
--- a/setup.py
+++ b/setup.py
@@ -66,7 +66,7 @@ setup(
install_requires=[
"python-dateutil>=2.4",
"six>=1.10",
- "text-unidecode==1.2",
+ "unidecode",
],
tests_require=[
"email_validator>=1.0.1,<1.1.0",
--
2.20.1