HUE 4.1 language setting problem

24 views
Skip to first unread message

Zhang Ruiqiang

unread,
Dec 2, 2017, 8:43:36 AM12/2/17
to hue-...@cloudera.org
Hi all:
    I'm a user of China. Afrer I installed Hue 4.1, I found that the default web page language is English, but my Chrome language is Chinese. In order to set the default language to Chinese, I modified desktop/core/src/desktop/settings.py, and set LANGUAGE_CODE=zh_CN. 
  I use '/usr/local/hue/build/env/bin/supervisor'  to start Hue service, and it seems everything is OK. But if I use  '/usr/local/hue/build/env/bin/supervisor -d' or user command 'nohup' to start Hue, https://github.com/cloudera/hue/blob/fdda56742631963925c92bc570fe5a9a8a441cb8/desktop/core/src/desktop/management/commands/runcherrypyserver.py#L121   will have a 'UnicodeEncdeError: 'ascii' codec can't encode characters in position 0-11: ordinal not in range(128)' error. 
    I add 'reload(sys) sys.setdefaultencoding('utf-8')'  at this file to solve this problem. Now, I want to know is there a better solution?

Thanks!


 



 

Romain Rigaux

unread,
Dec 4, 2017, 1:14:46 PM12/4/17
to Zhang Ruiqiang, hue-...@cloudera.org
How did you install Hue?

Browser Language should be automatically detected, if not it means 'make locales' was not run somehow. When using packaged version or tarball it should work out of the box.



 

--
You received this message because you are subscribed to the Google Groups "Hue-Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hue-user+unsubscribe@cloudera.org.

Zhang Ruiqiang

unread,
Dec 15, 2017, 5:22:05 AM12/15/17
to Romain Rigaux, hue-...@cloudera.org
Hi Romain:
     Sorry for replying so late. 
     I download the tarball from gethue.com, and extract the file, then execute "make apps; make install", and then use "/usr/local/hue/build/env/bin/supervisor" to start the server.  I try to run "make locales", but there is a error.


Thanks!
To unsubscribe from this group and stop receiving emails from it, send an email to hue-user+u...@cloudera.org.


 

Reply all
Reply to author
Forward
0 new messages