Re: Python 3.6 on Windows - does a python3 alias get created by installation?

2019-10-12 Thread Wesley Peng
smart.thanks. On 2019/10/12 12:19 下午, Gisle Vanem wrote: An "alias" could also simply be created using:   doskey python3=f:\ProgramFiles\Python36\python.exe -- https://mail.python.org/mailman/listinfo/python-list

Re: Mouse control

2019-10-12 Thread David L Neil via Python-list
On 7/10/19 4:11 AM, Alexander Vergun wrote: Hello all, I am coding a voice assistant under Python 3.7, Windows 7. I am using PYcharm and libraries such as PYSimpleGUI, mouse, keyboard etc. Everything works except for the mouse control and probably keyboard, the problem is following, when I ru

Re: python3, regular expression and bytes text

2019-10-12 Thread Eko palypse
First of all many thanks to everyone for the active participation. @Chris Angelico I think I understand what you illustrated with the byte example, makes sense. As it was developed for 8-bit encoding only, it cannot be used for mulitbyte encoding. @Richard Damon and @MRAB thank you very much for

Re: python3, regular expression and bytes text

2019-10-12 Thread MRAB
On 2019-10-12 20:57, Eko palypse wrote: You cannot. First, \w in re.LOCALE works only when the text is encoded with the locale encoding (cp1252 in your case). Second, re.LOCALE supports only 8-bit charsets. So even if you set the utf-8 locale, it would not help. Regular expressions with re.LO

Re: python3, regular expression and bytes text

2019-10-12 Thread Chris Angelico
On Sun, Oct 13, 2019 at 7:16 AM Richard Damon wrote: > > On 10/12/19 3:46 PM, Eko palypse wrote: > > Thank you very much for your answer. > > > >> You have to be able to match bytes, not strings. > > May I ask you to elaborate on this, sorry non-native English speaker. > > The buffer I receive is

Re: Mailscanner

2019-10-12 Thread MRAB
On 2019-10-12 21:06, Doris Marca Guaraca wrote: Hi sorry to bother you maybe you can help me, could you tell me which is the path that contains the main file of the bayes filter, I can't find it, or, I'm not sure this is the file / opt / zimbra / zimbramon /lib/Mail/Filter.pm Thank you in adv

Re: python3, regular expression and bytes text

2019-10-12 Thread MRAB
On 2019-10-12 20:48, Serhiy Storchaka wrote: 12.10.19 21:08, Eko palypse пише: So how can I make it work with utf8 encoded text? You cannot. First, \w in re.LOCALE works only when the text is encoded with the locale encoding (cp1252 in your case). Second, re.LOCALE supports only 8-bit charsets

Re: python3, regular expression and bytes text

2019-10-12 Thread Richard Damon
On 10/12/19 3:46 PM, Eko palypse wrote: > Thank you very much for your answer. > >> You have to be able to match bytes, not strings. > May I ask you to elaborate on this, sorry non-native English speaker. > The buffer I receive is a byte-like buffer. > >> I don't think you'll be able to 100% reliab

Re: python3, regular expression and bytes text

2019-10-12 Thread Chris Angelico
On Sun, Oct 13, 2019 at 6:54 AM Eko palypse wrote: > > Thank you very much for your answer. > > > You have to be able to match bytes, not strings. > > May I ask you to elaborate on this, sorry non-native English speaker. > The buffer I receive is a byte-like buffer. When you're matching text (the

Mailscanner

2019-10-12 Thread Doris Marca Guaraca
Hi sorry to bother you maybe you can help me, could you tell me which is the path that contains the main file of the bayes filter, I can't find it, or, I'm not sure this is the file / opt / zimbra / zimbramon /lib/Mail/Filter.pm Thank you in advance for your help. Regards Doris -- https://ma

Re: python3, regular expression and bytes text

2019-10-12 Thread Eko palypse
> You cannot. First, \w in re.LOCALE works only when the text is encoded > with the locale encoding (cp1252 in your case). Second, re.LOCALE > supports only 8-bit charsets. So even if you set the utf-8 locale, it > would not help. > > Regular expressions with re.LOCALE are slow. It may be more

Re: decorator needs access to variables where it is used.

2019-10-12 Thread Serhiy Storchaka
09.10.19 14:02, Chris Angelico пише: The decorator has full access to the function object, including a reference to that function's module globals. def trace(func): log = func.__globals__["log"] ... proceed as before As long as you can depend on "log" always being a module-level (glob

Re: python3, regular expression and bytes text

2019-10-12 Thread Eko palypse
Thank you very much for your answer. > You have to be able to match bytes, not strings. May I ask you to elaborate on this, sorry non-native English speaker. The buffer I receive is a byte-like buffer. > I don't think you'll be able to 100% reliably match bytes in this way. > You're asking it to

Re: python3, regular expression and bytes text

2019-10-12 Thread Serhiy Storchaka
12.10.19 21:08, Eko palypse пише: So how can I make it work with utf8 encoded text? You cannot. First, \w in re.LOCALE works only when the text is encoded with the locale encoding (cp1252 in your case). Second, re.LOCALE supports only 8-bit charsets. So even if you set the utf-8 locale, it w

Re: python3, regular expression and bytes text

2019-10-12 Thread Chris Angelico
On Sun, Oct 13, 2019 at 5:11 AM Eko palypse wrote: > > What needs to be set in order to be able to use a re search within > utf8 encoded bytes? You have to be able to match bytes, not strings. > So how can I make it work with utf8 encoded text? > Note, decoding it to a string isn't preferred as

python3, regular expression and bytes text

2019-10-12 Thread Eko palypse
What needs to be set in order to be able to use a re search within utf8 encoded bytes? My test, being on a windows PC with cp1252 setup, looks like this import re import locale cp1252 = 'Ärger im Paradies'.encode('cp1252') utf8 = 'Ärger im Paradies'.encode('utf-8') print('cp1252:', cp1252) pr

Re: question about making an App for Android

2019-10-12 Thread pyotr filipivich
Dennis Lee Bieber on Sat, 12 Oct 2019 12:26:43 -0400 typed in comp.lang.python the following: >On Fri, 11 Oct 2019 20:41:47 -0700, pyotr filipivich >declaimed the following: > > >> I've been hacking around with what needs to be computed. As in >>"okay,the orbits have different speed at dif

Re: Would you be interested in this Python open source project?

2019-10-12 Thread oliver
There are tons of projects that need help, I recommend that instead of re-inventing the wheel as there are enough choices out there re cicd and very likely you will find that your goal of 10/90 is unrealistic. Have a look at codetriage.com, and github has a feature that allows you to search for pr

[RELEASED] Python 3.5.8rc2 is released

2019-10-12 Thread Larry Hastings
On behalf of the Python development community, I'm relieved to announce the availability of Python 3.5.8rc2.  It's been a month after Python 3.5.8rc1, and since then we've added a small amount of new code to fix an API-level regression in http client, updated expat to 2.2.8, and upgraded the

Re: Suppress tooltips in Pygal charts (solved)

2019-10-12 Thread Roy Hann
Roy Hann wrote: > Is there any way to tell Pygal not to generate references to on-line > resources? I can now answer my own question. The solution was not obvious from reading the documentation but a glance at the pygal code uncovered the answer. The js configuration parameter specifies where

Re: Suppress tooltips in Pygal charts

2019-10-12 Thread Roy Hann
Dennis Lee Bieber wrote: > On Fri, 11 Oct 2019 12:46:10 + (UTC), Roy Hann > declaimed the following: > >>Following up on Elijah's suggestion responding to my earlier question >>about drawing gauges in a mobile (i.e. not normally internet connected) >>application on a Raspberry Pi I am using P