Python-UK Community on google+

2012-12-07 Thread Martin P. Hellwig
of. You can find it here: https://plus.google.com/u/0/communities/109155400666012015869 Hope to see you soon :-) Martin P. Hellwig -- http://mail.python.org/mailman/listinfo/python-list

Re: debugging in eclipse

2012-11-15 Thread Martin P. Hellwig
On Thursday, 15 November 2012 12:29:04 UTC, chip...@gmail.com wrote: > Hi all! > > > > I have a stupid problem, for which I cannot find a solution... > > > > I have a python module, lets call it debugTest.py. > > > > and it contains: > > def test(): > > a=1 > > b=2 > > c=a

Re: Article on the future of Python

2012-09-25 Thread Martin P. Hellwig
On Tuesday, 25 September 2012 09:14:27 UTC+1, Mark Lawrence wrote: > Hi all, > > I though this might be of interest. > http://www.ironfroggy.com/software/i-am-worried-about-the-future-of-python > -- > > Cheers. > Mark Lawrence. I glanced over the article but it seems to me another 'I am afraid

Re: simple client data base

2012-09-03 Thread Martin P. Hellwig
On Monday, 3 September 2012 15:12:21 UTC+1, Manatee wrote: > Hello all, I am learning to program in python. I have a need to make a > > program that can store, retrieve, add, and delete client data such as > > name, address, social, telephone number and similar information. This > > would be a

Re: Writing a wrapper - any tips?

2012-07-13 Thread Martin P. Hellwig
On Friday, 13 July 2012 05:03:23 UTC+1, Temia Eszteri wrote: > I'm going to be looking into writing a wrapper for the Allegro 5 game > development libraries, either with ctypes or Cython. They technically > have a basic 1:1 ctypes wrapper currently, but I wanted to make > something more pythonic,

Re: code review

2012-06-30 Thread Martin P. Hellwig
On Saturday, 30 June 2012 21:30:45 UTC+1, Alister wrote: > On Sat, 30 Jun 2012 21:38:58 +0200, Thomas Jollans wrote: > > > On 06/30/2012 08:39 PM, Thomas 'PointedEars' Lahn wrote: > >> Peter Otten wrote: > >> > >>> If you spell it > >>> > >>> def is_valid_password(password): > >>> return mud

Re: code review

2012-06-29 Thread Martin P. Hellwig
On Friday, 29 June 2012 20:41:11 UTC+1, Alister wrote: > On Fri, 29 Jun 2012 09:03:22 -0600, Littlefield, Tyler wrote: > > > On 6/29/2012 1:31 AM, Steven D'Aprano wrote: > >> On Thu, 28 Jun 2012 20:58:15 -0700, alex23 wrote: > >> > >>> On Jun 29, 12:57 pm, "Littlefield, Tyler" wrote: > I wa

Re: Open Source: you're doing it wrong - the Pyjamas hijack

2012-05-09 Thread Martin P. Hellwig
uably they are not mistakes at all, are not easy forgotten and can end up haunting you. I hope you will take these comments with you as a lesson learned, I do wish you all the best and look forward to the improvements you are going to contribute. -- Martin P. Hellwig (mph) -- http://mail.pytho

Re: Python randomly exits with Linux OS error -9 or -15

2012-04-09 Thread Martin P. Hellwig
On 09/04/2012 11:01, Janis wrote: My experience is that these kind of behaviors are observed when (from most to least likeliness): - Your kernel barfs on a limit, e.g. space/inodes/processes/memory/etc. - You have a linked library mismatch - You have bit rot on your system - You have a faulty l

Re: f python?

2012-04-08 Thread Martin P. Hellwig
On 08/04/2012 12:11, Xah Lee wrote: Hi Xah, You clearly didn't want help on this subject, as you really now how to do it anyway. But having read your posts over the years, I'd like to give you an observation on your persona, free of charge! :-) You are actually a talented writer, some may fi

Re: Eclipse, C, and Python

2012-03-20 Thread Martin P. Hellwig
On 20/03/2012 06:00, Richard Medina Calderon wrote: Hello Forum. I have installed Python comnpiler in Eclipse Classic for Windows. After a while I have installed the C compiler. However, somehow now when I try to run my code in Python it shows me for default Ant Run -->Ant Build I switched my

Re: speaking at PyCon

2012-01-31 Thread Martin P. Hellwig
On 29/01/2012 03:32, Eric Snow wrote: This is my first year speaking at PyCon, so I solicited speaking/preparation advice from a bunch of folks, particularly focusing on the PyCon speaking experience. I've compiled the results and put them online: http://ref.rtfd.org/speakers This is still rou

Re: Where to put data

2012-01-26 Thread Martin P. Hellwig
On 25/01/2012 17:26, bvdp wrote: Well once you think about distributing, here is the guide line I use: - If it is meant as a library that can be 'imported' in python: > site-packages is the place to be, some linux distros are rather creative with them so be careful. - If it is a 'stand-alon

Re: The devolution of English language and slothful c.l.p behaviors exposed!

2012-01-24 Thread Martin P. Hellwig
On 24/01/2012 14:51, J wrote: On Tue, Jan 24, 2012 at 09:05, Martin P. Hellwig wrote: On 24/01/2012 05:57, Rick Johnson wrote: I would wish that pedantic citizens of the British colony in America stopped calling whatever misinterpreted waffle they produce, English. I, sir, as a citizen of

Re: The devolution of English language and slothful c.l.p behaviors exposed!

2012-01-24 Thread Martin P. Hellwig
On 24/01/2012 05:57, Rick Johnson wrote: I would wish that pedantic citizens of the British colony in America stopped calling whatever misinterpreted waffle they produce, English. -- mph -- http://mail.python.org/mailman/listinfo/python-list

Re: icmp and raw sockets in python

2011-12-13 Thread Martin P. Hellwig
On 13/12/2011 16:50, Sagy Drucker wrote: hello Hi i am relatively new to python, so please be considerate... As I am only responding to one of your questions, perhaps it would be best if you don't get any other more helpful replies to split your questions up and post them separately. i'm im

Re: Clever hack or code abomination?

2011-12-01 Thread Martin P. Hellwig
On 01/12/2011 03:15, Roy Smith wrote: Well, I have seen much worse, so the WTFs/minute(*) count won't be too bad. However, as general rule for readability; If you think you have to ask, don't bother asking, spend that time rethinking and write a more readable solution. *) http://www.osnews

Re: Both Python 2.5.2 and 2.7.2 flop the same way under Win 7

2011-11-17 Thread Martin P. Hellwig
On 17/11/2011 23:54, W. eWatson wrote: My mistake above. I was talking about the previous 2.5.2 of install in Win7. Where I'm at is 2.7.2 now. However, I still find in very odd there is no Edit with IDLE when I right-click on junk.py. That's the way it worked on 2.5.2 on my XP and earlier, 2010,

Re: Execute a command on remote machine in python

2011-11-15 Thread Martin P. Hellwig
On 11/15/11 12:04, Roark wrote: Hi, I am first time trying my hands on python scripting and would need some guidance from the experts on my problem. I want to execute a windows command within python script from a client machine on a remote target server, and would want the output of the command

Re: webapp development in pure python

2011-10-25 Thread Martin P. Hellwig
On 10/25/11 15:13, Arnaud Delobelle wrote: On 25 October 2011 14:50, Laszlo Nagy wrote: Hi, Anyone knows a framework for webapp development? I'm not talking about javascript/html compilers and ajax frameworks. I need something that does not require javascript knowledge, just pure Python. (S

Re: Language Enhancement Idea to help with multi-processing (your opinions please)

2011-10-13 Thread Martin P. Hellwig
On 13/10/2011 15:13, Stefan Behnel wrote: Martin P. Hellwig, 13.10.2011 14:35: I was wondering if there could be an advantage to add another control flow statement. Changes at that level must be very well justified, are often rejected for the reason of being not too complicated to write in

Language Enhancement Idea to help with multi-processing (your opinions please)

2011-10-13 Thread Martin P. Hellwig
First of all let me say that I have no authority or knowledge of language design or multi-processing except from a user point of view, having a decade or so experience. I would like your opinion and appreciate any feedback and value any hints to documentation, procedures or related ramblings :-)

Re: Python without a tty

2011-09-29 Thread Martin P. Hellwig
On 29/09/2011 10:21, Steven D'Aprano wrote: I have a Python script which I would like to test without a tty attached to the process. I could run it as a cron job, but is there an easier way? I am running Linux. Well you could double fork and drop the parent, that would lose the tty which is

Re: How to daemonize a HTTPServer

2011-09-01 Thread Martin P. Hellwig
On 01/09/2011 04:16, babbu Pehlwan wrote: I have written a http server using BaseHTTPServer module. Now I want to instantiate it through another python script. The issue here is after instantiate the control doesn't come back till the server is running. Please suggest. Sounds like something you

Re: Syntactic sugar for assignment statements: one value to multiple targets?

2011-08-16 Thread Martin P. Hellwig
On 03/08/2011 02:45, gc wrote: a,b,c,d,e = *dict() where * in this context means something like "assign separately to all. Any thoughts? Thanks! Well got a thought but I am afraid it is the opposite of helpful in the direct sense. So if you don't want to hear it skip it :-) Although I c

Re: Ten rules to becoming a Python community member.

2011-08-16 Thread Martin P. Hellwig
On 16/08/2011 18:51, Prasad, Ramit wrote: Incorrect past tense usage of "used to": """ I "used to" wear wooden shoes """ Incorrect description using "used to": """ I have become "used to" wearing wooden shoes """ Correct usage of "used to": """ Wooden shoes can be "used to" torture someone

Re: Rant on web browsers

2011-06-14 Thread Martin P. Hellwig
On 14/06/2011 07:31, Chris Angelico wrote: But if anyone feels like writing an incompatible browser, please can you add Python scripting? You might find that Pyjamas already fill your needs python/javascript wise. It is truly great to just write python, translate it, and then have it work in

Re: English Idiom in Unix: Directory Recursively

2011-05-18 Thread Martin P. Hellwig
On 17/05/2011 23:20, Ian Kelly wrote: On Tue, May 17, 2011 at 4:26 PM, Xah Lee wrote: Though, if you think about it, it's not exactly a correct description. “Recursive”, or “recursion”, refers to a particular type of algorithm, or a implementation using that algorithm. Only when used as progr

Re: py3k buffered IO - flush() required between read/write?

2011-05-11 Thread Martin P. Hellwig
On 11/05/2011 19:08, Genstein wrote: On 11/05/2011 19:24, Terry Reedy wrote: writing and reading. If you want others to look at this more, you should 1) produce a minimal* example that demonstrates the questionable behavior, and 2) show the comparative outputs that raise your question. Thanks

Re: Development tools and practices for Pythonistas

2011-04-26 Thread Martin P. Hellwig
On 26/04/2011 14:39, snorble wrote: I would strongly advice to get familiar with: - Lint tools (like PyLint) - Refactoring - Source Control Systems (like Mercurial Hg) - Unit Testing with Code Coverage Followed by either writing your own toolset that integrates all of the above or start learnin

Re: my computer is allergic to pickles

2011-03-07 Thread Martin P. Hellwig
On 05/03/2011 01:56, Bob Fnord wrote: Any comments, suggestions? No but I have a bunch of pseudo-questions :-) What version of python are you using? How about your OS and bitspace (32/64)? Have you also tried using the non-c pickle module? If the data is very simple in structure, perhaps s

Re: Newbie...

2011-02-24 Thread Martin P. Hellwig
On 02/24/11 19:22, wisecrac...@tesco.net wrote: Hi all... I am new to this list so treat me gently... ;o) I for one welcome you :-) I use Python almost totally differently to the vast majority of people. I like "banging the metal". Well I can assure you that although you might be indeed i

Re: Displaying SVG in tkinter using cairo and rsvg

2011-02-16 Thread Martin P. Hellwig
On 02/16/11 09:04, Arndt Roger Schneider wrote: raster images from SVG: There are multiple methods to convert a scalable vector graphic into a bitmap. In addition to cairo, librsvg and rsvg imageMagick contains a vector graphic format similar to svg--gradients and transparency are problematic fo

Displaying SVG in tkinter using cairo and rsvg

2011-02-15 Thread Martin P. Hellwig
Hi all, Information on using tkinter for displaying an svg image seems a bit low spread on the Internet. I recently played around with pygame and svg and realized, hold on this can be done with tk too. So I thought I post a little example for future generations :-) (and also have stored at ht

Re: locale settings and date parsing under windows

2011-02-03 Thread Martin P. Hellwig
On 02/03/11 10:59, AlienBaby wrote: On Feb 3, 10:22 am, AlienBaby wrote: Hi, I'm attempting to convert some date-time strings from a text file under windows into a datetime object as returned by strptime() However, the strings can represent dates in various formats based on the country of ori

Re: Should there be a 'core' python install? (was Re: Tkinter: The good, the bad, and the ugly!)

2011-01-17 Thread Martin P. Hellwig
On 01/17/11 22:00, rantingrick wrote: On Jan 17, 2:09 pm, "Martin P. Hellwig" wrote: fortunately it is not my call and I actually quite like Tkinter. Are you sure about that Martin? :))) From: "Martin P. Hellwig" Newsgroups: comp.lang.python Subject: Re: GUIs - A Modes

Should there be a 'core' python install? (was Re: Tkinter: The good, the bad, and the ugly!)

2011-01-17 Thread Martin P. Hellwig
On 01/17/11 19:39, rantingrick wrote: Q: If you could replace Tkinter with any module/library (THAT IS NOT A GUI OR IDE!!) what would you like to see fill its place? Some systems, like FreeBSD have Tkinter and IDLE as a separate package which is not installed by default. Purely because those

Re: Multiple independently started python processes and sharing of a module

2011-01-14 Thread Martin P. Hellwig
On 01/14/11 10:05, Kushal Kumaran wrote: This might help though: https://code.google.com/p/modwsgi/wiki/ProcessesAndThreading It seems if you're not using 'daemon' mode, global data might be shared. Yes I read that thoroughly before I started out implementing a solution. But in my case I want

Re: Multiple independently started python processes and sharing of a module

2011-01-14 Thread Martin P. Hellwig
On 01/14/11 03:04, Kushal Kumaran wrote: - Original message - Hi all, I have the following problem (which I already have a hacked around solution that works but I'd would like some more input on it): I have a situation where multiple python processes are started independently from each

Multiple independently started python processes and sharing of a module

2011-01-13 Thread Martin P. Hellwig
uared wheel or am totally missing the point. Any suggestions/comments are greatly appreciated, Thanks in advanced, Martin P. Hellwig -- http://mail.python.org/mailman/listinfo/python-list

Re: Python documentation too difficult for beginners

2010-11-02 Thread Martin P. Hellwig
On 11/02/10 10:42, jk wrote: Is there much chance that the Python maintainers will change their documentation system to make it more like Java or PHP? How would I go about trying to make that happen? I am by no means an authority however since you ask it here I feel compelled to give you my opi

Re: pylint -- should I just ignore it sometimes?

2010-10-21 Thread Martin P. Hellwig
On 10/20/10 22:09, Seebs wrote: On 2010-10-20, Matteo Landi wrote: Another situation in which I needed to disable such kind of warnings is while working with graphics modules. I often use variable names such as x, y, z for coordinates, or r,g,b for colors. Would longer names make the reader's l

Re: pylint -- should I just ignore it sometimes?

2010-10-19 Thread Martin P. Hellwig
On 10/19/10 23:36, Seebs wrote: It seems like a very odd measure of complexity; is it really that unusual for objects to have more than seven meaningful attributes? Speaking without context here, so take it with as much salt as required ;-), it is not that unusual. However there are some thing

Re: pylint -- should I just ignore it sometimes?

2010-10-19 Thread Martin P. Hellwig
On 10/19/10 20:57, Seebs wrote: So, I'm messing around with pylint. Quite a lot of what it says is quite reasonable, makes sense to me, and all that. There's a few exceptions. Well, as with all styles IMHO, if there is a _good_ reason to break it, then by all means do, but you might want to c

Re: looping through possible combinations of McNuggets packs of 6,9 and 20

2010-08-13 Thread Martin P. Hellwig
On 08/13/10 10:46, Peter Otten wrote: Martin P. Hellwig wrote: SPOILER ALTER: THIS POST CONTAINS A POSSIBLE SOLUTION No it wasn't :-) which should be 1*9 + 2*6 What am I missing? Aah interesting, 21 % 9 returns 3 instead of 12, which makes sense of course. I guess the algorithm h

Re: looping through possible combinations of McNuggets packs of 6,9 and 20

2010-08-13 Thread Martin P. Hellwig
SPOILER ALTER: THIS POST CONTAINS A POSSIBLE SOLUTION On 08/12/10 21:41, News123 wrote: On 08/12/2010 09:56 PM, Martin P. Hellwig wrote: On 08/11/10 21:14, Baba wrote: How about rephrasing that question in your mind first, i.e.: For every number that is one higher then the previous one

Re: looping through possible combinations of McNuggets packs of 6,9 and 20

2010-08-12 Thread Martin P. Hellwig
On 08/11/10 21:14, Baba wrote: How about rephrasing that question in your mind first, i.e.: For every number that is one higher then the previous one*: If this number is dividable by: 6 or 9 or 20 or any combination of 6, 9, 20 than this number _can_ be bought in an exac

Re: GUI automation tool (windows)

2010-08-10 Thread Martin P. Hellwig
On 08/10/10 20:13, News123 wrote: On 08/10/2010 12:25 PM, Alex Barna wrote: On Aug 10, 10:05 am, Lawrence D'Oliveiro> Can’t understand the point to it. “GUI automation” is a contradiction in terms, because a GUI is designed for use by humans to do manual tasks, not ones that can be automated.

Re: xmlrpc and processes

2010-08-09 Thread Martin P. Hellwig
On 08/09/10 07:50, iu2 wrote: Hi, I have a SimpleXMLRPCServer running on one PC. I need several ServerProxy-s talking to it, each one running on a different PC. That is, I run on each PC a client application, that talks to the one server using xml-rpc. Is the xml-rpc designed to work like this?

Re: python styles: why Use spaces around arithmetic operators?

2010-07-26 Thread Martin P. Hellwig
On 07/27/10 00:06, rantingrick wrote: On Jul 26, 5:20 pm, Peng Yu wrote: This webpagehttp://www.python.org/dev/peps/pep-0008/recommends the following. It looks to me that both styles are fine. Could anybody let me know what the rationale is behind this recommendation? The rational is simple.

Re: grailbrowser now running under python 2.5 (probably above too)

2010-07-11 Thread Martin P. Hellwig
On 07/11/10 04:59, Luke Kenneth Casson Leighton wrote: source at: http://github.com/lkcl/grailbrowser $ python grail.py (note the lack of "python1.5" or "python2.4") conversion of the 80 or so regex's to re has been carried out. entirely successfully or not is a matter yet to be determined. al

Re: any issues with long running python apps?

2010-07-09 Thread Martin P. Hellwig
On 07/09/10 20:13, Les Schaffer wrote: i have been asked to guarantee that a proposed Python application will run continuously under MS Windows for two months time. And i am looking to know what i don't know. Get a good lawyer and put into the contract, the last thing you want is a windows updat

Re: Opinions please -- how big should a single module grow?

2010-07-09 Thread Martin P. Hellwig
On 07/09/10 05:37, Steven D'Aprano wrote: This is a style question rather than a programming question. How large (how many KB, lines, classes, whatever unit of code you like to measure in) should a module grow before I should break it up into a package? I see that, for example, decimal.py is> 3

Re: Download Microsoft C/C++ compiler for use with Python 2.6/2.7 ASAP

2010-07-06 Thread Martin P. Hellwig
On 07/06/10 21:19, sturlamolden wrote: On 6 Jul, 21:49, Christian Heimes wrote: I agree, the situation isn't ideal. I see if I can get in contact with Microsoft's open source team. Perhaps they can keep the download link to VS 2008 EE working. It seems the MSDN subscription required to get V

Re: Download Microsoft C/C++ compiler for use with Python 2.6/2.7 ASAP

2010-07-06 Thread Martin P. Hellwig
On 07/06/10 16:50, sturlamolden wrote: Just a little reminder: Microsoft has withdrawn VS2008 in favor of VS2010. The express version is also unavailable for download.>:(( Public download that is, people like me who have a MSDN subscription can still download old versions like Visual Studio

Re: git JSONRPC web service and matching pyjamas front-end

2010-06-30 Thread Martin P. Hellwig
On 06/30/10 03:29, CM wrote: On Jun 29, 6:54 pm, Luke Kenneth Casson Leighton wrote: as more than just a proof-of-concept but to get pyjamas out of looking like "a nice toy, doesn't do much, great demos, shame about real life", If may be generated with pyjamas but I'm not sure how this fulfil

Re: compile as exe with arguments

2010-06-28 Thread Martin P. Hellwig
On 06/28/10 11:18, dirknbr wrote: I want to compile as an exe using py2exe but the function should take arguments. How would I do this? Currently my exe runs (no errors) but nothing happens. I am not sure if I understand your question correctly, have you used a module like optparse and it doe

Re: Community (A Modest Proposal)

2010-06-13 Thread Martin P. Hellwig
At first I wanted to response in the style of 'karma is a bitch' or 'what goes around comes around' but then I considered that won't be helping much, so I only did at first in a meta sort of way, sorry for that. The thing is that sometimes for no good or appealing reasons, which I personally t

safer ctype? (was GUIs - A modest Proposal)

2010-06-12 Thread Martin P. Hellwig
On 06/12/10 08:21, Martin v. Loewis wrote: The issue is not that you may mistakes in the ctypes code, thus allowing users to crash Python. The issue is that if users remove ctypes (which they may want to do because it's not trustworthy), then your module will stop working (unless you have a fall

Re: a +b ?

2010-06-11 Thread Martin P. Hellwig
On 06/11/10 15:19, superpollo wrote: yanhua ha scritto: hi,all?? s = input() this does not work Well it does if it is python 3 and not 2 as you are using :-) -- mph -- http://mail.python.org/mailman/listinfo/python-list

Re: GUIs - A Modest Proposal

2010-06-10 Thread Martin P. Hellwig
On 06/11/10 07:00, rantingrick wrote: I would bet that only myself, Kevin, and only a handful of others use Tkinter for anything more than education purposes. AFIK, Kevin is THE ONLY PYTHON programmer producing real professional GUI's with Tkinter -- i encourage anyone else to speak up if your o

Re: GUIs - A Modest Proposal

2010-06-09 Thread Martin P. Hellwig
On 06/09/10 14:37, D'Arcy J.M. Cain wrote: On 09 Jun 2010 06:05:43 GMT Steven D'Aprano wrote: I think the only way to end this pointless discussion is this: "Hitler would have loved Tkinter!" Sorry, "Quirk's Exception" to Godwin's Law says that you can't invoke Godwin's Law on purpose. How

Re: GUIs - A Modest Proposal

2010-06-08 Thread Martin P. Hellwig
On 06/08/10 22:14, Ethan Furman wrote: Grant Edwards wrote: On 2010-06-08, Martin v. Loewis wrote: TkInter -> Tcl -> Tk -> Xlib Is the Tcl intepreter really need to use this GUI? Why not: (Pyton ->) Tkinter-API -> Xlib ? Even if this was possible (which it is not) Why is it not possible?

Re: GUIs - A Modest Proposal

2010-06-08 Thread Martin P. Hellwig
On 06/08/10 07:59, rantingrick wrote: On Jun 8, 1:39 am, "Martin P. Hellwig" wrote: On 06/06/10 03:22, ant wrote: I get the strong feeling that nobody is really happy with the state of Python GUIs. Tkinter is not widely liked, but is widely distributed. WxPython and PyGtk are bot

Re: GUIs - A Modest Proposal

2010-06-07 Thread Martin P. Hellwig
On 06/06/10 03:22, ant wrote: I get the strong feeling that nobody is really happy with the state of Python GUIs. Tkinter is not widely liked, but is widely distributed. WxPython and PyGtk are both powerful, but quirky in different ways. PyQt is tied to one platform. And there are dozens more.

Re: Python Forum

2010-06-03 Thread Martin P. Hellwig
On 06/03/10 12:46, Michele Simionato wrote: On Jun 3, 12:28 pm, "Martin P. Hellwig" wrote: On the other hand it might not be so bad that you don't get questions from users here who are unable to use a nntp reader or news to mail service. I am unable to use a nntp reader

Re: Python Forum

2010-06-03 Thread Martin P. Hellwig
On 06/03/10 11:16, Pierre Quentel wrote: I'm not saying that pythonforum.org is the best solution but it certainly looks more attractive than c.l.p. to the new generation of Python users - Pierre On the other hand it might not be so bad that you don't get questions from users here who are un

Re: multiprocessing and accessing server's stdout

2010-05-28 Thread Martin P. Hellwig
On 05/28/10 21:44, Adam Tauno Williams wrote: On Fri, 2010-05-28 at 15:41 +0100, Martin P. Hellwig wrote: On 05/28/10 13:17, Adam Tauno Williams wrote: You should be able to point it any any file-like object. But, again, why? If you have the data in the process why send it to stdout and

Re: multiprocessing and accessing server's stdout

2010-05-28 Thread Martin P. Hellwig
On 05/28/10 13:17, Adam Tauno Williams wrote: You should be able to point it any any file-like object. But, again, why? If you have the data in the process why send it to stdout and redirect it. Why not just send the data to the client directly? Well you might want to multiplex it to more

Re: if, continuation and indentation

2010-05-27 Thread Martin P. Hellwig
On 05/27/10 13:22, HH wrote: I have a question about best practices when it comes to line wrapping/ continuation and indentation, specifically in the case of an if statement. When I write an if statement with many conditions, I prefer to use a parenthesis around the whole block and get the impli

Re: confusing error with nntplib

2010-05-27 Thread Martin P. Hellwig
On 05/27/10 02:01, Eduardo Alvarez wrote: When trying to use nntplib to connect to the news server nntp.aioe.org, a bizarre sequence of events occurs: 1) I import the module, and create an instance, as follows: s = nntplib.NNTP('nntp.aioe.org') I get no errors, which leads me to believe all we

Re: Chatroom

2010-05-24 Thread Martin P. Hellwig
On 05/24/10 19:50, narcissus wrote: Hello , I want to create a program that is one chatroom and everyone has this program can Enter into that chatroom. how can i do this? and i want gui for it too (GTK) What have you tried so far? -- mph -- http://mail.python.org/mailman/listinfo/python-list

Re: where are the program that are written in python?

2010-05-21 Thread Martin P. Hellwig
On 05/21/10 11:21, Deep_Feelings wrote: python is not a new programming language ,it has been there for the last 15+ years or so ? right ? Yeah about the same as Java however by having a look at this page http://wiki.python.org/moin/Applications i could not see many programs written in py

250

2010-05-20 Thread Martin P. Hellwig
On 05/20/10 07:51, cosmeticsafrolatino wrote: hi 250 locahost.local Hello WimaxUser3645-219.wateen.net [110.36.45.219], pleased to meet you -- http://mail.python.org/mailman/listinfo/python-list

Re: Picking a license

2010-05-09 Thread Martin P. Hellwig
On 05/09/10 21:06, Stephen Hansen wrote: On Sun, May 9, 2010 at 12:33 PM, Martin P. Hellwig mailto:martin.hell...@dcuktec.org>> wrote: On 05/09/10 18:24, Stephen Hansen wrote: Wait, what? Why shouldn't I profit repeatedly from the "same work a

Re: Picking a license

2010-05-09 Thread Martin P. Hellwig
On 05/09/10 18:24, Stephen Hansen wrote: Wait, what? Why shouldn't I profit repeatedly from the "same work already done"? *I* created, its *mine*. I put blood, sweat and tears into it and perhaps huge amounts of resources, risking financial security and sanity, and you're arguing I shouldn't

Re: Picking a license

2010-05-09 Thread Martin P. Hellwig
On 05/09/10 04:49, Paul Rubin wrote: As I read it, he is saying that when someone releases free software, they have "for all intends and purposes lost control over its use", so they "should have made peace with the fact" and surrender gracefully. I'm asking why he doesn't think Microsoft has los

Re: Picking a license

2010-05-08 Thread Martin P. Hellwig
On 05/08/10 09:37, Steven D'Aprano wrote: If encouraging third parties to take open source code and lock it up behind proprietary, closed licences *isn't* a moral hazard, then I don't know what one is. I fail to see what is morally wrong with it. When I ,as the author, share my work to the pu

Re: Teaching Programming

2010-05-05 Thread Martin P. Hellwig
On 05/04/10 12:59, superpollo wrote: Martin P. Hellwig ha scritto: For the corner cases (I can think of a couple) it is good to know you can use ';' most of the time. most but not always as i noted (think about loops or function definition) Well through in some exec magic

Re: Teaching Programming

2010-05-04 Thread Martin P. Hellwig
On 05/04/10 11:28, superpollo wrote: Samuel Williams ha scritto: I personally like indentation. I just wonder whether it is an issue that some people will dislike. there might be problems if for example you generate code from a one-line template. Well a one-line template code generator are

Re: Linux servers, network and file names

2010-04-23 Thread Martin P. Hellwig
On 04/22/10 15:13, Infinity77 wrote: For me: //SERVER/gavana/Folder/FileName.txt Colleague: //SERVER/Colleague/Folder/FileName.txt So, no matter what I do, the file name stored in the database is user- dependent and not universal and common to all of us. If that user dependent part happens t

Re: Building a GUI Toolkit

2010-04-20 Thread Martin P. Hellwig
On 04/20/10 21:15, Martin P. Hellwig wrote: On 04/20/10 19:53, Lie Ryan wrote: Rather than writing a windowing toolkit from the low-level, I would rather like to see some wrapper for existing windowing toolkit which uses more pythonic idioms. Most popular python GUI toolkit currently in use

Re: Building a GUI Toolkit

2010-04-20 Thread Martin P. Hellwig
On 04/20/10 19:53, Lie Ryan wrote: Rather than writing a windowing toolkit from the low-level, I would rather like to see some wrapper for existing windowing toolkit which uses more pythonic idioms. Most popular python GUI toolkit currently in use are only a simple thin wrapper over the librar

Re: Building a GUI Toolkit

2010-04-18 Thread Martin P. Hellwig
On 04/18/10 12:49, Tim Diels wrote: Hi I was thinking of writing a GUI toolkit from scratch using a basic '2D library'. I have already come across the Widget Construction Kit. My main question is: Could I build a GUI toolkit of reasonable performance with the Widget Construction Kit, would it s

Re: Unit testing errors (testing the platform module)

2010-04-13 Thread Martin P. Hellwig
On 04/13/10 15:01, John Maclean wrote: I normally use languages unit testing framework to get a better understanding of how a language works. Right now I want to grok the platform module; 1 #!/usr/bin/env python 2 '''a pythonic factor''' 3 import unittest 4 import platform 5 6

Re: 2.7 beta 1

2010-04-11 Thread Martin P. Hellwig
On 04/12/10 06:57, Mensanator wrote: On Apr 11, 6:08 pm, Steven D'Aprano wrote: On Sun, 11 Apr 2010 11:54:04 -0700, Mensanator wrote: On Apr 11, 11:53 am, Steven D'Aprano wrote: On Sat, 10 Apr 2010 21:08:44 -0700, Mensanator wrote: Maybe because I'm a user, not a developer. You write co

Re: Cleanup guarantees?

2010-04-08 Thread Martin P. Hellwig
On 04/09/10 05:13, Alf P. Steinbach wrote: Second, I'm unable to find documentation of when they're called and what they do. It seems that (A) when the connection object's stream is exhausted by reading, its close() method is called automatically, and (B) that when the text_reader object's clos

Re: In disGuiodoise?

2010-04-05 Thread Martin P. Hellwig
On 04/05/10 00:05, r wrote: However i have also considered that maybe *all* the "well knowns" are in fact the many colorful personalities of Guido. De vraag is dan natuurlijk of al zijn persoonlijkheden nog steeds nederlands machtig zijn. -- mph -- http://mail.python.org/mailman/listinfo/

Re: off topic but please forgive me me and answer

2010-04-03 Thread Martin P. Hellwig
On 04/03/10 16:46, Patrick Maupin wrote: On Apr 3, 9:43 am, "Martin P. Hellwig"> IMHO, the crackpot in this regard is actually partially right, multiplication does mean that the number must get bigger, however for fractions you multiply four numbers, two numerators and two deno

Re: off topic but please forgive me me and answer

2010-04-03 Thread Martin P. Hellwig
On 04/03/10 16:17, Steven D'Aprano wrote: On Sat, 03 Apr 2010 15:43:41 +0100, Martin P. Hellwig wrote: I am replying to this post not because I disagree but because it postalogically fits the best (I am by no means an expert either). IMHO, the crackpot in this regard is actually part

Re: off topic but please forgive me me and answer

2010-04-03 Thread Martin P. Hellwig
On 04/03/10 14:38, Steve Holden wrote: If you think you will persuade a crackpot to drop his lunacy by logical argument you are clearly an optimist of the first water. But since I like a challenge (and bearing in mind this is OT so I don't claim to be an expert) you might try first of all persu

Re: Get Eclipse/PyDev to run scripts that don't end in .py

2010-03-31 Thread Martin P. Hellwig
On 03/31/10 22:37, J wrote: Is there any way to tell PyDev in Eclipse to run a script that doesn't end in .py? Even if I have to go and manually set something for each file... I've inherited (in a manner of speaking) a dev project that is done in python2.6... I pulled the latest dev branch and

Re: Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Martin P. Hellwig
On 03/26/10 01:10, Rhodri James wrote: Pretty much. In the sense that you're thinking of, every assignment works that way, even the initial "TEST1 = One()". Assignment binds names to objects, though you have to be aware that names can be such exotic things as "t", "a[15]" or "TEST2.__instance_o

Re: Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Martin P. Hellwig
On 03/25/10 23:41, Christian Heimes wrote: Martin P. Hellwig schrieb: What I don't understand why in the second test, the last boolean is True instead of (what I expect) False. Could somebody enlighten me please as this has bitten me before and I am confused by this behavior. Hint: TEST

Don't understand behavior; instance form a class in another class' instance

2010-03-25 Thread Martin P. Hellwig
Hi all, When I run the following snippet (drastically simplified, to just show what I mean): >> import platform, sys class One(object): def __init__(self): self.one = True def change(self): self.one = False class Two(object): def __init__(self): self._inst

Re: Pythonic way to trim and keep leading and trailing whitespace

2010-03-23 Thread Martin P. Hellwig
On 03/23/10 23:38, Tim Chase wrote: Just in case you're okay with a regexp solution, you can use >>> s = "\t\tabc def " >>> import re >>> r = re.compile(r'^(\s*)(.*?)(\s*)$') >>> m = re.match(s) >>> m.groups() ('\t\t', 'abc def', ' ') >>> leading, text, trailing = m.groups() Ahhh regex,

Re: Need to create subprocess...

2010-03-18 Thread Martin P. Hellwig
On 03/18/10 16:17, drstoka wrote: Hello, I have to run a program as a child process inside my python program and redirect it's output through a pipe to a parent program process. So, I wrote this: pipe = Popen('example_program', shell=True, bufsize=0, stdout=PIPE).stdout and it works great. No

Re: multiprocessing on freebsd

2010-03-17 Thread Martin P. Hellwig
On 03/17/10 13:30, Tim Arnold wrote: Hi, I'm checking to see if multiprocessing works on freebsd for any version of python. My server is about to get upgraded from 6.3 to 8.0 and I'd sure like to be able to use multiprocessing. I think the minimal test would be: - import mult

Re: import antigravity

2010-03-16 Thread Martin P. Hellwig
On 03/16/10 19:30, Hans Mulder wrote: Ulrich Eckhardt wrote: Chris Rebert wrote: You're a bit behind the times. If my calculations are right, that comic is over 2 years old. import timetravel I think you mean: from __future__ import timetravel -- HansM Well according to Marty it is: fr

Re: xml-rpc

2010-03-14 Thread Martin P. Hellwig
On 03/14/10 10:32, hackingKK wrote: Instead of using the library directly, isn't python-twisted a better choice? Why? -- mph -- http://mail.python.org/mailman/listinfo/python-list

  1   2   3   4   5   >