Re: Everything is an object in python - object class and type class

2015-06-01 Thread Steven D'Aprano
On Tuesday 02 June 2015 11:02, TheDoctor wrote: > On Monday, June 1, 2015 at 7:33:11 PM UTC-5, Chris Angelico wrote: >> On Tue, Jun 2, 2015 at 10:24 AM, TheDoctor >> wrote: >> > A type is not an object in the same way an instantiated type is an >> > object -- anymore than a blueprint for a buildi

Re: Everything is an object in python - object class and type class

2015-06-01 Thread Steven D'Aprano
On Tuesday 02 June 2015 11:15, TheDoctor wrote: > A type is not an object. Yes it is. py> isinstance(type, object) True py> isinstance(int, object) True > You see it as one, because you are MENTALLY > lexing your own code on the screen. No, I see it as one, because it is one. > But python d

Re: Religion [was Re: Everything is an object in python - object class and type class]

2015-06-01 Thread Mark Lawrence
On 02/06/2015 07:04, Steven D'Aprano wrote: On Tuesday 02 June 2015 15:01, Rustom Mody wrote: eg Would it make sense to you if you were told that there are widespread religions like Buddhism that are agnostic or Jainism that are strictly atheistic? No of course it wouldn't make sense. But not

Re: Religion [was Re: Everything is an object in python - object class and type class]

2015-06-01 Thread Rustom Mody
On Tuesday, June 2, 2015 at 11:34:34 AM UTC+5:30, Steven D'Aprano wrote: > On Tuesday 02 June 2015 15:01, Rustom Mody wrote: > > > eg Would it make sense to you if you were told that there are widespread > > religions like Buddhism that are agnostic or Jainism that are strictly > > atheistic? > >

Re: Create Web app on Win and run on Win or Mac

2015-06-01 Thread Mark Lawrence
On 02/06/2015 06:51, Bret Edwards via Python-list wrote: I took a look at Ren'Py as suggested by a reply to my previous post entitled "Create on Win and run on Win or Mac." Thanks for your suggestion. Ren'Py looks pretty amazing! Not sure that is a good route since my primary reason for this end

Religion [was Re: Everything is an object in python - object class and type class]

2015-06-01 Thread Steven D'Aprano
On Tuesday 02 June 2015 15:01, Rustom Mody wrote: > eg Would it make sense to you if you were told that there are widespread > religions like Buddhism that are agnostic or Jainism that are strictly > atheistic? No of course it wouldn't make sense. But nothing to do with religion, spirituality an

Create Web app on Win and run on Win or Mac

2015-06-01 Thread Bret Edwards via Python-list
I took a look at Ren'Py as suggested by a reply to my previous post entitled "Create on Win and run on Win or Mac." Thanks for your suggestion. Ren'Py looks pretty amazing! Not sure that is a good route since my primary reason for this endeavor is learning Python scripting (secondarily to creat

Re: How to understand '_' in these tests?

2015-06-01 Thread Chris Angelico
On Tue, Jun 2, 2015 at 2:18 PM, fl wrote: > Because I have tried several commands, such as reversed('fred'), xx and rx, > '4' are always there. > > What is your explanation about the following? > > > Thanks, > > > > > > reversed('fred') > _ > '4' _ > '4' xx > 33223 _ > '

Re: What is considered an "advanced" topic in Python?

2015-06-01 Thread Rustom Mody
On Monday, June 1, 2015 at 1:28:53 PM UTC+5:30, Laura Creighton wrote: > If you are giving a talk about Decimal -- and trying to stamp out the > inappropriate use of floats you have to first inform people that > what they learned as 'decimals' as children was not floating point, > despite the fact

Re: Everything is an object in python - object class and type class

2015-06-01 Thread Rustom Mody
On Tuesday, June 2, 2015 at 10:17:55 AM UTC+5:30, TheDoctor wrote: > > Mark, one of my real names. Thanks -- that helps. > People are dumb, but perhaps I am dumb for treating them as equals. Perhaps > that's not a fair assumption. That doesn't. > It's quite clear, that there's a bit of re

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Actually that's not true... messages not that interesting. This C# parser does not parse what I want which is: "updates" and "positions". Thus I rejected this parser some days ago. But it's technique could be handy. Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
If some of this code could be made to work it could be of some use: ParserEngine is the least important... MessageParser is interesting. class AbstractSectionsParser(AbstractParser): # Provides a method to return a list of sections def GetResult(self): # Returns the list with the found resourc

Re: Everything is an object in python - object class and type class

2015-06-01 Thread TheDoctor
On Monday, June 1, 2015 at 11:09:09 PM UTC-5, rand...@fastmail.us wrote: > On Mon, Jun 1, 2015, at 20:24, TheDoctor wrote: > > A type is not an object in the same way an instantiated type is an object > > -- anymore than a blueprint for a building is the building itself. > > What is an object? >

Re: Everything is an object in python - object class and type class

2015-06-01 Thread TheDoctor
> > A type is not an object in the same way an instantiated type is an object > > -- anymore than a blueprint for a building is the building itself. > > Point 1 > > Yes. You may be onto something here Mark [I assume that's your name]. > Some very intelligent people have suggested that the slopp

Re: What is considered an "advanced" topic in Python?

2015-06-01 Thread Rustom Mody
On Monday, June 1, 2015 at 9:40:39 PM UTC+5:30, Chris Angelico wrote: > On Tue, Jun 2, 2015 at 1:17 AM, BartC wrote: > > On 01/06/2015 14:52, Chris Angelico wrote: > >> It's > >> > >> like the eternal debate about assignment and whether "x = x + 1" is > >> nonsense, with advocates preferring "x :=

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Example for python: MyString = "Hello World" print MyString.rfind("World") if MyString.rfind("World"): print "yes" else: print "no" Pretty cool. Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Hmm this parser uses an interesting technique: if line.Contains("activePlayerRef"): self._activePlayerRef = Convert.ToInt64(line.Substring(line.LastIndexOf("activePlayerRef") + 16)) I'll see if python can do this as well... ;) Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/p

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Together with this it's might be of some use: http://codeconverter.sharpdevelop.net/SnippetConverter.aspx It converts C# to Python pretty fast. I'll give it a try to see if it can work. Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Here is a parser for sto demo files written in C# maybe it can be of some use, check trunk folders: http://sourceforge.net/p/stodemolauncher/code/HEAD/tree/ Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: How to understand '_' in these tests?

2015-06-01 Thread random832
On Tue, Jun 2, 2015, at 00:18, fl wrote: > Hi, > > I just know that '_' is the last result in the Python interpreter. I feel that > it is like 'ans' in Matlab. When I run the following commands. The result of > '_' are always '4'. > > > Because I have tried several commands, such as reversed('fr

How to understand '_' in these tests?

2015-06-01 Thread fl
Hi, I just know that '_' is the last result in the Python interpreter. I feel that it is like 'ans' in Matlab. When I run the following commands. The result of '_' are always '4'. Because I have tried several commands, such as reversed('fred'), xx and rx, '4' are always there. What is your exp

Re: Everything is an object in python - object class and type class

2015-06-01 Thread random832
On Mon, Jun 1, 2015, at 21:15, TheDoctor wrote: > In Python 2.7 type(type) is type (not object), but isinstance(type, > object) is true -- so it is ambiguous, even contradictory, in the > language. isinstance(type, object) is true because object is the parent class of type. issubclass(type, object

Re: Everything is an object in python - object class and type class

2015-06-01 Thread random832
On Mon, Jun 1, 2015, at 20:24, TheDoctor wrote: > A type is not an object in the same way an instantiated type is an object > -- anymore than a blueprint for a building is the building itself. What is an object? It's something you can call str or repr on. It's something you can lookup attributes

Re: Everything is an object in python - object class and type class

2015-06-01 Thread Mark Lawrence
On 02/06/2015 04:15, Rustom Mody wrote: Two unrelated points: On Tuesday, June 2, 2015 at 5:54:43 AM UTC+5:30, TheDoctor wrote: On Monday, June 1, 2015 at 7:03:49 AM UTC-5, Eddilbert Macharia wrote: I think i kind of understand now. Instead of python having data types like int, string, e.t.c

Re: Parser needed.

2015-06-01 Thread Mark Lawrence
On 02/06/2015 01:29, Skybuck Flying wrote: Hello, I need some kind of parser and some kind of way to access the data contained in a file like the one below: (text file): http://www.skybuck.org/Games/StartrekOnline/Parser/SpaceFleetAlertEnemyExample.demo I am interested in learning the entity

Re: What use of string module?

2015-06-01 Thread Mark Lawrence
On 02/06/2015 03:14, fl wrote: Hi, I read the online help about string. It lists string constants, string formatting, template strings and string functions. After reading these, I am still puzzled about how to use the string module. Could you show me a few example about this module? Thanks

Re: What is considered an "advanced" topic in Python?

2015-06-01 Thread Gene Heskett
On Monday 01 June 2015 20:33:50 Dennis Lee Bieber wrote: > On Mon, 1 Jun 2015 09:49:35 -0400, Gene Heskett > > declaimed the following: > >But IMO, any language that does not have the ability to set an fp > > number to a fixed number of digits to the right of the separator > > regardless of whic

Re: Everything is an object in python - object class and type class

2015-06-01 Thread Rustom Mody
Two unrelated points: On Tuesday, June 2, 2015 at 5:54:43 AM UTC+5:30, TheDoctor wrote: > On Monday, June 1, 2015 at 7:03:49 AM UTC-5, Eddilbert Macharia wrote: > > I think i kind of understand now. > > > > Instead of python having data types like int, string, e.t.c it has two > > primitive typ

Create on Win and run on Win or Mac

2015-06-01 Thread MrJean1
See this thread for possible answers /Jean -- https://mail.python.org/mailman/listinfo/python-list

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Perhaps the list.append operation is the cause of the slowdown, or perhaps my algo is flawed. No idea yet with slowdown of parser code so far. Instead of trying to debug everything going to add some time outputs to the whole thing to get to bottom of this ;) Ok another sikuli failure... I ju

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Apperently print speed has some exponential time issue in SikuliX kinda weird. But at least processing is high... however, debug console/print is only thing I got to diagnose problems... Could get time-wise nasty... hmmm... Perhaps I should make a small little parser in Delphi and port it to

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Test program shows, python/sikulix can handle about 3m chars per second so I must continue with a parser attempt. Apperently there is some bottleneck/slowdown in posted code... I may have to slow down a bit take more time... and perhaps use global vars or so... instead of parameters. Maybe t

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Test program shows, python/sikulix can handle about 3m chars per second so I must continue with a parser attempt. # test char processing speed. # test if sikulix 1.1, python, jython/whatever is a piece of shit when it comes to parsing dealing with characters, unicode processing bottleneck theo

What use of string module?

2015-06-01 Thread fl
Hi, I read the online help about string. It lists string constants, string formatting, template strings and string functions. After reading these, I am still puzzled about how to use the string module. Could you show me a few example about this module? Thanks -- https://mail.python.org/mailma

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
I tried running this in SikuliX 1.1 from pyparsing import Word, alphas greet = Word( alphas ) + "," + Word( alphas ) + "!" greeting = greet.parseString( "Hello, World!" ) print greeting Doesn't seem to run pyparser module missing. Another reason why not to use it, unfortunately. Not sure if i

Re: Message passing syntax for objects | OOPv2

2015-06-01 Thread TheDoctor
On Thursday, May 9, 2013 at 12:39:37 AM UTC-5, Steven D'Aprano wrote: > On Wed, 08 May 2013 19:35:58 -0700, Mark Janssen wrote: > > > Long story short: the lambda > > calculus folks have to split from the Turing machine folks. > > These models of computation should not use the same language. The

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
"Joel Goldstick" wrote in message news:mailman.34.1433209315.13271.python-l...@python.org... On Mon, Jun 1, 2015 at 9:31 PM, Skybuck Flying wrote: Yes this will work: DemoChars = FileObject.read() I think this is a cleaner solution. EOL can be ignored and focusses on { } and stuff like

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
I am trying to rush it a bit but things are starting to go to hell. SikuliX needs to be restarted continously to deal with bugs. Plus Eclipse breakpoints cannot be set. So both IDEs totally suck for any complex code development. Plus I can already tell this is going to be insanely slow in pyth

Re: Parser needed.

2015-06-01 Thread Joel Goldstick
On Mon, Jun 1, 2015 at 9:31 PM, Skybuck Flying wrote: > Yes this will work: > > DemoChars = FileObject.read() > > I think this is a cleaner solution. EOL can be ignored and focusses on { } > and stuff like that... when extracting information EOL could be used as > well. > > > Bye, > Skybuck. > --

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
On 06/01/2015 07:19 PM, Skybuck Flying wrote: How hard would it be to encode that into pyparser ? " Check out the docs and you probably will get an idea. The only real way to find out is to try it. Is this file from a certain program? If so, it's possible someone has already written a python

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Nice char based code: BotDemoFolder = "C:\\Games\\Startrek Online\\Startrek Online\\Cryptic Studios\\Star Trek Online\\Live\\demos" BotDemoFile = "SpaceFleetAlert.demo" import time def ParseDemoLines( ParaLines ): print "Parsing " + str( len(ParaLines) ) + " lines." for LineIndex in range(0,

Re: How to use an iterator?

2015-06-01 Thread Rob Gaddi
On Mon, 01 Jun 2015 18:26:57 -0700, fl wrote: > Hi, > > > I read the online tutorial on iterator: > > https://docs.python.org/2/library/itertools.html > > I have no idea on how to use this one: > > itertools.count(start=0, step=1) > > BTW, I am using Python 2.7.9 on Windows 7. > > > > I e

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Yes this will work: DemoChars = FileObject.read() I think this is a cleaner solution. EOL can be ignored and focusses on { } and stuff like that... when extracting information EOL could be used as well. Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Everything is an object in python - object class and type class

2015-06-01 Thread Chris Angelico
On Tue, Jun 2, 2015 at 11:15 AM, TheDoctor wrote: > Let me make this clearer to you, Chris, because I don't want you to have to > suck it too, like the rest of this community. > > A type is not an object. You see it as one, because you are MENTALLY lexing > your own code on the screen. But pyt

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Ok, so far so good, a little start has been made. Text file is read into lines... I am not so sure if this is a good idea... Maybe it's easier if the entire file is one gigant array of characters instead of fragmented lines. However I don't know yet exactly how to read as one gigant array of

Re: Parser needed.

2015-06-01 Thread Michael Torrie
On 06/01/2015 07:19 PM, Skybuck Flying wrote: > How hard would it be to encode that into pyparser ? Check out the docs and you probably will get an idea. The only real way to find out is to try it. Is this file from a certain program? If so, it's possible someone has already written a python li

How to use an iterator?

2015-06-01 Thread fl
Hi, I read the online tutorial on iterator: https://docs.python.org/2/library/itertools.html I have no idea on how to use this one: itertools.count(start=0, step=1) BTW, I am using Python 2.7.9 on Windows 7. I even input the following: def count(start=0, step=1): # count(10) --> 10 11

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Since the file is probably ascii... not sure... I might come away with: " file.read([size]) Reads at most size bytes from the file (less if the read hits EOF before obtaining size bytes). " The doc does not mention is size is optionally... I will try and leave it out, see what happens, other

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
"Michael Torrie" wrote in message news:mailman.31.1433207544.13271.python-l...@python.org... On 06/01/2015 06:29 PM, Skybuck Flying wrote: The parser should be able to parse a textfile of somewhere between 20.000 lines to 50.000 lines in about 1 to 2 seconds. My environment is SikuliX 1.1 "

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
So far this is what I got... I like to name things for what they are so FileObject I like better than something abstract/weird like "text file", my code: BotDemoFolder = "C:\\Games\\Startrek Online\\Startrek Online\\Cryptic Studios\\Star Trek Online\\Live\\demos" BotDemoFile = "SpaceFleetAler

Re: Everything is an object in python - object class and type class

2015-06-01 Thread TheDoctor
On Monday, June 1, 2015 at 7:33:11 PM UTC-5, Chris Angelico wrote: > And a type is an > object too. There is no significant difference here. Let me make this clearer to you, Chris, because I don't want you to have to suck it too, like the rest of this community. A type is not an object. You see

Re: Parser needed.

2015-06-01 Thread Michael Torrie
On 06/01/2015 06:29 PM, Skybuck Flying wrote: > The parser should be able to parse a textfile of somewhere between 20.000 > lines to 50.000 lines in about 1 to 2 seconds. > > My environment is SikuliX 1.1 I don't have any inclination to examine your input files, but you could certainly mock up a

Re: Where is 'palindrome' defined?

2015-06-01 Thread MRAB
On 2015-06-02 01:55, fl wrote: On Sunday, May 31, 2015 at 9:46:56 PM UTC-7, fl wrote: Hi, When I search solution of reverse a string/number, I came across a short function online: >>> def palindrome(num): return str(num) == str(num)[::-1] I thought that it is a general function. And w

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Readlines is indeed documented as reading EOF: http://www.tutorialspoint.com/python/file_methods.htm Bye, skybuck. "Skybuck Flying" wrote in message news:37cda$556d009d$5419aafe$38...@news.ziggo.nl... This will probably help: http://stackoverflow.com/questions/14676265/how-to-read-text-fi

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
I really like this python help file, it has served me well so far: http://www.tutorialspoint.com/python/python_functions.htm It's unusually better than the rest on the net ;) It matches nicely Sikuli's python's capabilities. Bye, Skybuck :) -- https://mail.python.org/mailman/listinfo/python-l

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Link looks a bit odd, home index link: Nice python documentation/tutorial/help: http://www.tutorialspoint.com/python/index.htm Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Except for the first bracket... it has no structure name. Perhaps the demo filename could be used as structure name or just be left empty. Bye, Skybuck. "Skybuck Flying" wrote in message news:aef84$556d00e7$5419aafe$39...@news.ziggo.nl... From examining the demo file it seems each brac

Re: Where is 'palindrome' defined?

2015-06-01 Thread sohcahtoa82
On Monday, June 1, 2015 at 5:55:14 PM UTC-7, fl wrote: > On Sunday, May 31, 2015 at 9:46:56 PM UTC-7, fl wrote: > > Hi, > > > > When I search solution of reverse a string/number, I came across a short > > function online: > > > > >>> def palindrome(num): > > return str(num) == str(num)[::-1]

Re: Everything is an object in python - object class and type class

2015-06-01 Thread TheDoctor
On Monday, June 1, 2015 at 7:33:11 PM UTC-5, Chris Angelico wrote: > On Tue, Jun 2, 2015 at 10:24 AM, TheDoctor wrote: > > A type is not an object in the same way an instantiated type is an object > > -- anymore than a blueprint for a building is the building itself. > > And don't let dreamingfo

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
From examining the demo file it seems each bracketted data sections if pre-header/pre-fixed with it's name. So it's somewhat similar to a C structure: structure { } Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
This can help with parsing the C like bracketted data: http://stackoverflow.com/questions/1651487/python-parsing-bracketed-blocks algo: " For each string in the array: Find the first '{'. If there is none, leave that string alone. Init a counter to 0. For each character in the string:

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
This will probably help: http://stackoverflow.com/questions/14676265/how-to-read-text-file-into-a-list-or-array-with-python text_file = open("filename.dat", "r") lines = text_file.readlines() print lines print len(lines) text_file.close() Usually I like to consult officals docs though...Bye, Sk

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
Some further information about the demo file: It seems to be split up into "creation sections" and "update" sections. The update sections contain the positions. The update sections also contain a reference number to the created entities. (There is one empty creation section but that's because

Re: Parser needed.

2015-06-01 Thread Skybuck Flying
I will try and help for as far as possible, maybe I will end up writing it myself in the process. The first problem seems to be, how to read a textfile into python all at once... and then perhaps process them per line. Bye, Skybuck. -- https://mail.python.org/mailman/listinfo/python-list

Re: Where is 'palindrome' defined?

2015-06-01 Thread fl
On Sunday, May 31, 2015 at 9:46:56 PM UTC-7, fl wrote: > Hi, > > When I search solution of reverse a string/number, I came across a short > function online: > > >>> def palindrome(num): > return str(num) == str(num)[::-1] > > I thought that it is a general function. And with the following

Re: Everything is an object in python - object class and type class

2015-06-01 Thread Chris Angelico
On Tue, Jun 2, 2015 at 10:24 AM, TheDoctor wrote: > On Monday, June 1, 2015 at 7:03:49 AM UTC-5, Eddilbert Macharia wrote: >> I think i kind of understand now. >> >> Instead of python having data types like int, string, e.t.c it has two >> primitive types which are class type and class object whi

Parser needed.

2015-06-01 Thread Skybuck Flying
Hello, I need some kind of parser and some kind of way to access the data contained in a file like the one below: (text file): http://www.skybuck.org/Games/StartrekOnline/Parser/SpaceFleetAlertEnemyExample.demo I am interested in learning the entity numbers: "EntityRef " and their position

Re: Everything is an object in python - object class and type class

2015-06-01 Thread TheDoctor
On Monday, June 1, 2015 at 7:03:49 AM UTC-5, Eddilbert Macharia wrote: > I think i kind of understand now. > > Instead of python having data types like int, string, e.t.c it has two > primitive types which are class type and class object which are created by > python interpreter during its setu

Re: Language design

2015-06-01 Thread TheDoctor
On Friday, September 13, 2013 at 12:08:04 AM UTC-5, Steven D'Aprano wrote: > On Thu, 12 Sep 2013 20:23:21 -0700, Mark Janssen wrote: > which would be silly. Only somebody who doesn't understand how > inheritance works in Python would do that. There's simply no need for it, > and in fact it would

Re: Create on Win and run on Win or Mac

2015-06-01 Thread Terry Reedy
On 6/1/2015 7:29 PM, Bret Edwards via Python-list wrote: I would like to create a Python (stand-alone executable) program on a Windows machine and deploy the finished product on other Windows machines (of varying Windows OS versions) and also on Mac machines (of varying Mac OS versions.) The pro

Re: Pyton re module and POSIX equivalence classes

2015-06-01 Thread MRAB
On 2015-06-01 23:48, Mark Lawrence wrote: On 01/06/2015 21:29, Tim Chase wrote: Is Python supposed to support POSIX "equivalence classes"? I tried the following in Py2 and Py3: >>> re.sub('[[=a=]]', 'A', 'aáàãâä', re.U) 'aáàãâä' which suggests that it doesn't (I would have expected "AAA

Create on Win and run on Win or Mac

2015-06-01 Thread Bret Edwards via Python-list
I would like to create a Python (stand-alone executable) program on a Windows machine and deploy the finished product on other Windows machines (of varying Windows OS versions) and also on Mac machines (of varying Mac OS versions.) The program would present a GUI that the user would interact w

Re: Everything is an object in python - object class and type class

2015-06-01 Thread BartC
On 01/06/2015 13:03, Eddilbert Macharia wrote: Thank you all who have taken there time to assist me. Special thanks to Steven D'Aparo even though you didn't have two you have taken you time to go into details. I think i kind of understand now. Instead of python having data types like int, stri

Re: Pyton re module and POSIX equivalence classes

2015-06-01 Thread Mark Lawrence
On 01/06/2015 21:29, Tim Chase wrote: Is Python supposed to support POSIX "equivalence classes"? I tried the following in Py2 and Py3: >>> re.sub('[[=a=]]', 'A', 'aáàãâä', re.U) 'aáàãâä' which suggests that it doesn't (I would have expected "AA" as the result). Is there a way to get

Re: [RELEASED] Python 3.5.0b2 is now available

2015-06-01 Thread MRAB
On 2015-06-01 21:57, Terry Reedy wrote: On 6/1/2015 7:48 AM, MRAB wrote: I've just run "Windows x86 executable installer" and "Windows x86-64 executable installer". While installing, the progress messages overwrote each other without clearing the background each time. I saw something like th

Re: Using a particular python binary with venv

2015-06-01 Thread greenbay . graham
http://bugs.python.org/issue24356 -- https://mail.python.org/mailman/listinfo/python-list

Re: Using a particular python binary with venv

2015-06-01 Thread Carl Meyer
On 06/01/2015 04:07 PM, greenbay.gra...@gmail.com wrote: > On Tuesday, 2 June 2015 09:43:37 UTC+12, Carl Meyer wrote: >> On 06/01/2015 03:33 PM, orotau wrote: >>> According to this >>> https://docs.python.org/3.4/library/venv.html#module-venv 'Each >>> virtual environment has its own Python bina

Re: Using a particular python binary with venv

2015-06-01 Thread greenbay . graham
On Tuesday, 2 June 2015 09:43:37 UTC+12, Carl Meyer wrote: > On 06/01/2015 03:33 PM, orotau wrote: > > According to this > > https://docs.python.org/3.4/library/venv.html#module-venv 'Each > > virtual environment has its own Python binary (allowing creation of > > environments with various Pyth

Re: Language design

2015-06-01 Thread TheDoctor
On Wednesday, September 11, 2013 at 6:40:22 PM UTC-5, Steven D'Aprano wrote: > On Wed, 11 Sep 2013 14:30:54 -0700, Mark Janssen wrote: > > > 1) It tried to make Object the parent of every class. > > Tried, and succeeded. Oh? How about: class superdict(dict): """I'm going to extend the

Re: Using Python instead of Bash

2015-06-01 Thread Cecil Westerhof
Op Monday 1 Jun 2015 22:42 CEST schreef Laura Creighton: > In a message of Mon, 01 Jun 2015 21:57:05 +0200, Cecil Westerhof > writes: >>> Truly? That's (very close to) 7 inch by 9 inch, 177.8 mm x 228.6 >>> mm and 7 by 9 is what pre-metric Britian called 'Small Post >>> Quarto'. I wonder if this m

Pyton re module and POSIX equivalence classes

2015-06-01 Thread Tim Chase
Is Python supposed to support POSIX "equivalence classes"? I tried the following in Py2 and Py3: >>> re.sub('[[=a=]]', 'A', 'aáàãâä', re.U) 'aáàãâä' which suggests that it doesn't (I would have expected "AA" as the result). Is there a way to get this behavior? I found that perl knows a

Re: Using a particular python binary with venv

2015-06-01 Thread Laura Creighton
In a message of Mon, 01 Jun 2015 14:33:56 -0700, greenbay.gra...@gmail.com writ es: >According to this https://docs.python.org/3.4/library/venv.html#module-venv >'Each virtual environment has its own Python binary (allowing creation of >environments with various Python versions)' >So how would I

Re: Using a particular python binary with venv

2015-06-01 Thread Carl Meyer
On 06/01/2015 03:33 PM, greenbay.gra...@gmail.com wrote: > According to this > https://docs.python.org/3.4/library/venv.html#module-venv 'Each > virtual environment has its own Python binary (allowing creation of > environments with various Python versions)' > > So how would I create a virtual e

Re: Using a particular python binary with venv

2015-06-01 Thread Ian Kelly
On Mon, Jun 1, 2015 at 3:33 PM, wrote: > According to this https://docs.python.org/3.4/library/venv.html#module-venv > 'Each virtual environment has its own Python binary (allowing creation of > environments with various Python versions)' > So how would I create a virtual environment using the

Using a particular python binary with venv

2015-06-01 Thread greenbay . graham
According to this https://docs.python.org/3.4/library/venv.html#module-venv 'Each virtual environment has its own Python binary (allowing creation of environments with various Python versions)' So how would I create a virtual environment using the venv module that has a Python 2.7 binary? tia g

Re: Zero [was Re: What is considered an "advanced" topic in Python?]

2015-06-01 Thread Terry Reedy
On 6/1/2015 9:14 AM, Skip Montanaro wrote: remove. Maybe you should just install a decent spam filter or switch to Gmail, which has a functioning spam filter (unlike Yahoo...) For me, Yahoo's spam filter is comparable to Gmail's. (My udel account is actually handl

Re: Everything is an object in python - object class and type class

2015-06-01 Thread vern . muhr
On Sunday, May 31, 2015 at 7:34:20 AM UTC-7, Eddilbert Macharia wrote: > Hello All , > > I'm wrecking my head trying to understand. where the class object comes into > play . > > Is it only meant to act as base class and does it mean there is an actual > class called object in python which all

Re: [RELEASED] Python 3.5.0b2 is now available

2015-06-01 Thread Zachary Ware
On Mon, Jun 1, 2015 at 3:57 PM, Terry Reedy wrote: > On 6/1/2015 7:48 AM, MRAB wrote: > >> I've just run "Windows x86 executable installer" and "Windows x86-64 >> executable installer". >> >> While installing, the progress messages overwrote each other without >> clearing the background each time.

Re: [RELEASED] Python 3.5.0b2 is now available

2015-06-01 Thread Terry Reedy
On 6/1/2015 7:48 AM, MRAB wrote: I've just run "Windows x86 executable installer" and "Windows x86-64 executable installer". While installing, the progress messages overwrote each other without clearing the background each time. I saw something like that too. Can you open a tracker issue wit

Re: Using Python instead of Bash

2015-06-01 Thread Laura Creighton
In a message of Mon, 01 Jun 2015 21:57:05 +0200, Cecil Westerhof writes: >> Truly? That's (very close to) 7 inch by 9 inch, 177.8 mm x 228.6 mm >> and 7 by 9 is what pre-metric Britian called 'Small Post Quarto'. >> I wonder if this merely a coincidence, or does some software really >> still like

super

2015-06-01 Thread TheDoctor
Missive #02441: super() If you're going to use object composition, creating a super (no pun intended) class, you are forming an explicit object hierarchy (unlike mix-in style). In this case, if the method exists in the parent class, you shouldn't give the user (or subclass) the choice of call

Re: Using Python instead of Bash

2015-06-01 Thread Cecil Westerhof
Op Monday 1 Jun 2015 20:42 CEST schreef Laura Creighton: > In a message of Mon, 01 Jun 2015 18:44:01 +0200, Cecil Westerhof > writes: >> Op Monday 1 Jun 2015 17:44 CEST schreef Laura Creighton: >> >>> In a message of Mon, 01 Jun 2015 12:44:34 +0200, Cecil Westerhof >>> writes: Also the funny

Re: Somebody is trying to install python

2015-06-01 Thread Chris Angelico
On Tue, Jun 2, 2015 at 4:16 AM, Laura Creighton wrote: > trying to install a binary, opp system windows xp tried python 2 and three > both failed said incompatible processor, my pc is 1 year old with an AMD > 6200 6 core processor > thanks > Dave Hi David! Do you know what edition of Windows you

Re: Using Python instead of Bash

2015-06-01 Thread Laura Creighton
In a message of Mon, 01 Jun 2015 18:44:01 +0200, Cecil Westerhof writes: >Op Monday 1 Jun 2015 17:44 CEST schreef Laura Creighton: > >> In a message of Mon, 01 Jun 2015 12:44:34 +0200, Cecil Westerhof >> writes: >>> Also the funny thing is that I first scanned it. But it gave >>> several problems.

Re: What is considered an "advanced" topic in Python?

2015-06-01 Thread Grant Edwards
On 2015-06-01, Mark Lawrence wrote: > On 01/06/2015 18:02, Grant Edwards wrote: >> On 2015-06-01, BartC wrote: >> >>> At one time the choice was integer or floating point in many languages, >>> unless you were specifically using a business language such as Cobol. >> >> My recollection in the earl

Somebody is trying to install python

2015-06-01 Thread Laura Creighton
The person who is being told that their processor is incompatible is back. But replied to me, not the list. reply to: https://mail.python.org/pipermail/python-list/2015-May/691557.html Laura --- Forwarded Message Return-Path: From: "David Skardon" To: "Laura Creighton" References: <414E2

Re: What is considered an "advanced" topic in Python?

2015-06-01 Thread Mark Lawrence
On 01/06/2015 18:02, Grant Edwards wrote: On 2015-06-01, BartC wrote: At one time the choice was integer or floating point in many languages, unless you were specifically using a business language such as Cobol. My recollection in the early days of home computers is that many BASIC implement

replace parens update

2015-06-01 Thread Littlefield, Tyler
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello all: I've put a new version here: https://dl.dropboxusercontent.com/u/10204868/replace_parens.py It's for me, a lot easier to understand. It uses regex to replace parens rather than using a state machine and conforms to the python standards for

Re: Zero [was Re: What is considered an "advanced" topic in Python?]

2015-06-01 Thread Mark Lawrence
On 01/06/2015 14:14, Skip Montanaro wrote: Maybe you should just install a decent spam filter or switch to Gmail, which has a functioning spam filter (unlike Yahoo...) Okay I'll bite, what's wrong with the Yahoo spam filter? -- My fellow Pythonistas, ask not what

Re: What is considered an "advanced" topic in Python?

2015-06-01 Thread Marko Rauhamaa
MRAB : > 1971 was also the year we started the switch over to the metric > system. It was going to be done gradually over a 10-year period. It's > still a work in progress... Same here in Finland. Minutes, hours and degrees persist as do calories, teaspoons and carats. Marko -- https://mail.py

  1   2   >