Issue with get-untranslated bench command

Hi all,

I am trying to translate a custom app written originally in English.
I have issues running the bench get-untranslated fr /home/frappe/frappe-bench/apps/myapp/ command as it returns killed

I tried to point to the translations file directly but then I get an error message:
bench get-untranslated fr /home/frappe/frappe-bench/apps/myapp/myapp/translations/fr.csv

/home/frappe/frappe-bench/apps/frappe/frappe/translate.py:450: UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them as being unequal
  if dontwalk in folders: folders.remove(dontwalk)
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/home/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 79, in <module>
    main()
  File "/home/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 16, in main
    click.Group(commands=commands)(prog_name='bench')
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 722, in __call__
    return self.main(*args, **kwargs)
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 697, in main
    rv = self.invoke(ctx)
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 1066, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 1066, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 895, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 535, in invoke
    return callback(*args, **kwargs)
  File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/decorators.py", line 17, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/home/frappe/frappe-bench/apps/frappe/frappe/commands/__init__.py", line 24, in _func
    ret = f(frappe._dict(ctx.obj), *args, **kwargs)
  File "/home/frappe/frappe-bench/apps/frappe/frappe/commands/translate.py", line 50, in get_untranslated
    frappe.translate.get_untranslated(lang, untranslated_file, get_all=all)
  File "/home/frappe/frappe-bench/apps/frappe/frappe/translate.py", line 576, in get_untranslated
    messages.extend(get_messages_for_app(app))
  File "/home/frappe/frappe-bench/apps/frappe/frappe/translate.py", line 306, in get_messages_for_app
    messages.extend(get_server_messages(app))
  File "/home/frappe/frappe-bench/apps/frappe/frappe/translate.py", line 453, in get_server_messages
    if f.endswith(".py") or f.endswith(".html") or f.endswith(".js"):
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 5: ordinal not in range(128)

I get the same message when running bench get-untranslated fr /home/frappe/frappe-bench/apps/erpnext/ for example.

I am obviously missing something in the way this command should be run and any help would be welcome.

Thanks a lot!

It was indeed obvious, I had a folder with a french name (and accent) in an other app that caused the issue :frowning: