Mmm thanks for pointing this out. I don't have a Windows machine to test
this against right now but it seems you're right and there's something
wrong in my example (which is what I recommend in the official doc BTW, so
it needs to be fixed).
That aside, do you think the rest of my reasoning makes
On Sun, Sep 3, 2017 at 11:09 PM, Giampaolo Rodola' wrote:
>
> This is an example which filters processes with a funky name which works
> with both Python 2
> and 3:
>
> import psutil, sys
>
> PY3 = sys.version_info[0] == 2
> LOOKFOR = u"ƒőő.exe"
> for proc in psutil.process_iter(at
Hello Eryk,
it is true that the most correct way to represent strings in Python 2 is by
dealing with Unicode but it is also true that the most common scenario in
both the stdlib and most third party libs is to return and deal with str
(bytes) instead, so this is why I decided to do the same in psut
On Sun, Sep 3, 2017 at 9:58 AM, Giampaolo Rodola' wrote:
>
> - #1040: all strings are encoded by using OS fs encoding.
> - #1040: the following Windows APIs on Python 2 now return a string instead
> of
> unicode:
> - Process.memory_maps().path
> - WindowsService.bin_path()
> - WindowsServi
Hello all,
I'm glad to announce the release of psutil 5.3.0:
https://github.com/giampaolo/psutil
A blogpost describing the main changes is available here:
http://grodola.blogspot.com/2017/09/psutil-530-with-full-unicode-support-is.html
About
=
psutil (process and system utilities) is a
On Tue, 07 Mar 2017 14:05:15 -0800, John Nagle wrote:
> How do I test if a Python 2.7.8 build was built for 32-bit Unicode?
sys.maxunicode will be 1114111 if it is a "wide" (32-bit) build and 65535
if it is a "narrow" (16-bit) build.
You can double-check with:
unichr(0x10) # will raise V
On 3/7/2017 5:05 PM, John Nagle wrote:
How do I test if a Python 2.7.8 build was built for 32-bit
Unicode? (I'm dealing with shared hosting, and I'm stuck
with their provided versions.)
If I give this to Python 2.7.x:
sy = u'\U0001f60f'
len(sy) is 1 on a Ubuntu 14.04LTS machine, but 2
On Wed, Mar 8, 2017 at 9:05 AM, John Nagle wrote:
>How do I test if a Python 2.7.8 build was built for 32-bit
> Unicode? (I'm dealing with shared hosting, and I'm stuck
> with their provided versions.)
>
> If I give this to Python 2.7.x:
>
> sy = u'\U0001f60f'
>
> len(sy) is 1 on a Ubuntu
How do I test if a Python 2.7.8 build was built for 32-bit
Unicode? (I'm dealing with shared hosting, and I'm stuck
with their provided versions.)
If I give this to Python 2.7.x:
sy = u'\U0001f60f'
len(sy) is 1 on a Ubuntu 14.04LTS machine, but 2 on the
Red Hat shared hosting machine.
On 21/04/2013 10:02, Terry Jan Reedy wrote:
On 4/20/2013 9:37 PM, rusi wrote:
I believe that the recent correction in unicode performance followed
jmf's grumbles
No, the correction followed upon his accurate report of a regression,
last August, which was unfortunately mixed in with grumbles a
On 4/20/2013 9:37 PM, rusi wrote:
I believe that the recent correction in unicode performance followed
jmf's grumbles
No, the correction followed upon his accurate report of a regression,
last August, which was unfortunately mixed in with grumbles and
inaccurate claims. Others separated out
jmfauth於 2013年4月21日星期日UTC+8上午1時12分43秒寫道:
> In a previous post,
>
>
>
> http://groups.google.com/group/comp.lang.python/browse_thread/thread/6aec70817705c226#
>
> ,
>
>
>
> Chris “Kwpolska” Warrick wrote:
>
>
>
> “Is Unicode su
On Sun, Apr 21, 2013 at 1:36 PM, Steven D'Aprano
wrote:
> On Sat, 20 Apr 2013 18:37:00 -0700, rusi wrote:
>
>> According to jmf python sucks up to ASCII (those big bad Americans… of
>> whom Steven is the first…)
>
> Watch who you're calling an American, mate.
I think he knows, and that's why he s
On Sat, 20 Apr 2013 18:37:00 -0700, rusi wrote:
> According to jmf python sucks up to ASCII (those big bad Americans… of
> whom Steven is the first…)
Watch who you're calling an American, mate.
--
Steven
--
http://mail.python.org/mailman/listinfo/python-list
On Apr 21, 4:03 am, Neil Hodgson wrote:
> Hi jmf,
>
> > This gives me plenty of ideas to test the "flexible string
> > representation" (FSR). I should recognize this FSR is failing
> > particulary very well...
>
> This is too vague for me.
>
> Which string representation should Python
On 04/20/2013 11:14 AM, Chris Angelico wrote:
Flash forward to current date, and jmf has hijacked so many threads to
moan about PEP 393 that I'm actually happy about this one, simply
because he gave it a new subject line and one appropriate to a
discussion about Unicode.
+1000
--
http://mail.py
Hi jmf,
This gives me plenty of ideas to test the "flexible string
representation" (FSR). I should recognize this FSR is failing
particulary very well...
This is too vague for me.
Which string representation should Python use?
1) UTF-32
2) UTF-8
3) Python 3.3 -- 1, 2, or 4 bytes per
Unicode support so hard, especially in the 21st century?”
--
Unicode is not really complicate and it works very well (more
than two decades of development if you take into account
iso-14).
But, - I can say, "as usual" - people prefer to spend their
time to make a "better Unicode th
up/comp.lang.python/browse_thread/thread/6aec70817705c226#
>>> ,
>>>
>>> Chris “Kwpolska” Warrick wrote:
>>>
>>> “Is Unicode support so hard, especially in the 21st century?”
>>>
>>> --
>>>
>>> Unicode is not really complicate and
at you like
> how Python has implemented it? "FSR is failing ... a delight"? I don't
> know what you mean.
You're not familiar with jmf? He's one of our resident trolls. Allow
me to summarize Python 3's Unicode support...
>From 3.0 up to and including 3.
On Sat, Apr 20, 2013 at 10:22 AM, Ned Batchelder wrote:
> On 4/20/2013 1:12 PM, jmfauth wrote:
>>
>> In a previous post,
>>
>>
>> http://groups.google.com/group/comp.lang.python/browse_thread/thread/6aec70817705c226#
>> ,
>>
>> Chris “Kwpolsk
On 4/20/2013 1:12 PM, jmfauth wrote:
In a previous post,
http://groups.google.com/group/comp.lang.python/browse_thread/thread/6aec70817705c226#
,
Chris “Kwpolska” Warrick wrote:
“Is Unicode support so hard, especially in the 21st century?”
--
Unicode is not really complicate and it works
In a previous post,
http://groups.google.com/group/comp.lang.python/browse_thread/thread/6aec70817705c226#
,
Chris “Kwpolska” Warrick wrote:
“Is Unicode support so hard, especially in the 21st century?”
--
Unicode is not really complicate and it works very well (more
than two decades of
On Saturday, September 1, 2012 3:41:04 PM UTC-7, Steven D'Aprano wrote:
> Thanks to Victor Stinner, the curses module now has improved Unicode
>
> support.
>
>
>
> http://mail.python.org/pipermail/python-dev/2012-September/121569.html
>
>
>
> Victor ha
On Sun, 10 Oct 2010 11:34:02 +0200, David Kastrup wrote:
[unnecessary quoting removed]
> Your headers state:
>
> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.3 (darwin)
Please stop spamming multiple newsgroups. I'm sure this is of great
interest to the Emacs newsgroup, but not of Python.
Followu
On Sat, 09 Oct 2010 15:45:42 -0700, Sean McAfee wrote:
>> I'll have to say, as far as text processing goes, the most beautiful
>> lang with respect to unicode is emacs lisp. In elisp code (e.g.
>> Generate a Web Links Report with Emacs Lisp ), i don't have to declare
>> none of the unicode or enco
Sean McAfee writes:
> Xah Lee writes:
>> Perl's exceedingly lousy unicode support hack is well known. In fact
>> it is the primary reason i “switched” to python for my scripting needs
>> in 2005. (See: Unicode in Perl and Python)
>
> I think your assessment
On Sat, 09 Oct 2010 13:06:32 -0700, Bigos wrote:
[...]
> Maybe you have checked wrong version. There two versions of Ruby out
> there one does support unicode and the other doesn't.
Please don't feed the trolls. Xah Lee is a known troll who cross-posts to
irrelevant newsgroups with his blathering
2010-10-09
On Oct 9, 3:45 pm, Sean McAfee wrote:
> Xah Lee writes:
> > Perl's exceedingly lousy unicode support hack is well known. In fact
> > it is the primary reason i “switched” to python for my scripting needs
> > in 2005. (See: Unicode in Perl and Python)
>
Xah Lee writes:
> Perl's exceedingly lousy unicode support hack is well known. In fact
> it is the primary reason i “switched” to python for my scripting needs
> in 2005. (See: Unicode in Perl and Python)
I think your assessment is antiquated. I've been doing Unicode
progra
On Oct 7, 7:13 pm, Xah Lee wrote:
> here's my experiences dealing with unicode in various langs.
>
> Unicode Support in Ruby, Perl, Python, Emacs Lisp
>
> Xah Lee, 2010-10-07
>
> I looked at Ruby 2 years ago. One problem i found is that it does not
> support Unicode w
here's my experiences dealing with unicode in various langs.
Unicode Support in Ruby, Perl, Python, Emacs Lisp
Xah Lee, 2010-10-07
I looked at Ruby 2 years ago. One problem i found is that it does not
support Unicode well. I just checked today, it still doesn't. Just do
a web search o
HI
Can u please tell me if there is any package or class that I can import
for internationalization, or unicode support?
This module is just a small part of our application, and we are not
really supposed to alter the code.
We do not have nobody here to help us with python here. and are
supposed
Fredrik Lundh wrote:
>
> what does the word "validate" mean here?
>
Let me explain our module.
We receive text files (with comma separated values, as per some
predefined format) from a third party.
for example account file comes as "abc.acc" {.acc is the extension for
account file as per our code}
sonald wrote:
> Hi,
> I am using python2.4.1
>
> I need to pass russian text into python and validate the same.
> Can u plz guide me on how to make my existing code support the
> russian text.
>
> Is there any module that can be used for unicode support in python?
>
"sonald" wrote:
> I have added the following line in the script
>
> # -*- coding: utf-8 -*-
that's good.
> I have also modified the site.py
that's bad, because this means that your code won't work on standard
Python installations.
> Now when I try to validate the data in the text file
> say ab
ussian text,
>
> some junk character (box like) is added as the first character
> what must be the reason for this?
> and how do I handle it?
You shouldn't tamper with the site-wide encoding, as this will mask
errors you made in the best case, let alone not producing new ones.
Fredrik Lundh wrote:
> >http://www.google.com/search?q=python+unicode
>
> (and before anyone starts screaming about how they hate RTFM replies, look
> at the search result)
>
>
Thanks!! but i have already tried this...
and let me tell you what i am trying now...
I have added the following li
>http://www.google.com/search?q=python+unicode
(and before anyone starts screaming about how they hate RTFM replies, look
at the search result)
--
http://mail.python.org/mailman/listinfo/python-list
"sonald" wrote:
> I need to pass russian text into python and validate the same.
> Can u plz guide me on how to make my existing code support the
> russian text.
>
> Is there any module that can be used for unicode support in python?
Python has built-in Unicode support
Hi,
I am using python2.4.1
I need to pass russian text into python and validate the same.
Can u plz guide me on how to make my existing code support the
russian text.
Is there any module that can be used for unicode support in python?
Incase of decimal numbers, how to handle "comma
Dale King <[EMAIL PROTECTED]> wrote:
>Tim Roberts wrote:
>> "Xah Lee" <[EMAIL PROTECTED]> wrote:
>>
>>> Languages with Full Unicode Support
>>>
>>> As far as i know, Java and JavaScript are languages with full, complete
>>&g
Tim Roberts wrote:
> "Xah Lee" <[EMAIL PROTECTED]> wrote:
>
>> Languages with Full Unicode Support
>>
>> As far as i know, Java and JavaScript are languages with full, complete
>> unicode support. That is, they allow names to be defined using unic
Pascal Bourguignon wrote:
> [...]
> (coerce (lschar :name "LATIN") 'string)
> --> "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
> ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóô
> [...]
In what programming language/interpreter is this code?
--
http://mail.python.org/mailman/li
Joachim Durchholz <[EMAIL PROTECTED]> writes:
> Oliver Bandel schrieb:
>> Matthias Blume wrote:
>>
>>> Tin Gherdanarra <[EMAIL PROTECTED]> writes:
>>>
>>>
Oliver Bandel wrote:
> こんいちわ Xah-Lee san ;-)
Uhm, I'd guess that Xah is Chinese. Be careful
with such things in r
Oliver Bandel schrieb:
> Matthias Blume wrote:
>
>> Tin Gherdanarra <[EMAIL PROTECTED]> writes:
>>
>>
>>> Oliver Bandel wrote:
>>>
こんいちわ Xah-Lee san ;-)
>>>
>>> Uhm, I'd guess that Xah is Chinese. Be careful
>>> with such things in real life; Koreans might
>>> beat you up for this. Stay alive
Oliver Bandel <[EMAIL PROTECTED]> writes:
>>>Oliver Bandel wrote:
>>>
こんいちわ Xah-Lee san ;-)
>>>
>>>Uhm, I'd guess that Xah is Chinese. Be careful
>>>with such things in real life; Koreans might
>>>beat you up for this. Stay alive!
>> And the Japanese might beat him up, too. For butchering the
Matthias Blume wrote:
> Tin Gherdanarra <[EMAIL PROTECTED]> writes:
>
>
>>Oliver Bandel wrote:
>>
>>>こんいちわ Xah-Lee san ;-)
>>
>>Uhm, I'd guess that Xah is Chinese. Be careful
>>with such things in real life; Koreans might
>>beat you up for this. Stay alive!
>
>
> And the Japanese might beat hi
Joachim Durchholz wrote:
> Chris Uppal schrieb:
>> Joachim Durchholz wrote:
>>
This is implementation-defined in C. A compiler is allowed to accept
variable names with alphabetic Unicode characters outside of ASCII.
>>>
>>> Hmm... that could would be nonportable, so C support for Unicode
Chris Uppal schreef:
> Since the interpretation of characters which are yet to be added to
> Unicode is undefined (will they be digits, "letters", operators,
> symbol, punctuation ?), there doesn't seem to be any sane way
> that a language could allow an unrestricted choice of Unicode in
> ide
Chris Uppal schrieb:
> Joachim Durchholz wrote:
>
>>> This is implementation-defined in C. A compiler is allowed to accept
>>> variable names with alphabetic Unicode characters outside of ASCII.
>> Hmm... that could would be nonportable, so C support for Unicode is
>> half-baked at best.
>
> Sin
that a language
> could
> allow an unrestricted choice of Unicode in identifiers. Hence, it must define
> a specific allowed sub-set. C certainly defines an allowed subset of Unicode
> characters -- so I don't think you could call its Unicode support "half-baked"
>
efine
a specific allowed sub-set. C certainly defines an allowed subset of Unicode
characters -- so I don't think you could call its Unicode support "half-baked"
(not in that respect, anyway). A case -- not entirely convincing, IMO -- could
be made that it would be better to allow
Tim Roberts wrote:
> "Xah Lee" <[EMAIL PROTECTED]> wrote:
>
>>Languages with Full Unicode Support
>>
>>As far as i know, Java and JavaScript are languages with full, complete
>>unicode support. That is, they allow names to be defined using unicode.
&g
Tim Roberts schrieb:
> "Xah Lee" <[EMAIL PROTECTED]> wrote:
>> C ? No.
>
> This is implementation-defined in C. A compiler is allowed to accept
> variable names with alphabetic Unicode characters outside of ASCII.
Hmm... that could would be nonportable, so C support for Unicode is
half-baked at
"Xah Lee" <[EMAIL PROTECTED]> wrote:
>Languages with Full Unicode Support
>
>As far as i know, Java and JavaScript are languages with full, complete
>unicode support. That is, they allow names to be defined using unicode.
>(the JavaScript engine used by FireFox su
Tin Gherdanarra <[EMAIL PROTECTED]> writes:
> Oliver Bandel wrote:
>> こんいちわ Xah-Lee san ;-)
>
> Uhm, I'd guess that Xah is Chinese. Be careful
> with such things in real life; Koreans might
> beat you up for this. Stay alive!
And the Japanese might beat him up, too. For butchering their
language
Oliver Bandel wrote:
>
> こんいちわ Xah-Lee san ;-)
Uhm, I'd guess that Xah is Chinese. Be careful
with such things in real life; Koreans might
beat you up for this. Stay alive!
>
>
> Xah Lee wrote:
>
>> Languages with Full Unicode Support
>>
>>
"Oliver Bandel" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
>
> Xah Lee wrote:
>
>>
>> As far as i know, Java and JavaScript are languages with full, complete
>> unicode support. That is, they allow names to be defined using unicode.
> As far as i know, here's few other lang's status:
>
> C → No.
I think C has the wchar type to handle larger values. And C++ has
std::wstring. So really, the support is there.
http://www.cl.cam.ac.uk/~mgk25/unicode.html#c
I think the problem is that most C/C++ coders don
こんいちわ Xah-Lee san ;-)
Xah Lee wrote:
> Languages with Full Unicode Support
>
> As far as i know, Java and JavaScript are languages with full, complete
> unicode support. That is, they allow names to be defined using unicode.
Can you explain what you mena with the names he
Xah Lee wrote:
> If you know a lang that does full unicode support, please let me know.
Tcl. You may have to modify the "source" command to get it to default
to something other than the system encoding, but this is trivial in Tcl.
--
Darren New / San Diego, CA, USA (PST
Xah Lee wrote:
> Languages with Full Unicode Support
>
> As far as i know, Java and JavaScript are languages with full, complete
> unicode support. That is, they allow names to be defined using unicode.
> (the JavaScript engine used by FireFox support this)
>
> As far as i k
Xah Lee wrote:
> Lisps → No.
The Common Lisp spec (CLHS) doesn't require that implementations support
Unicode characters, but it doesn't forbid it and some implementations
support it, e.g. http://clisp.cons.org/impnotes.html
--
Frank Buss, [EMAIL PROTECTED]
http://www.frank-buss.de, http://www.
Languages with Full Unicode Support
As far as i know, Java and JavaScript are languages with full, complete
unicode support. That is, they allow names to be defined using unicode.
(the JavaScript engine used by FireFox support this)
As far as i know, here's few other lang's statu
Neal Norwitz wrote:
> On 2/17/06, M.-A. Lemburg <[EMAIL PROTECTED]> wrote:
>
>>Neal Norwitz wrote:
> >
>>Another candidate for removal is the --disable-unicode
>>switch.
>>
>>We should probably add a deprecation warning for that in
>>Py 2.5 and then remove the hundreds of
>>#idef Py_USING_UNICODE
Hello All,
I've added (optional) unicode support for ConfigObj. This is now
available from SVN.
You can specify an encoding to decode the config file on reading. This
maps to an encoding attribute on the ConfigObj instance that is also
used for writing (and can be changed).
You can find
What's new?
SPE now creates backup files and can insert your standard signature
(with for example license and copyright information) in your code. A
bug that prevented SPE to start on Linux has been fixed and also a lot
of bugfixes were implemented, especially for unicode.
You can read more on the
Thanks, a lot.
It helped me so much.
Mike
--
http://mail.python.org/mailman/listinfo/python-list
[Mike]
> Is there a python library, that is able to create Excel files with
> unicode characters.
pyExcelerator claims to do this, but I've never used it.
http://sourceforge.net/projects/pyexcelerator/
--
Richie Hindle
[EMAIL PROTECTED]
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
I want to create an Excel file, but I don't to use com or any win32
object. Because, the file should be opened via OpenOffice. I found
pyXLWriter, but it doesn't support unicode or non-ascii characters. Is
there a python library, that is able to create Excel files with unicode
characters.
I t
> "xah" == xah <[EMAIL PROTECTED]> writes:
xah> python supports unicode in source
xah> code by putting a coding declaration as the first line.
[...]
xah> In perl, support of unicode is very flaky. The language does
xah> not support it, [...]
All:
Xah Lee is trolli
<[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
# -*- coding: utf-8 -*-
# python supports unicode in source code by putting a coding
declaration
# as the first line.
print "look chinese chars: ?"
# Note, however, identifiers cannot use unicode chars.
# e.g. you cannot define a fu
[EMAIL PROTECTED] wrote:
> # -*- coding: utf-8 -*-
> # python supports unicode in source code by putting a coding
> declaration
> # as the first line.
So?
> In perl, support of unicode is very flaky. The language does not
> support it, but packages that changes behaviors of string handling (in
>
74 matches
Mail list logo