Re: access to MS Access password-protected database?

2009-02-11 Thread Kenneth McDonald
Sorry for the vagueness. I do have access to the file and can open it using Access. I haven't yet done anything involving Python and Access (or Python and Win interfacing, for that matter.) Thanks, Ken On Feb 11, 2009, at 12:01 PM, imageguy wrote: On Feb 11, 10:43 am, Ken McDonald wrot

Any equivalent to Ruby's 'hpricot' html/xpath/css selector package?

2008-12-28 Thread Kenneth McDonald
Ruby has a package called 'hpricot' which can perform limited xpath queries, and CSS selector queries. However, what makes it really useful is that it does a good job of handling the "broken" html that is so commonly found on the web. Does Python have anything similar, i.e. something that w

Re: Why not Ruby?

2008-12-31 Thread Kenneth Tilton
Xah Lee wrote: > Just spent 3 hours looking into Ruby today. Here's my short impression > for those interested. > > * Why Not Ruby? > http://xahlee.org/UnixResource_dir/writ/why_not_Ruby.html > > plain text version follows: > -- > > Why Not Ruby? > > Xah Le

Re: Why not Ruby?

2009-01-01 Thread Kenneth Tilton
s...@netherlands.com wrote: On Wed, 31 Dec 2008 23:16:41 -0500, Kenneth Tilton wrote: Xah Lee wrote: Just spent 3 hours looking into Ruby today. Here's my short impression for those interested. * Why Not Ruby? http://xahlee.org/UnixResource_dir/writ/why_not_Ruby.html plain text ve

Re: Why not Ruby?

2009-01-01 Thread Kenneth Tilton
Richard Riley wrote: Jason Rumney writes: On Jan 1, 3:12 pm, r wrote: The man lives in a world driven by common sense "Common" sense suggests that his views are shared among the general populace. I don't see much evidence of that in the sometimes never- ending threads that frequently follo

Re: Ban Xah Lee

2009-03-09 Thread Kenneth Tilton
Roedy Green wrote: On Sat, 7 Mar 2009 14:52:02 -0800 (PST), Xah Lee wrote, quoted or indirectly quoted someone who said : I consider this post relevant because i've been perennially gossiped about in comp.lang.* groups today and in the past 5 or 10 years, many of the threads mentioning my name

Re: Ban Xah Lee

2009-03-09 Thread Kenneth Tilton
Dirk Bruere at NeoPax wrote: Larry Gates wrote: On Sun, 08 Mar 2009 04:09:52 +, Dirk Bruere at NeoPax wrote: Dirk Bruere at NeoPax wrote: Well, don't worry - nobody is going to ban you from Usenet (except possibly the Chinese govt). OTOH, nobody here much cares. So, rant on - it's what

Re: Ban Xah Lee

2009-03-10 Thread Kenneth Tilton
Craig Allen wrote: There you go: a 30-second psychological diagnosis by an electrical engineer based entirely on Usenet postings. It doesn't get much more worthless than that... -- Grant rolf but interesting post nonetheless. I have been really somewhat fascinated by AS since I heard of it a

Python script to automate use of Google Translate? (or other translator)

2008-04-20 Thread Kenneth McDonald
I have the need to occasionally translate a single word programatically. Would anyone have a Python script that would let me do this using Google (or another) translation service? Thanks, Ken -- http://mail.python.org/mailman/listinfo/python-list

Where to get BeautifulSoup--www.crummy.com appears to be down.

2008-04-22 Thread Kenneth McDonald
Sadly. Thanks, Ken -- http://mail.python.org/mailman/listinfo/python-list

People still using Tkinter?

2008-05-09 Thread Kenneth McDonald
Any guesses as to how many people are still using Tkinter? And can anyone direct me to good, current docs for Tkinter? Thanks, Ken -- http://mail.python.org/mailman/listinfo/python-list

Re: People still using Tkinter?

2008-05-10 Thread Kenneth McDonald
The only trick it that sometimes it isn't obvious how to make the Tcl/ Tk call via Python. Ken On May 10, 2008, at 11:27 AM, Martin v. Löwis wrote: I am, but "still" isn't the word, I just started. Good, *complete* docs seem to be hard to find, but using a combination of the free resources a

Any other UI kits with text widget similar to that in Tk?

2008-05-10 Thread Kenneth McDonald
I'm wondering if any of the other GUI kits have a text widget that is similar in power to the one in Tk. wxWindows, from what I can tell, doesn't offer nearly the options the Tk widget does. I'm less familiar with Qt. Any feedback would be most appreciated. Thanks, Ken -- http://mail.pytho

subprocess.Popen hangs at times?

2008-09-10 Thread Kenneth McDonald
When making calls of the form Popen(cmd, shell=True, stdout=subprocess.PIPE), we've been getting occasional, predictable hangs. Will Popen accumulate a certain amount of stdout and then block until its read? We don't want to use threads, so just want to read the entire stdout after the subp

wxpython error message?

2006-03-23 Thread Kenneth Xie
I made some mistake in my codes, so there was a window with a text field appeared. But before I could read the message in the text field, the window disappeared. So I can't figure out what's the problem with my codes. What should I do to make the message window last a little longer? Thank you. --

Re: Haskell's new logo, and the idiocy of tech geekers

2009-10-02 Thread Kenneth Tilton
Xah Lee wrote: Haskell has a new logo. A fantastic one. Beautiful. For creator, context, detail, see bottom of: • A Lambda Logo Tour http://xahlee.org/UnixResource_dir/lambda_logo.html Cool survey, and yes, that is a nice new one for Haskell. I saw beauty the other day changing an applicati

Re: Haskell's new logo, and the idiocy of tech geekers

2009-10-02 Thread Kenneth Tilton
Pascal J. Bourguignon wrote: Kenneth Tilton writes: Xah Lee wrote: Haskell has a new logo. A fantastic one. Beautiful. For creator, context, detail, see bottom of: • A Lambda Logo Tour http://xahlee.org/UnixResource_dir/lambda_logo.html Don't do that! If you want to watch the

Re: Which is the best implementation of LISP family of languages for real world programming ?

2010-06-10 Thread Kenneth Tilton
bolega wrote: Which is the best implementation of LISP family of languages for real world programming ? http://wiki.alu.org/Implementation Kindly pick one from commercial and one from open-source . ACL and SBCL The criteria is : libraries, gui interface and builder, libraries for TCP, and

Re: death of newsgroups (Microsoft closing their newsgroups)

2010-07-13 Thread Kenneth Tilton
Xah Lee wrote: • Death of Newsgroups http://xahlee.org/UnixResource_dir/writ2/death_of_newsgroups.html plain text version follows. -- Death of Newsgroups Xah Lee, 2010-07-13 Microsoft is closing down their newsgroups. See: microsoft.public.win

Re: death of newsgroups (Microsoft closing their newsgroups)

2010-07-14 Thread Kenneth Tilton
Steven D'Aprano wrote: On Tue, 13 Jul 2010 23:24:12 -0400, Kenneth Tilton wrote: The moral? If you look for the spam, you'll find it. And if you *don't* look for spam, you can be sure that some goose will reply to it and get it past your filters. Thanks for that Kenneth, i

Re: Fascinating interview by Richard Stallman at KTH on emacs history and internals

2010-07-18 Thread Kenneth Tilton
Lawrence D'Oliveiro wrote: In message , Nick Keighley wrote: On 16 July, 09:24, Mark Tarver wrote: On 15 July, 23:21, bolega wrote: http://www.gnu.org/philosophy/stallman-kth.html RMS lecture at KTH (Sweden), 30 October 1986 did you really have to post all of this... read more »...

Re: math symbols in unicode (grouped by purpose)

2010-08-15 Thread Kenneth Tilton
On 8/13/2010 5:18 PM, Xah Lee wrote: some collection of math symbols in unicode. • Math Symbols in Unicode http://xahlee.org/comp/unicode_math_operators.html I am surprised you do not include the numeric character codes. kt • Arrows in Unicode http://xahlee.org/comp/unicode_arrows.ht

Re: The Complexity And Tedium of Software Engineering

2009-06-05 Thread Kenneth Tilton
Xah Lee wrote: On Jun 3, 11:50 pm, Xah Lee wrote: Of interest: • The Complexity And Tedium of Software Engineering http://xahlee.org/UnixResource_dir/writ/programer_frustration.html Addendum: The point in these short examples is not about software bugs or problems. It illustrates, how seemi

Re: The Complexity And Tedium of Software Engineering

2009-06-07 Thread Kenneth Tilton
verec wrote: On 2009-06-05 21:03:33 +0100, Kenneth Tilton said: When progress stops we will have time to polish our systems, not before. Is that an endorsement of mediocrity? No, of General Patton. hth, kt -- http://mail.python.org/mailman/listinfo/python-list

Re: OT: unix to Windows technology

2009-07-08 Thread Kenneth Tilton
Xah Lee wrote: Dear unixers & lispers, i've been using Mac for the past 19 years, and been a professional sys admin or web app developers on the unix platform, since 1998 (maily Solaris, Apache, Perl, Java, SQL, PHP). In june, i bought a PC (not for the first time though), and made a switch to W

cPickle segfault with nested dicts in threaded env

2010-09-08 Thread Kenneth Dombrowski
hreading.Thread(target=threadloop) > t.start() > Any thoughts will be appreciated, thanks for looking, Kenneth -- http://mail.python.org/mailman/listinfo/python-list

Re: cPickle segfault with nested dicts in threaded env

2010-09-09 Thread Kenneth Dombrowski
t; reasons that no exploit is possible.  So the bug should be reported > against 2.5 as well as later versions. Hi Paul, Thanks for the input, it sounds reasonable to me. I reported it & the maintainers can decide what to do with it: http://bugs.python.org/issue9812 Thanks again everyone

Obtain Ceritificate Information from Invalid or Self-Signed Certificate in Python

2017-04-03 Thread Kenneth Buckler
I'm working on a Python 2.7.13 (Win x64) script to verify SSL certificates, and alert for problems. Specifically, I'm looking to return the date the cert expires or did expire. However, I'm running into an issue where the script will return information only if the certificate is valid. If the cert

Re: Functional style programming in python: what will you talk about if you have an hour on this topic?

2011-07-13 Thread J Kenneth King
Anthony Kong writes: > (My post did not appear in the mailing list, so this is my second try. > Apology if it ends up posted twice) > > Hi, all, > > If you have read my previous posts to the group, you probably have some idea > why I asked this question. > > I am giving a few presentations on p

Re: Refactor/Rewrite Perl code in Python

2011-07-25 Thread J Kenneth King
Steven D'Aprano writes: > On Sun, Jul 24, 2011 at 7:29 PM, Shashwat Anand > wrote: > >> How do I start ? >> The idea is to rewrite module by module. >> But how to make sure code doesn't break ? > > By testing it. > > Read up on "test driven development". > > At this point, you have this: > > Per

3.5.2

2016-10-25 Thread Kenneth L Stege
Im running windows 7 pro, 64 bit. I downloaded 3.5.2 64 bit and when I try to run I get the error message  api-ms-win-crt-runtime-l1-1-0.dll is missing. I loaded that file and still will not run.   suggestions? thanks -- https://mail.python.org/mailman/listinfo/python-list

Pros/Cons of Turbogears/Rails?

2006-08-27 Thread kenneth . m . mcdonald
First, I don't intend this to be a flame war, please. Python and Ruby are the only two languages I'd willingly work in (at least amongst common languages), and TurboGears and Rails seem roughly equivalent. I'm much more knowledgable about Python, but that's a minor issue--I've been intending to le

Status of PyXPCOM?

2006-09-13 Thread kenneth . m . mcdonald
I'm waiting for PyXPCOM with bated breath, but always have a hard time figuring out what is actually happening with it--the ActiveState mailing list is mostly inactive, and web searches Always turn up very old, out of date pages. If it weren't for the fact that I know Mark Hammond is working,very,

Python to JavaScript Compiler? Anyone written such a beast?

2006-09-13 Thread kenneth . m . mcdonald
Of course, I'm not talking about something that would transform any Python code into semantically JavaScript code, but simply something that would analyze a "restricted" Python source file, and spit out equivalent JavaScript. The big advantage (as far as I'm concerned) is that one could make use of

Iterating by both element and index?...

2006-09-25 Thread kenneth . m . mcdonald
I'd like to iterate over a sequence by both element and index, something like for (element, index) in somefun(sequence): ... Obviously this is easy enough to code, but I seem to remember that such a function was added to standard Python at some point, but I just can't dig up a reference to it

Python/UNO/OpenOffice?

2006-09-29 Thread kenneth . m . mcdonald
Are then any currently active and reasonably mature Python plugins/ apis/whatever for programming/scripting OpenOffice? The page I've found is http://udk.openoffice.org/python/python-bridge.html, but it was last updated more than a year ago. Thanks, Ken -- http://mail.python.org/mailman/listinfo/

Python Oracle Interace on Solaris

2006-02-17 Thread kenneth . s . chan
I am trying to use Python to do queries on a Oracle database using a Solaris box. I have seen tools such as cx_Oracle which would be good except that my Solaris box does not have an Oracle installation. Do I need to have an Oracle installation on my Solaris box to access the Oracle database (which

Re: Two questions about style and some simple math

2009-01-20 Thread J Kenneth King
Spoofy writes: > .. .. > > 2. > > For maintaining the character attributes I creates a seperate class. I > wonder weather this is an "overuse" of OO (instead of just making the > attributes plain variables of the Char class) and if the way I wrote > this is OK (somehow this looks cool to me but

Re: Pyro deadlock

2009-01-20 Thread J Kenneth King
MatthewS writes: > I'd like to know if the following behavior is expected and can be > avoided: I have a Pyro server object that maintains a queue of work, > and multiple Pyro worker objects that take work off the queue by > calling a method on the server (get_work) and then return the work to >

Re: I'm a python addict !

2009-01-26 Thread J Kenneth King
Linuxguy123 writes: > I just started using python last week and I'm addicted. > > I hate Perl. I never did learn to use it with any competence. I has to > be the most obfuscated, cryptic language I've ever seen. Making it > "object oriented" only makes it worse ! > .. .. I program full-time

Re: I'm a python addict !

2009-01-26 Thread J Kenneth King
J Kenneth King writes: > Linuxguy123 writes: > >> I just started using python last week and I'm addicted. >> >> I hate Perl. I never did learn to use it with any competence. I has to >> be the most obfuscated, cryptic language I've ever seen. Maki

Re: Recommendation for a small web framework like Perl's CGI::Application to run as CGI?

2009-01-29 Thread J Kenneth King
excord80 writes: > I need to make a small, relatively low-traffic site that users can > create accounts on and log into. Scripts must run as cgi (no > mod_python or FastCGI is available). Can anyone recommend a small and > simple web framework for Python, maybe similar to Perl's > CGI::Applicatio

Re: What is wrong in my list comprehension?

2009-02-02 Thread J Kenneth King
Chris Rebert writes: > Python 2.6 (r26:66714, Nov 18 2008, 21:48:52) > [GCC 4.0.1 (Apple Inc. build 5484)] on darwin > Type "help", "copyright", "credits" or "license" for more information. bool(-1) > True > > str.find() returns -1 on failure (i.e. if the substring is not in the > given stri

Re: What is wrong in my list comprehension?

2009-02-02 Thread J Kenneth King
Chris Rebert writes: > Python 2.6 (r26:66714, Nov 18 2008, 21:48:52) > [GCC 4.0.1 (Apple Inc. build 5484)] on darwin > Type "help", "copyright", "credits" or "license" for more information. bool(-1) > True > > str.find() returns -1 on failure (i.e. if the substring is not in the > given stri

Re: What is wrong in my list comprehension?

2009-02-02 Thread J Kenneth King
Stephen Hansen writes: >>> str.find() returns -1 on failure (i.e. if the substring is not in the >>> given string). >>> -1 is considered boolean true by Python. >> >> That's an odd little quirk... never noticed that before. >> >> I just use regular expressions myself. >> >> Wouldn't this be somet

Re: What is wrong in my list comprehension?

2009-02-02 Thread J Kenneth King
Chris Rebert writes: > Python 2.6 (r26:66714, Nov 18 2008, 21:48:52) > [GCC 4.0.1 (Apple Inc. build 5484)] on darwin > Type "help", "copyright", "credits" or "license" for more information. bool(-1) > True > > str.find() returns -1 on failure (i.e. if the substring is not in the > given stri

Re: What is wrong in my list comprehension?

2009-02-02 Thread J Kenneth King
Chris Rebert writes: > Python 2.6 (r26:66714, Nov 18 2008, 21:48:52) > [GCC 4.0.1 (Apple Inc. build 5484)] on darwin > Type "help", "copyright", "credits" or "license" for more information. bool(-1) > True > > str.find() returns -1 on failure (i.e. if the substring is not in the > given stri

Re: Added-value of frameworks?

2009-02-04 Thread J Kenneth King
Matimus writes: > On Feb 4, 8:08 am, Gilles Ganault wrote: >> Hello >> >> If I wanted to build some social web site such as Facebook, what do >> frameworks like Django or TurboGears provide over writing a site from >> scratch using Python? >> >> Thank you for your feedback. > > Why not just look

Re: [Web 2.0] Added-value of frameworks?

2009-02-05 Thread J Kenneth King
Bruno Desthuilliers writes: > Gilles Ganault a écrit : >> Hello >> >> If I wanted to build some social web site such as Facebook, what do >> frameworks like Django or TurboGears provide over writing a site from >> scratch using Python? > > Quite a lot of abstractions and factorisation of the boil

Re: Flattening lists

2009-02-05 Thread J Kenneth King
mk writes: > Hello everybody, > > Any better solution than this? > > def flatten(x): > res = [] > for el in x: > if isinstance(el,list): > res.extend(flatten(el)) > else: > res.append(el) > return res > > a = [1, 2, 3, [4, 5, 6], [[7, 8], [9, 10

[ANN] TracShell 0.1 released

2009-02-12 Thread J Kenneth King
I tend to work a lot with Trac for project management and have always found the browser interface to be a productivity killer. I always wanted a simple command-line interface to Trac, but having never found one I found a little free time and got off my laurels to make one. TracShell 0.1 is an ear

Re: TracShell 0.1 released

2009-02-12 Thread J Kenneth King
Krzysztof Retel writes: > On 12 Feb, 14:06, J Kenneth King wrote: >> I tend to work a lot with Trac for project management and have always >> found the browser interface to be a productivity killer. I always >> wanted a simple command-line interface to Trac, but having

Re: is there a project running (GUI Builder for Python ) ?

2009-02-12 Thread J Kenneth King
azrael writes: > To be honest, in compare to Visual Studio, Gui Builders for wx > widgets are really bad. That's because Visual Studio is a Microsoft product to build interfaces for Microsoft products. wx on the other hand is cross platform and ergo, much more complicated. > Do you know if the

Re: [ANN] TracShell 0.1 released

2009-02-13 Thread J Kenneth King
J Kenneth King writes: > I tend to work a lot with Trac for project management and have always > found the browser interface to be a productivity killer. I always > wanted a simple command-line interface to Trac, but having never found > one I found a little free time and got off m

Re: is there a project running (GUI Builder for Python ) ?

2009-02-13 Thread J Kenneth King
gc_ott...@yahoo.ca writes: > ..I come from Delphi, and compared to Delphi, even Visual Studio >> vanishes ;-) > ...I don't even notice the difference between Delphi (which > I'm still using) >> and wxPython. >> >> I think this story happened to other people to, >> so instead of putting

Musings: Using decorators to reduce duplicate exception handling

2009-02-17 Thread J Kenneth King
I recently started a project called TracShell (http://code.google.com/p/tracshell) where I make heavy use of the xmlrpclib core module. When the number of RPC calls was small, wrapping each call in try/except was acceptable. However, this obviously will duplicate code all over the place. There ar

Re: Musings: Using decorators to reduce duplicate exception handling

2009-02-18 Thread J Kenneth King
"Gabriel Genellina" writes: > En Tue, 17 Feb 2009 21:12:57 -0200, J Kenneth King > escribió: > >> I recently started a project called TracShell >> (http://code.google.com/p/tracshell) where I make heavy use of the >> xmlrpclib core module. >> >>

Re: Musings: Using decorators to reduce duplicate exception handling

2009-02-19 Thread J Kenneth King
Cameron Simpson writes: > On 17Feb2009 15:12, J Kenneth King wrote: > | I recently started a project called TracShell > | (http://code.google.com/p/tracshell) where I make heavy use of the > | xmlrpclib core module. > | > | When the number of RPC calls was small, wrappin

Re: Python equivalent of Common Lisp Macros?

2008-11-26 Thread J Kenneth King
dpapathanasiou <[EMAIL PROTECTED]> writes: > I'm using the feedparser library to extract data from rss feed items. > > After I wrote this function, which returns a list of item titles, I > noticed that most item attributes would be retrieved the same way, > i.e., the function would look exactly th

Re: RELEASED Python 3.0 final

2008-12-04 Thread J Kenneth King
Barry Warsaw <[EMAIL PROTECTED]> writes: > On behalf of the Python development team and the Python community, I > am happy to announce the release of Python 3.0 final. Yay! Thanks for all the great work. -- http://mail.python.org/mailman/listinfo/python-list

Re: Python 3.0 automatic decoding of UTF16

2008-12-05 Thread J Kenneth King
Johannes Bauer <[EMAIL PROTECTED]> writes: > Traceback (most recent call last): > File "./modify.py", line 12, in > a = AddressBook("2008_11_05_Handy_Backup.txt") > File "./modify.py", line 7, in __init__ > line = f.readline() > File "/usr/local/lib/python3.0/io.py", line 1807, in r

Re: pydb 1.24

2008-12-11 Thread J Kenneth King
[EMAIL PROTECTED] (R. Bernstein) writes: > This release is to clear out some old issues. It contains some > bugfixes, document corrections, and enhancements. Tests were > revised for Python 2.6 and Python without readline installed. A bug > involving invoking from ipython was fixed. The "frame" co

Re: Are Django/Turbogears too specific?

2008-12-21 Thread J Kenneth King
Gilles Ganault writes: > Hi > > I'd like to rewrite a Web 2.0 PHP application in Python with AJAX, and > it seems like Django and Turbogears are the frameworks that have the > most momentum. > > I'd like to use this opportunity to lower the load on servers, as the > PHP application wasn't built t

Re: If your were going to program a game...

2009-01-02 Thread J Kenneth King
Tokyo Dan writes: > If your were going to program a game in python what technologies would > you use? > > The game is a board game with some piece animations, but no movement > animation...think of a chess king exploding. The game runs in a > browser in a window of a social site built around the

Re: Is there a better algorithm?

2009-01-02 Thread J Kenneth King
Kottiyath writes: > I have the following list of tuples: > L = [(1, 2), (3, 4, 5), (6, 7)] > > I want to loop through the list and extract the values. > The only algorithm I could think of is: for i in l: > ... u = None > ... try: > ... (k, v) = i > ... except ValueError: > ... (k, u,

Re: Is there a better algorithm?

2009-01-02 Thread J Kenneth King
Paul Rubin writes: > Kottiyath writes: >> I have the following list of tuples: >> L = [(1, 2), (3, 4, 5), (6, 7)] >> I want to loop through the list and extract the values. > > Others have suggested messy ways to code what you're asking. At another > level, that li

Re: Noob question: Is all this typecasting normal?

2009-01-06 Thread J Kenneth King
"Gabriel Genellina" writes: > En Mon, 05 Jan 2009 02:03:26 -0200, Roy Smith escribió: > > >> The other day, I came upon this gem. It's a bit of perl embedded in a >> Makefile; this makes it even more gnarly because all the $'s get >> doubled to >> hide them from make: >> >> define absmondir >>

Re: image recogniton?

2009-01-06 Thread J Kenneth King
Li Han writes: > Hi! I know little about the computer image processing, and now I have > a fancy problem which is how to read the time from the picture of a > clock by programming ? Is there anyone who can give me some > suggestions? > Thank! > Li Han I do work in object recognition, and I

Re: looking for tips on how to implement "ruby-style" Domain Specific Language in Python

2009-01-06 Thread J Kenneth King
Jonathan Gardner writes: > On Jan 6, 8:18 am, sturlamolden wrote: >> On Jan 6, 4:32 pm, mark wrote: >> >> > I want to implement a internal DSL in Python. I would like the syntax >> > as human readable as possible. >> >> Also beware that Python is not Lisp. You cannot define new syntax (yes >> I

Re: looking for tips on how to implement "ruby-style" Domain Specific Language in Python

2009-01-07 Thread J Kenneth King
Jonathan Gardner writes: > On Jan 6, 12:24 pm, J Kenneth King wrote: >> Jonathan Gardner writes: >> > On Jan 6, 8:18 am, sturlamolden wrote: >> >> On Jan 6, 4:32 pm, mark wrote: >> >> >> > I want to implement a internal DSL in Python. I

Re: looking for tips on how to implement "ruby-style" Domain Specific Language in Python

2009-01-07 Thread J Kenneth King
Kay Schluehr writes: > On 7 Jan., 16:50, J Kenneth King wrote: > >> Python expressions are not >> data types either and hence no macros -- I can't write a python function >> that generates python code at compile time. > > Have you ever considered there a

Re: looking for tips on how to implement "ruby-style" Domain Specific Language in Python

2009-01-08 Thread J Kenneth King
Jonathan Gardner writes: > On Jan 7, 9:16 am, "Chris Mellon" wrote: >> >> The OP wants a Ruby-style DSL by which he means "something that lets >> me write words instead of expressions". The ruby syntax is amenable to >> this, python (and lisp, for that matter) syntax is not and you can't >> impl

Re: looking for tips on how to implement "ruby-style" Domain Specific Language in Python

2009-01-08 Thread J Kenneth King
Kay Schluehr writes: > On 8 Jan., 16:25, J Kenneth King wrote: > >> As another poster mentioned, eventually PyPy will be done and then >> you'll get more of an "in-Python" DSL. > > May I ask why you consider it as important that the interpreter is &

Re: PIL problem

2008-10-08 Thread J Kenneth King
bfrederi <[EMAIL PROTECTED]> writes: > I am having a problem using PIL. I am trying to crop and image to a > square, starting from the center of the image, but when I try to crop > the image, it won't crop. Here are the relevant code snippets: > > ### Function I am testing ### > def create_square_

Re: PYTHON WORKING WITH PERL ??

2008-10-16 Thread J Kenneth King
Pat <[EMAIL PROTECTED]> writes: > Sean DiZazzo wrote: >> On Sep 29, 12:44 pm, "Blubaugh, David A." <[EMAIL PROTECTED]> >> wrote: >>> Sir, >>> >>> You are absolutely correct. I was praying to G_d I did not have to >>> slaughter my project's source code in this manner. However, like life >>> itsel

Re: PYTHON WORKING WITH PERL ??

2008-10-16 Thread J Kenneth King
Joshua Kugler <[EMAIL PROTECTED]> writes: > Pat wrote: >>> Rewrite everything in python. Save yourself now...while you still >>> can. >>> >>> ~Sean >> >> Trust me. Sean is absolutely correct. I'm currently in the process of >> converting a large Perl project to Python (and learning Python at th

python extensions: including project local headers

2008-10-23 Thread J Kenneth King
#x27;]) setup(name = 'pysift', version = '0.0', description = 'A SIFT feature detection package', author = 'James Kenneth King', author_email = "[EMAIL PROTECTED]", url = "http://agentultra.com/";, long_des

Re: python extensions: including project local headers

2008-10-23 Thread J Kenneth King
Robert Kern <[EMAIL PROTECTED]> writes: > Philip Semanchuk wrote: >> >> On Oct 23, 2008, at 11:36 AM, J Kenneth King wrote: >> >>> >>> Hey everyone, >>> >>> I'm working on a python extension wrapper around Rob Hess' >

Re: python extensions: including project local headers

2008-10-23 Thread J Kenneth King
Philip Semanchuk <[EMAIL PROTECTED]> writes: > On Oct 23, 2008, at 11:36 AM, J Kenneth King wrote: > >> >> Hey everyone, >> >> I'm working on a python extension wrapper around Rob Hess' >> implementation of a SIFT feature detector. I'm wo

Re: python extensions: including project local headers

2008-10-24 Thread J Kenneth King
Philip Semanchuk <[EMAIL PROTECTED]> writes: > On Oct 23, 2008, at 3:18 PM, J Kenneth King wrote: > >> Philip Semanchuk <[EMAIL PROTECTED]> writes: >> >>> On Oct 23, 2008, at 11:36 AM, J Kenneth King wrote: >>> >>>> >>>> Hey

Re: Python suitable for Midi ?

2008-10-29 Thread J Kenneth King
Derek Martin <[EMAIL PROTECTED]> writes: > On Tue, Oct 28, 2008 at 06:54:57PM +0200, Chuckk Hubbard wrote: >> The problem I've run into is that I can't set the audio to a higher >> priority than the GUI (Tkinter). If I move the mouse over the app, no >> matter what, I get audio dropouts. AFAICT

Re: Daemon and logging - the best approach?

2008-11-07 Thread J Kenneth King
Lech Karol Pawłaszek <[EMAIL PROTECTED]> writes: > Hello. > > I'm trying to make a daemon and I want to log to a file its activity. > I'm using logging module with a configuration file for it (loaded via > fileConfig()). > > And now I want to read logging config file before daemonize the program >

Re: best python unit testing framwork

2008-11-11 Thread J Kenneth King
Brendan Miller <[EMAIL PROTECTED]> writes: > What would heavy python unit testers say is the best framework? > > I've seen a few mentions that maybe the built in unittest framework > isn't that great. I've heard a couple of good things about py.test and > nose. Are there other options? Is there an

Re: duck-type-checking?

2008-11-12 Thread J Kenneth King
Joe Strout <[EMAIL PROTECTED]> writes: > Let me preface this by saying that I think I "get" the concept of > duck- > typing. > > However, I still want to sprinkle my code with assertions that, for > example, my parameters are what they're supposed to be -- too often I > mistakenly pass in somethi

Re: Multiprocessing vs. [Pyro, RPyC]

2008-11-15 Thread J Kenneth King
Jeffrey Barish <[EMAIL PROTECTED]> writes: > [EMAIL PROTECTED] wrote: > >> >> Jeffrey> With the release of multiprocessing in Python 2.6, is there >> any Jeffrey> reason to use Pyro or RPyC? >> >> As far as I know the multiprocessing module only works on one machine >> (multi-cpu or mult

function parameter scope python 2.5.2

2008-11-20 Thread J Kenneth King
I recently encountered some interesting behaviour that looks like a bug to me, but I can't find the appropriate reference to any specifications to clarify whether it is a bug. Here's the example code to demonstrate the issue: class SomeObject(object): def __init__(self): self.words

Re: function parameter scope python 2.5.2

2008-11-20 Thread J Kenneth King
J Kenneth King <[EMAIL PROTECTED]> writes: > I recently encountered some interesting behaviour that looks like a bug > to me, but I can't find the appropriate reference to any specifications > to clarify whether it is a bug. > > Here's the example code to d

Re: function parameter scope python 2.5.2

2008-11-21 Thread J Kenneth King
alex23 <[EMAIL PROTECTED]> writes: > On Nov 21, 9:40 am, J Kenneth King <[EMAIL PROTECTED]> wrote: >> Of course, providing a shallow (or deep as necessary) copy makes it >> work, I'm curious as to why the value passed as a parameter to a >> function outside

Re: function parameter scope python 2.5.2

2008-11-21 Thread J Kenneth King
Steven D'Aprano <[EMAIL PROTECTED]> writes: > On Thu, 20 Nov 2008 18:31:12 -0500, J Kenneth King wrote: > >> Of course I expected that recursive_func() would receive a copy of >> weird_obj.words but it appears to happily modify the object. > > I am curious

Re: function parameter scope python 2.5.2

2008-11-21 Thread J Kenneth King
Peter Pearson <[EMAIL PROTECTED]> writes: > On Fri, 21 Nov 2008 10:12:08 -0500, J Kenneth King wrote: >> Steven D'Aprano <[EMAIL PROTECTED]> writes: >>> >>> I am curious why you thought that. What made you think Python should/did >>> make a c

ANN: tracshell 0.1r23

2009-03-04 Thread J Kenneth King
ho've already helped a lot by submitting patches. Bug reports, feature requests, comments and critiques are encouraged! All the best, J Kenneth King -- http://mail.python.org/mailman/listinfo/python-list

Re: While loop

2009-03-05 Thread J Kenneth King
Fab86 writes: > On Mar 5, 5:23 pm, Marco Mariani wrote: >> Fab86 wrote: >> > Is it possible to get the program to catch the exception, wait 10 >> > seconds, then carry of from where it was rather than starting again? >> >> something like this? probably works in PASCAL as well :) >> >> > i=0 >> >

Re: Roundup Issue Tracker release 1.4.7

2009-03-17 Thread J Kenneth King
Richard Jones writes: > I'm proud to release version 1.4.7 of Roundup. > - Allow CGI frontend to serve XMLRPC requests. > - Added XMLRPC actions, as well as bridging CGI actions to XMLRPC actions. Sweet. I'm working on a small project called TracShell which is a command-line front-end to the T

mocking xmlrpclib

2009-03-23 Thread J Kenneth King
At the risk of sounding like I don't know what I'm doing, I must say that I am finding it rather difficult/tedious to mock the xmlrpclib interface using minimock. I refuse to believe that I'm the only developer to have tried this before, but google isn't being my friend and I can't seem to get it

Re: HTML Generation

2009-04-03 Thread J Kenneth King
Tino Wildenhain writes: > Hi Mike, > > > Mike wrote: >> Hello all, >> >> I'm writing a web app and wanted to do some html generation (I >> really do not like to maintain or write html). >> >> I'm thinking of writing a dsl based on the following: >> >> def html(): >> return >> >> def a(): >>

Re: HTML Generation

2009-04-03 Thread J Kenneth King
Stefan Behnel writes: > J Kenneth King wrote: >> from tags import html, head, meta, title, body, div, p, a >> >> mypage = html( >> head( >> meta(attrs={'http-equiv': "Content-Type",

Re: decorators don't play nice with nose?

2009-04-06 Thread J Kenneth King
hyperboreean writes: > From: hyperboreean > Subject: decorators don't play nice with nose? > Newsgroups: comp.lang.python > To: python-list@python.org > Date: Mon, 06 Apr 2009 11:01:04 +0300 > > Hi, I am trying to test the business part of a web service. For this I > am using unittest & nose. >

unpythonic use of property()?

2009-04-17 Thread J Kenneth King
Consider: code: class MyInterface(object): def __get_id(self): return self.__id id = property(fget=__get_id) def __init__(self, id, foo): self.__id = id self.foo = foo class MyInterf

Re: unpythonic use of property()?

2009-04-20 Thread J Kenneth King
Carl Banks writes: > On Apr 17, 4:00 pm, Scott David Daniels wrote: >> Carl Banks wrote: >> > On Apr 17, 10:21 am, J Kenneth King wrote: >> >> Consider: >> >> >> code: >> >> --

Re: unpythonic use of property()?

2009-04-22 Thread J Kenneth King
Luis Zarrabeitia writes: > On Monday 20 April 2009 11:29:19 am J Kenneth King wrote: >> Changing the ID value would break things on the server, so I >> wanted to write the interface class to respect those conventions. > > Then, take this opportunity fix the server and pre

<    1   2   3   4   >