As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
—
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last):
File “/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py”, line 47, in
uploadfile
ret = frappe.utils.file_manager.upload()
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line 33, in upload
filedata = save_uploaded(dt, dn)
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line 52, in save_uploaded
return save_file(fname, content, dt, dn);
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line 118, in save_file
fname = get_file_name(fname, content_hash[-6:])
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line 254, in get_file_name
if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
File “/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py”, line 18,
in exists
os.stat(path)
UnicodeEncodeError: ‘ascii’ codec can’t encode characters in position 58-64:
ordinal not in range(128)
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on this
forum by a team (https://frappe.io/webnotes). So please consider donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as much
information as you can. Please see it from the point of view of the person
receiving the communication.
For sending images, use http://imgur.com or other similar services. Do
not send images as attachments. Links are good. Same goes for any file you
are going to send.
above is the file name, it is local file name in chinese.
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
—
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
above is the file name, it is local file name in chinese.
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
-- Note:
If you are posting an issue,
1. ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful. 2. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication. 3. Paste your code athttp://pastebin.comorhttp://gist.github.comand send only the URL via email 4. For sending images, usehttp://imgur.comor other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
—
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
above is the file name, it is local file name in chinese.
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last):
File “/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py”, line 47,
in uploadfile
ret = frappe.utils.file_manager.upload()
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”, line
33, in upload
filedata = save_uploaded(dt, dn)
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”, line
52, in save_uploaded
return save_file(fname, content, dt, dn);
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”, line
118, in save_file
fname = get_file_name(fname, content_hash[-6:])
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”, line
254, in get_file_name
if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
File “/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py”, line
18, in exists
os.stat(path)
UnicodeEncodeError: ‘ascii’ codec can’t encode characters in position
58-64: ordinal not in range(128)
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on this
forum by a team (https://frappe.io/webnotes). So please consider donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as much
information as you can. Please see it from the point of view of the person
receiving the communication.
For sending images, use http://imgur.com or other similar services. Do
not send images as attachments. Links are good. Same goes for any file you
are going to send.
ERPNext is a free and open source software and support is given on this
forum by a team (https://frappe.io/webnotes). So please consider donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as much
information as you can. Please see it from the point of view of the person
receiving the communication.
For sending images, use http://imgur.com or other similar services. Do
not send images as attachments. Links are good. Same goes for any file you
are going to send.
mine is 2.7.3, maybe it's time to re-setup from scratch. will update. thanks.
在 2014年9月18日星期四UTC+8下午1时14分42秒,Pratik Vyas写道:
On Thu, Sep 18, 2014 at 10:18 AM, Rushabh Mehta <rm...@gmail.com> wrote:
> That file name works for me too....
>
> I am running Python 2.7.5
>
> @Pratik any clue?
>
>
>
> @rushabh_mehta
> https://erpnext.com >
> On 17-Sep-2014, at 1:04 pm, Y Y <ya...@gmail.com> wrote:
>
> 新东方名师推荐BEC词汇.doc
>
> above is the file name, it is local file name in chinese.
>
>
> 在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
>>
>> As subject. if file name is local language. Please suggest how to fix.
>>
>> Traceback (innermost last):
>> File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47,
>> in uploadfile
>> ret = frappe.utils.file_manager.upload()
>> File
>> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line
>> 33, in upload
>> filedata = save_uploaded(dt, dn)
>> File
>> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line
>> 52, in save_uploaded
>> return save_file(fname, content, dt, dn);
>> File
>> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line
>> 118, in save_file
>> fname = get_file_name(fname, content_hash[-6:])
>> File
>> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line
>> 254, in get_file_name
>> if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
>> File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line
>> 18, in exists
>> os.stat(path)
>> UnicodeEncodeError: 'ascii' codec can't encode characters in position
>> 58-64: ordinal not in range(128)
>
>
> --
> Note:
>
> If you are posting an issue,
>
> 1. ERPNext is a free and open source software and support is given on this
> forum by a team (https://frappe.io/webnotes). So please consider donating if
> you find this forum useful (https://frappe.io/buy). Even a small amount
> would be helpful.
> 2. We should be able to replicate it at our end. So please give us as much
> information as you can. Please see it from the point of view of the person
> receiving the communication.
> 3. Paste your code at http://pastebin.com or http://gist.github.com and send
> only the URL via email
> 4. For sending images, use http://imgur.com or other similar services. Do
> not send images as attachments. Links are good. Same goes for any file you
> are going to send.
>
> End of Note
> ---
> You received this message because you are subscribed to the Google Groups
> "ERPNext Developer Forum" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to erpnext-developer-forum+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/erpnext-developer-forum/079433d5-896c-4dde-9a1b-fee98883da9b%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> Note:
>
> If you are posting an issue,
>
> 1. ERPNext is a free and open source software and support is given on this
> forum by a team (https://frappe.io/webnotes). So please consider donating if
> you find this forum useful (https://frappe.io/buy). Even a small amount
> would be helpful.
> 2. We should be able to replicate it at our end. So please give us as much
> information as you can. Please see it from the point of view of the person
> receiving the communication.
> 3. Paste your code at http://pastebin.com or http://gist.github.com and send
> only the URL via email
> 4. For sending images, use http://imgur.com or other similar services. Do
> not send images as attachments. Links are good. Same goes for any file you
> are going to send.
>
> End of Note
> ---
> You received this message because you are subscribed to the Google Groups
> "ERPNext Developer Forum" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to erpnext-developer-forum+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/erpnext-developer-forum/BD9344FE-5A81-4A97-88E9-FB751324209B%40gmail.com.
>
> For more options, visit https://groups.google.com/d/optout.
ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
—
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line 254, in get_file_name
if len(n_records) > 0 or os.path.exists(get_files_path(fname))
Can you try changing that line to
if len(n_records) > 0 or os.path.exists(get_files_path(fname.encode(‘utf-8’)))
On Thu, Sep 18, 2014 at 11:01 AM, Y Y ya...@gmail.com wrote:
mine is 2.7.3, maybe it’s time to re-setup from scratch. will update.
thanks.
在 2014年9月18日星期四UTC+8下午1时14分42秒,Pratik Vyas写道:
On Thu, Sep 18, 2014 at 10:18 AM, Rushabh Mehta rm...@gmail.com wrote:
above is the file name, it is local file name in chinese.
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last):
File “/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py”, line
47,
in uploadfile
ret = frappe.utils.file_manager.upload()
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
33, in upload
filedata = save_uploaded(dt, dn)
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
52, in save_uploaded
return save_file(fname, content, dt, dn);
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
118, in save_file
fname = get_file_name(fname, content_hash[-6:])
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
254, in get_file_name
if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
File “/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py”,
line
18, in exists
os.stat(path)
UnicodeEncodeError: ‘ascii’ codec can’t encode characters in position
58-64: ordinal not in range(128)
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on
this
forum by a team (https://frappe.io/webnotes). So please consider
donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as
much
information as you can. Please see it from the point of view of the
person
receiving the communication.
For sending images, use http://imgur.com or other similar services.
Do
not send images as attachments. Links are good. Same goes for any file
you
are going to send.
End of Note
You received this message because you are subscribed to the Google
Groups
“ERPNext Developer Forum” group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to erpnext-developer-forum+un...@googlegroups.com.
To view this discussion on the web visit
ERPNext is a free and open source software and support is given on
this
forum by a team (https://frappe.io/webnotes). So please consider
donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as
much
information as you can. Please see it from the point of view of the
person
receiving the communication.
For sending images, use http://imgur.com or other similar services.
Do
not send images as attachments. Links are good. Same goes for any file
you
are going to send.
End of Note
You received this message because you are subscribed to the Google
Groups
“ERPNext Developer Forum” group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to erpnext-developer-forum+un...@googlegroups.com.
To view this discussion on the web visit
ERPNext is a free and open source software and support is given on this
forum by a team (https://frappe.io/webnotes). So please consider donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as much
information as you can. Please see it from the point of view of the person
receiving the communication.
For sending images, use http://imgur.com or other similar services. Do
not send images as attachments. Links are good. Same goes for any file you
are going to send.
On Thu, Sep 18, 2014 at 3:20 PM, Pratik Vyas pd...@gmail.com wrote:
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line 254, in get_file_name
if len(n_records) > 0 or os.path.exists(get_files_path(fname))
Can you try changing that line to
if len(n_records) > 0 or os.path.exists(get_files_path(fname.encode(‘utf-8’)))
On Thu, Sep 18, 2014 at 11:01 AM, Y Y ya...@gmail.com wrote:
mine is 2.7.3, maybe it’s time to re-setup from scratch. will update.
thanks.
在 2014年9月18日星期四UTC+8下午1时14分42秒,Pratik Vyas写道:
On Thu, Sep 18, 2014 at 10:18 AM, Rushabh Mehta rm...@gmail.com wrote:
above is the file name, it is local file name in chinese.
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last):
File “/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py”, line
47,
in uploadfile
ret = frappe.utils.file_manager.upload()
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
33, in upload
filedata = save_uploaded(dt, dn)
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
52, in save_uploaded
return save_file(fname, content, dt, dn);
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
118, in save_file
fname = get_file_name(fname, content_hash[-6:])
File
“/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py”,
line
254, in get_file_name
if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
File “/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py”,
line
18, in exists
os.stat(path)
UnicodeEncodeError: ‘ascii’ codec can’t encode characters in position
58-64: ordinal not in range(128)
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on
this
forum by a team (https://frappe.io/webnotes). So please consider
donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as
much
information as you can. Please see it from the point of view of the
person
receiving the communication.
For sending images, use http://imgur.com or other similar services.
Do
not send images as attachments. Links are good. Same goes for any file
you
are going to send.
End of Note
You received this message because you are subscribed to the Google
Groups
“ERPNext Developer Forum” group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to erpnext-developer-forum+un...@googlegroups.com.
To view this discussion on the web visit
ERPNext is a free and open source software and support is given on
this
forum by a team (https://frappe.io/webnotes). So please consider
donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as
much
information as you can. Please see it from the point of view of the
person
receiving the communication.
For sending images, use http://imgur.com or other similar services.
Do
not send images as attachments. Links are good. Same goes for any file
you
are going to send.
End of Note
You received this message because you are subscribed to the Google
Groups
“ERPNext Developer Forum” group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to erpnext-developer-forum+un...@googlegroups.com.
To view this discussion on the web visit
ERPNext is a free and open source software and support is given on this
forum by a team (https://frappe.io/webnotes). So please consider donating if
you find this forum useful (https://frappe.io/buy). Even a small amount
would be helpful.
We should be able to replicate it at our end. So please give us as much
information as you can. Please see it from the point of view of the person
receiving the communication.
For sending images, use http://imgur.com or other similar services. Do
not send images as attachments. Links are good. Same goes for any file you
are going to send.
On Thu, Sep 18, 2014 at 3:20 PM, Pratik Vyas <pd...@gmail.com> wrote:
> File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
> line 254, in get_file_name
> if len(n_records) > 0 or os.path.exists(get_files_path(fname))
>
> Can you try changing that line to
>
> if len(n_records) > 0 or os.path.exists(get_files_path(fname.encode('utf-8')))
>
> On Thu, Sep 18, 2014 at 11:01 AM, Y Y <ya...@gmail.com> wrote:
>> mine is 2.7.3, maybe it's time to re-setup from scratch. will update.
>> thanks.
>>
>> 在 2014年9月18日星期四UTC+8下午1时14分42秒,Pratik Vyas写道:
>>>
>>> On Thu, Sep 18, 2014 at 10:18 AM, Rushabh Mehta <rm...@gmail.com> wrote:
>>> > That file name works for me too....
>>> >
>>> > I am running Python 2.7.5
>>> >
>>> > @Pratik any clue?
>>> >
>>> >
>>> >
>>> > @rushabh_mehta
>>> > https://erpnext.com >>> >
>>> > On 17-Sep-2014, at 1:04 pm, Y Y <ya...@gmail.com> wrote:
>>> >
>>> > 新东方名师推荐BEC词汇.doc
>>> >
>>> > above is the file name, it is local file name in chinese.
>>> >
>>> >
>>> > 在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
>>> >>
>>> >> As subject. if file name is local language. Please suggest how to fix.
>>> >>
>>> >> Traceback (innermost last):
>>> >> File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line
>>> >> 47,
>>> >> in uploadfile
>>> >> ret = frappe.utils.file_manager.upload()
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 33, in upload
>>> >> filedata = save_uploaded(dt, dn)
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 52, in save_uploaded
>>> >> return save_file(fname, content, dt, dn);
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 118, in save_file
>>> >> fname = get_file_name(fname, content_hash[-6:])
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 254, in get_file_name
>>> >> if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
>>> >> File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py",
>>> >> line
>>> >> 18, in exists
>>> >> os.stat(path)
>>> >> UnicodeEncodeError: 'ascii' codec can't encode characters in position
>>> >> 58-64: ordinal not in range(128)
>>> >
>>> >
>>> > --
>>> > Note:
>>> >
>>> > If you are posting an issue,
>>> >
>>> > 1. ERPNext is a free and open source software and support is given on
>>> > this
>>> > forum by a team (https://frappe.io/webnotes). So please consider
>>> > donating if
>>> > you find this forum useful (https://frappe.io/buy). Even a small amount
>>> > would be helpful.
>>> > 2. We should be able to replicate it at our end. So please give us as
>>> > much
>>> > information as you can. Please see it from the point of view of the
>>> > person
>>> > receiving the communication.
>>> > 3. Paste your code at http://pastebin.com or http://gist.github.com and
>>> > send
>>> > only the URL via email
>>> > 4. For sending images, use http://imgur.com or other similar services.
>>> > Do
>>> > not send images as attachments. Links are good. Same goes for any file
>>> > you
>>> > are going to send.
>>> >
>>> > End of Note
>>> > ---
>>> > You received this message because you are subscribed to the Google
>>> > Groups
>>> > "ERPNext Developer Forum" group.
>>> > To unsubscribe from this group and stop receiving emails from it, send
>>> > an
>>> > email to erpnext-developer-forum+un...@googlegroups.com.
>>> > To view this discussion on the web visit
>>> >
>>> > https://groups.google.com/d/msgid/erpnext-developer-forum/079433d5-896c-4dde-9a1b-fee98883da9b%40googlegroups.com.
>>> > For more options, visit https://groups.google.com/d/optout.
>>> >
>>> >
>>> > --
>>> > Note:
>>> >
>>> > If you are posting an issue,
>>> >
>>> > 1. ERPNext is a free and open source software and support is given on
>>> > this
>>> > forum by a team (https://frappe.io/webnotes). So please consider
>>> > donating if
>>> > you find this forum useful (https://frappe.io/buy). Even a small amount
>>> > would be helpful.
>>> > 2. We should be able to replicate it at our end. So please give us as
>>> > much
>>> > information as you can. Please see it from the point of view of the
>>> > person
>>> > receiving the communication.
>>> > 3. Paste your code at http://pastebin.com or http://gist.github.com and
>>> > send
>>> > only the URL via email
>>> > 4. For sending images, use http://imgur.com or other similar services.
>>> > Do
>>> > not send images as attachments. Links are good. Same goes for any file
>>> > you
>>> > are going to send.
>>> >
>>> > End of Note
>>> > ---
>>> > You received this message because you are subscribed to the Google
>>> > Groups
>>> > "ERPNext Developer Forum" group.
>>> > To unsubscribe from this group and stop receiving emails from it, send
>>> > an
>>> > email to erpnext-developer-forum+un...@googlegroups.com.
>>> > To view this discussion on the web visit
>>> >
>>> > https://groups.google.com/d/msgid/erpnext-developer-forum/BD9344FE-5A81-4A97-88E9-FB751324209B%40gmail.com.
>>> >
>>> > For more options, visit https://groups.google.com/d/optout.
>>>
>>> No idea,
>>>
>>> worked on demo.frappecloud.com too
>>>
>>> curl
>>> https://demo.frappecloud.com/files/%E6%96%B0%E4%B8%9C%E6%96%B9%E5%90%8D%E5%B8%88%E6%8E%A8%E8%8D%90BEC%E8%AF%8D%E6%B1%87762117.doc >>>
>>>
>>> --
>>> Pratik
>>> erpnext
>>
>> --
>> Note:
>>
>> If you are posting an issue,
>>
>> 1. ERPNext is a free and open source software and support is given on this
>> forum by a team (https://frappe.io/webnotes). So please consider donating if
>> you find this forum useful (https://frappe.io/buy). Even a small amount
>> would be helpful.
>> 2. We should be able to replicate it at our end. So please give us as much
>> information as you can. Please see it from the point of view of the person
>> receiving the communication.
>> 3. Paste your code at http://pastebin.com or http://gist.github.com and send
>> only the URL via email
>> 4. For sending images, use http://imgur.com or other similar services. Do
>> not send images as attachments. Links are good. Same goes for any file you
>> are going to send.
>>
>> End of Note
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "ERPNext Developer Forum" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to erpnext-developer-forum+un...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/erpnext-developer-forum/d38ada52-728f-4d97-afef-0de5217719c5%40googlegroups.com.
>>
>> For more options, visit https://groups.google.com/d/optout.
>
>
>
> --
> Pratik
> erpnext
--
Pratik
erpnext
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
—
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
On Thu, Sep 18, 2014 at 3:20 PM, Pratik Vyas <pd...@gmail.com> wrote:
> File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
> line 254, in get_file_name
> if len(n_records) > 0 or os.path.exists(get_files_path(fname))
>
> Can you try changing that line to
>
> if len(n_records) > 0 or os.path.exists(get_files_path(fname.encode('utf-8')))
>
> On Thu, Sep 18, 2014 at 11:01 AM, Y Y <ya...@gmail.com> wrote:
>> mine is 2.7.3, maybe it's time to re-setup from scratch. will update.
>> thanks.
>>
>> 在 2014年9月18日星期四UTC+8下午1时14分42秒,Pratik Vyas写道:
>>>
>>> On Thu, Sep 18, 2014 at 10:18 AM, Rushabh Mehta <rm...@gmail.com> wrote:
>>> > That file name works for me too....
>>> >
>>> > I am running Python 2.7.5
>>> >
>>> > @Pratik any clue?
>>> >
>>> >
>>> >
>>> > @rushabh_mehta
>>> > https://erpnext.com >>> >
>>> > On 17-Sep-2014, at 1:04 pm, Y Y <ya...@gmail.com> wrote:
>>> >
>>> > 新东方名师推荐BEC词汇.doc
>>> >
>>> > above is the file name, it is local file name in chinese.
>>> >
>>> >
>>> > 在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
>>> >>
>>> >> As subject. if file name is local language. Please suggest how to fix.
>>> >>
>>> >> Traceback (innermost last):
>>> >> File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line
>>> >> 47,
>>> >> in uploadfile
>>> >> ret = frappe.utils.file_manager.upload()
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 33, in upload
>>> >> filedata = save_uploaded(dt, dn)
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 52, in save_uploaded
>>> >> return save_file(fname, content, dt, dn);
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 118, in save_file
>>> >> fname = get_file_name(fname, content_hash[-6:])
>>> >> File
>>> >> "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py",
>>> >> line
>>> >> 254, in get_file_name
>>> >> if len(n_records) > 0 or os.path.exists(get_files_path(fname)):
>>> >> File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py",
>>> >> line
>>> >> 18, in exists
>>> >> os.stat(path)
>>> >> UnicodeEncodeError: 'ascii' codec can't encode characters in position
>>> >> 58-64: ordinal not in range(128)
>>> >
>>> >
>>> > --
>>> > Note:
>>> >
>>> > If you are posting an issue,
>>> >
>>> > 1. ERPNext is a free and open source software and support is given on
>>> > this
>>> > forum by a team (https://frappe.io/webnotes). So please consider
>>> > donating if
>>> > you find this forum useful (https://frappe.io/buy). Even a small amount
>>> > would be helpful.
>>> > 2. We should be able to replicate it at our end. So please give us as
>>> > much
>>> > information as you can. Please see it from the point of view of the
>>> > person
>>> > receiving the communication.
>>> > 3. Paste your code at http://pastebin.com or http://gist.github.com and
>>> > send
>>> > only the URL via email
>>> > 4. For sending images, use http://imgur.com or other similar services.
>>> > Do
>>> > not send images as attachments. Links are good. Same goes for any file
>>> > you
>>> > are going to send.
>>> >
>>> > End of Note
>>> > ---
>>> > You received this message because you are subscribed to the Google
>>> > Groups
>>> > "ERPNext Developer Forum" group.
>>> > To unsubscribe from this group and stop receiving emails from it, send
>>> > an
>>> > email to erpnext-developer-forum+un...@googlegroups.com.
>>> > To view this discussion on the web visit
>>> >
>>> > https://groups.google.com/d/msgid/erpnext-developer-forum/079433d5-896c-4dde-9a1b-fee98883da9b%40googlegroups.com.
>>> > For more options, visit https://groups.google.com/d/optout.
>>> >
>>> >
>>> > --
>>> > Note:
>>> >
>>> > If you are posting an issue,
>>> >
>>> > 1. ERPNext is a free and open source software and support is given on
>>> > this
>>> > forum by a team (https://frappe.io/webnotes). So please consider
>>> > donating if
>>> > you find this forum useful (https://frappe.io/buy). Even a small amount
>>> > would be helpful.
>>> > 2. We should be able to replicate it at our end. So please give us as
>>> > much
>>> > information as you can. Please see it from the point of view of the
>>> > person
>>> > receiving the communication.
>>> > 3. Paste your code at http://pastebin.com or http://gist.github.com and
>>> > send
>>> > only the URL via email
>>> > 4. For sending images, use http://imgur.com or other similar services.
>>> > Do
>>> > not send images as attachments. Links are good. Same goes for any file
>>> > you
>>> > are going to send.
>>> >
>>> > End of Note
>>> > ---
>>> > You received this message because you are subscribed to the Google
>>> > Groups
>>> > "ERPNext Developer Forum" group.
>>> > To unsubscribe from this group and stop receiving emails from it, send
>>> > an
>>> > email to erpnext-developer-forum+un...@googlegroups.com.
>>> > To view this discussion on the web visit
>>> >
>>> > https://groups.google.com/d/msgid/erpnext-developer-forum/BD9344FE-5A81-4A97-88E9-FB751324209B%40gmail.com.
>>> >
>>> > For more options, visit https://groups.google.com/d/optout.
>>>
>>> No idea,
>>>
>>> worked on demo.frappecloud.com too
>>>
>>> curl
>>> https://demo.frappecloud.com/files/%E6%96%B0%E4%B8%9C%E6%96%B9%E5%90%8D%E5%B8%88%E6%8E%A8%E8%8D%90BEC%E8%AF%8D%E6%B1%87762117.doc >>>
>>>
>>> --
>>> Pratik
>>> erpnext
>>
>> --
>> Note:
>>
>> If you are posting an issue,
>>
>> 1. ERPNext is a free and open source software and support is given on this
>> forum by a team (https://frappe.io/webnotes). So please consider donating if
>> you find this forum useful (https://frappe.io/buy). Even a small amount
>> would be helpful.
>> 2. We should be able to replicate it at our end. So please give us as much
>> information as you can. Please see it from the point of view of the person
>> receiving the communication.
>> 3. Paste your code at http://pastebin.com or http://gist.github.com and send
>> only the URL via email
>> 4. For sending images, use http://imgur.com or other similar services. Do
>> not send images as attachments. Links are good. Same goes for any file you
>> are going to send.
>>
>> End of Note
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "ERPNext Developer Forum" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to erpnext-developer-forum+un...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/erpnext-developer-forum/d38ada52-728f-4d97-afef-0de5217719c5%40googlegroups.com.
>>
>> For more options, visit https://groups.google.com/d/optout.
>
>
>
> --
> Pratik
> erpnext
--
Pratik
erpnext
–
Note:
If you are posting an issue,
ERPNext is a free and open source software and support is given on this forum by a team (https://frappe.io/webnotes). So please consider donating if you find this forum useful (https://frappe.io/buy). Even a small amount would be helpful.
We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.
End of Note
—
You received this message because you are subscribed to the Google Groups "ERPNext Developer Forum" group.
In my VM, i enter into python console, then show sys.getdefaultencoding(), result is: ascii
I think that's the issue. why would happens to that, i used same installation setup(via bench).
any simple solution for this?
Thanks,
Yang
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
It is supposed to be ascii by default and it should still work like in my system. Is your bench folder name or some other folder in hierarchy contain non English names?
-Anand
On Monday, September 22, 2014, Y Y <ya…@gmail.com> wrote:
Dear Team,
In my VM, i enter into python console, then show sys.getdefaultencoding(), result is: ascii
I think that's the issue. why would happens to that, i used same installation setup(via bench).
any simple solution for this?
Thanks,
Yang
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
I fixed that..., It shall be get_files_path(fname).encode('utf-8') haha...
在 2014年9月22日星期一UTC+8下午9时37分01秒,Anand Doshi写道:
It is supposed to be ascii by default and it should still work like in my system. Is your bench folder name or some other folder in hierarchy contain non English names?
In my VM, i enter into python console, then show sys.getdefaultencoding(), result is: ascii
I think that's the issue. why would happens to that, i used same installation setup(via bench).
any simple solution for this?
Thanks,
Yang
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
I fixed that..., It shall be get_files_path(fname).encode('utf-8') haha...
在 2014年9月22日星期一UTC+8下午9时37分01秒,Anand Doshi写道:
It is supposed to be ascii by default and it should still work like in my system. Is your bench folder name or some other folder in hierarchy contain non English names?
In my VM, i enter into python console, then show sys.getdefaultencoding(), result is: ascii
I think that's the issue. why would happens to that, i used same installation setup(via bench).
any simple solution for this?
Thanks,
Yang
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
I fixed that..., It shall be get_files_path(fname).encode('utf-8') haha...
在 2014年9月22日星期一UTC+8下午9时37分01秒,Anand Doshi写道:
It is supposed to be ascii by default and it should still work like in my system. Is your bench folder name or some other folder in hierarchy contain non English names?
In my VM, i enter into python console, then show sys.getdefaultencoding(), result is: ascii
I think that's the issue. why would happens to that, i used same installation setup(via bench).
any simple solution for this?
Thanks,
Yang
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)
I fixed that..., It shall be get_files_path(fname).encode('utf-8') haha...
在 2014年9月22日星期一UTC+8下午9时37分01秒,Anand Doshi写道:
It is supposed to be ascii by default and it should still work like in my system. Is your bench folder name or some other folder in hierarchy contain non English names?
In my VM, i enter into python console, then show sys.getdefaultencoding(), result is: ascii
I think that's the issue. why would happens to that, i used same installation setup(via bench).
any simple solution for this?
Thanks,
Yang
在 2014年9月17日星期三UTC+8上午10时46分18秒,Y Y写道:
As subject. if file name is local language. Please suggest how to fix.
Traceback (innermost last): File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 47, in uploadfile ret = frappe.utils.file_manager.upload() File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 33, in upload filedata = save_uploaded(dt, dn) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 52, in save_uploaded return save_file(fname, content, dt, dn); File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 118, in save_file fname = get_file_name(fname, content_hash[-6:]) File "/home/erpnext/frappe-bench/apps/frappe/frappe/utils/file_manager.py", line 254, in get_file_name if len(n_records) > 0 or os.path.exists(get_files_path(fname)): File "/home/erpnext/frappe-bench/env/lib/python2.7/genericpath.py", line 18, in exists os.stat(path) UnicodeEncodeError: 'ascii' codec can't encode characters in position 58-64: ordinal not in range(128)