once more localizing folders



  • Hiho …
    … new user forgot to switch default lang in 1st start window to german.
    Now all foldernames are default english.

    Tried the python script from here but always get an error:

    root@kopano1:~# python localize-folders.py --user myuser --lang de_DE.UTF-8
    Localizing user: myuser
    Changing localized folder names to "de_DE.UTF-8"
    'ascii' codec can't decode byte 0xc3 in position 3: ordinal not in range(128)```
    

    locale on my debian stretch shows

    LANG=de_DE.UTF-8
    LANGUAGE=
    LC_CTYPE="de_DE.UTF-8"
    LC_NUMERIC="de_DE.UTF-8"
    LC_TIME="de_DE.UTF-8"
    LC_COLLATE="de_DE.UTF-8"
    LC_MONETARY="de_DE.UTF-8"
    LC_MESSAGES="de_DE.UTF-8"
    LC_PAPER="de_DE.UTF-8"
    LC_NAME="de_DE.UTF-8"
    LC_ADDRESS="de_DE.UTF-8"
    LC_TELEPHONE="de_DE.UTF-8"
    LC_MEASUREMENT="de_DE.UTF-8"
    LC_IDENTIFICATION="de_DE.UTF-8"
    LC_ALL=
    

    and

    kopano-locales are OK, i think

    root@kopano1:/# cat /etc/default/kopano | grep LOCALE
    KOPANO_LOCALE="de_DE.UTF-8"
    KOPANO_USERSCRIPT_LOCALE="de_DE.UTF-8"
    

    what am I missing?

    regards

    Rico



  • You nothing.

    This looks like a python2/3 bug.

    try python3 localize-folders.py --user myuser --lang de_DE.UTF-8


  • Kopano

    @El-Muchacho said in once more localizing folders:

    … new user forgot to switch default lang in 1st start window to german.
    Now all foldernames are default english.

    the “welcome screen” in WebApp does not have an influence on the folder names, as these are already created before the user logs in (when the user was created actually).

    @El-Muchacho said in once more localizing folders:

    what am I missing?

    Can you provide versions used? Are you using the latest version of the python script?



  • @fbartels said in once more localizing folders:

    Are you using the latest version of the python script?

    Think so … got it from here today

    @fbartels said in once more localizing folders:

    the “welcome screen” in WebApp does not have an influence on the folder names, as these are already created before the user logs in (when the user was created actually).

    OK … so I missed something while user-creation? Is there more than the KOPANO LOCALE settings needed in order to create the stores successfully in german?

    Yes ;) found it here
    created the admin.cfg in /etc/kopano and added default_store_locale = de_DE.UTF-8

    New users are now created successfully

    But the problem with some current users is still there.
    The script is not working for me.



  • @thctlo said in once more localizing folders:

    This looks like a python2/3 bug.
    try python3 localize-folders.py --user myuser --lang de_DE.UTF-8

    by using it with python3 i get

    root@kopano1:~# python3 localize-folders.py --user myuser --lang de_DE.UTF-8
    Traceback (most recent call last):
      File "localize-folders.py", line 9, in <module>
        import kopano
    ImportError: No module named 'kopano'
    

  • Kopano

    @El-Muchacho said in once more localizing folders:

    Is there more than the KOPANO LOCALE settings needed in order to create the stores successfully in german?

    yes this has changed in 8.6.8. see https://documentation.kopano.io/kopano_changelog/kc.html#kopano-core-8-6-8-8-6-8-0

    @El-Muchacho said in once more localizing folders:

    ImportError: No module named ‘kopano’

    you would then also need to have python3-kopano installed when calling the script.

    sadly you provide no information which kopano version you are using or in which os you are seeing this.



  • @fbartels said in once more localizing folders:

    sadly you provide no information which kopano version you are using or in which os you are seeing this.

    debian stretch … it’s in initial post ;)
    and currently still using kopano 8.6.9

    and btw : dry-run looks correct:

    root@kopano1:~# python localize-folders.py --u myuser --lang de_DE.UTF-8 --dry-run
    Localizing user: myuser
    Changing localized folder names to "de_DE.UTF-8"
    Running in dry mode no changes will be made
    Renaming MAPI Folder "junk" -> From "Spam" To "Spam"
    Renaming MAPI Folder "tasks" -> From "Aufgaben" To "Aufgaben"
    Renaming MAPI Folder "journal" -> From "Journal" To "Journal"
    Renaming MAPI Folder "wastebasket" -> From "Deleted Items" To "Gelöschte Objekte"
    Renaming MAPI Folder "inbox" -> From "Inbox" To "Posteingang"
    Renaming MAPI Folder "sentmail" -> From "Sent Items" To "Gesendete Objekte"
    Renaming MAPI Folder "outbox" -> From "Outbox" To "Postausgang"
    Renaming MAPI Folder "calendar" -> From "Calendar" To "Kalender"
    Renaming MAPI Folder "rss" -> From "RSS Feeds" To "RSS-Feeds"
    Renaming MAPI Folder "drafts" -> From "Drafts" To "Entwürfe"
    Renaming MAPI Folder "contacts" -> From "Contacts" To "Kontakte"
    Renaming MAPI Folder "notes" -> From "Notes" To "Notizen"
    Renaming MAPI Folder "suggested_contacts" -> From "Suggested Contacts" To "Vorgeschlagene Kontakte"
    


  • @El-Muchacho

    in /etc/apache2/envvars change:
    “export LANG=C”
    to
    “export LANG=de_DE.UTF-8”

    … after that:
    /etc/init.d/apache2 restart


Log in to reply