Re: [web2py] Re: json.loads with cyrillic string

2019-06-04 Thread Константин Комков
Val K, yes, but I get json string from client js.

вт, 4 июн. 2019 г., 17:01 Val K :

> it is maybe not convenient when storing json as text file, to solve this
> you can pass ensure_ascii=False to json.dumps
>
> --
> Resources:
> - http://web2py.com
> - http://web2py.com/book (Documentation)
> - http://github.com/web2py/web2py (Source code)
> - https://code.google.com/p/web2py/issues/list (Report Issues)
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "web2py-users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/web2py/Jf0nxpP6w2M/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> web2py+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/ef98ecd7-0a13-49f7-b982-b4b5c7acbce2%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAM7z-VkdDPdCW3jx%3D3L4Qcu0NVSTW0rGE5B_HKYV0-12zHTdaw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: json.loads with cyrillic string

2019-06-04 Thread Val K
it is maybe not convenient when storing json as text file, to solve this you 
can pass ensure_ascii=False to json.dumps

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/ef98ecd7-0a13-49f7-b982-b4b5c7acbce2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: json.loads with cyrillic string

2019-06-04 Thread Val K
In python2 it is so

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/a6dd7be4-eff8-4291-98f5-a26f16e8bde7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[web2py] Re: json.loads with cyrillic string

2019-06-04 Thread Константин Комков
Now is nothing, but I thought if I do b.get('fac')[0] I got something like 
u'\u0421\u0430\u0434\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0430 
\u0438 \u043b\u0430\u043d\u0434\u0448\u0430\u0444\u0442\u043d\u043e\u0439 
\u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u044b' .

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/c892b879-aa12-4030-a05f-2e23de0edf04%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.