Problem importing "Supplier" when language is simplified Chinese (zh)

Whenever importing an Excel table in the Chinese system receiving the error “local variable ‘doctype’ referenced before assignment”

  • downloaded the template in right system language, added just mandatory fields → receiving error
  • when switching to English, downloading template, same mandatory field, same data → succesfull import
  • both in v10 and development branch of v11

I have the feeling there’s a problem caused by the default Simplified Chinese template since it’s working well in English system. Any suggestions how to fix or debug this problem further?

this is a bug, the pull request just submitted [Bug Fix] Data import from non EN language template failed by szufisher · Pull Request #5760 · frappe/frappe · GitHub

also you can try the below workaround
1.after change the user language, then log off the system
2. in the backend, clear the cache by sudo bench clear-cache, restart the server again
3. logon the system try upload again!

if still failed, please kindly change the downloaded template(Chinese Version) from 文档类型: back to Doctype:
and try again!

anyway, if the above pull request accepted and merged, hopefully it can work without above workaround needed!

the pull request already merged, may I know whether your reported issue resolved?