PostgreSQL Bugs

Collected from the PG bugs email list.

Bug ID15417
PG Version10.5
OSlinux
Opened2018-10-03 12:32:56+00
Reported byHossein Keramati
StatusNew

Body of first available message related to this bug follows.

The following bug has been logged on the website:

Bug reference:      15417
Logged by:          Hossein Keramati
Email address:      (redacted)
PostgreSQL version: 10.5
Operating system:   linux
Description:        

I have a django application on server that use postgresql database with UTF8
encoding and C.UTF8 for collation and ctype and on my localhost I use
sqlite3 as database.
I put some Persian characters on my database and it works properly on my
localhost but on server when I send a request it works for some models of my
database and doesn't work for some other, with this error:
" 'ascii' codec can't encode characters ".

I tried with different collation and ctype including fa_IR.UTF8 but the
result was worse. 
All of my controllers follow same logic and methods and I can't understand
how it's possible to work for some controllers and don't work for others.

what's the solution?

---
my pip freeze:
Django==2.0.7
gunicorn==19.9.0
mysqlclient==1.3.13
psycopg2==2.7.5
psycopg2-binary==2.7.5
pytz==2018.5
uWSGI==2.0.17.1

Thank You <3

Hossein Keramati Tavallaei

Messages

DateAuthorSubject
2018-10-03 12:32:56+00=?utf-8?q?PG_Bug_reporting_form?=BUG #15417: 'ascii' codec can't encode characters