Re: Making wxPython a standard module?

2008-06-15 Thread Sebastian "lunar" Wiesner
"Martin v. Löwis" <[EMAIL PROTECTED]>: >> Just out of curiosity, what are the chances of this happening (sort of >> like what happened with sqlite)? > > As a starting point, the author(s) of wxPython would need to contribute > it to Python (and then also give the PSF the permission to relicense >

Re: bpython - fancy Python shell

2008-06-16 Thread Sebastian "lunar" Wiesner
Wolfgang Grafen <[EMAIL PROTECTED]>: > I couldn't get it work on Solaris (modified some lines for Python2.3). If solaris doesn't have a readline library, you might try to compile gnu readline, and recompile python (also a chance to get the current version 2.5) > One reason was that I had to down

Re: Context manager for files vs garbage collection

2008-06-17 Thread Sebastian "lunar" Wiesner
Floris Bruynooghe <[EMAIL PROTECTED]>: > I was wondering when it was worthwil to use context managers for > file. Consider this example: > > def foo(): > t = False > for line in file('/tmp/foo'): > if line.startswith('bar'): > t = True > break > return

Re: pyinotify issue

2008-06-20 Thread Sebastian "lunar" Wiesner
AndreH <[EMAIL PROTECTED]>: > On Jun 17, 12:11 pm, AndreH <[EMAIL PROTECTED]> wrote: >> On Jun 13, 3:39 pm, AndreH <[EMAIL PROTECTED]> wrote: >> >> >> >> > Good day, >> >> > I just installed pyinotify on my gentoo box. >> >> > When I test the library through "pyinotify.pv -v /tmp" under root, >> >

Re: Fast and easy GUI prototyping with Python

2008-06-21 Thread Sebastian "lunar" Wiesner
[EMAIL PROTECTED] <[EMAIL PROTECTED]>: > Which tools would you use? I want the interface design to be as easy > and fast as possible, all ideology aside. I'm considering either > IronPython+Visual Studio or Python+Qt -- but I'm open for other > suggestions. I'm using the latter, and am perfectly

Re: Fast and easy GUI prototyping with Python

2008-06-22 Thread Sebastian "lunar" Wiesner
Michael Torrie <[EMAIL PROTECTED]>: > [EMAIL PROTECTED] wrote: >> 2) The Qt vs. .NET API. I have no experience with Qt's API and a >> rudimentary experience with the .NET API (seems powerfull but also big >> and complex). > > Qt's API is very very good. Easy to use and extremely powerful. Note

Re: Fast and easy GUI prototyping with Python

2008-06-23 Thread Sebastian "lunar" Wiesner
Michael Torrie <[EMAIL PROTECTED]>: > Pete Kirkham wrote: >> 2008/6/21 Val-Amart <[EMAIL PROTECTED]>: >> >>> Use PyQt. You will gain great portability +all the functionality built >>> in qt. >>> You can try PyGTK also, though i wont recommend it. >>> >> Why would you not recommend it? I've been u

Re: Going from Tkinter to pyQT

2008-06-23 Thread Sebastian "lunar" Wiesner
Alex Bryan <[EMAIL PROTECTED]>: > I had a guy on this mailing list tell me that pyQT is much better than > Tkinter, and after looking into it a bit I think he is right. However, > I can't find much on it. I want to know if there are any good books or > online tutorials that would be helpful. I dou

Re: Threads, GIL and re.match() performance

2008-06-27 Thread Sebastian "lunar" Wiesner
Jeff <[EMAIL PROTECTED]>: > (and possibly intermediate results) These could be stored purely in C space, without refcounting needed. -- Freedom is always the freedom of dissenters. (Rosa Luxemburg) -- http://mail.python.org/mailman/listinfo/python-list

Re: How do web templates separate content and logic?

2008-06-27 Thread Sebastian "lunar" Wiesner
John Salerno <[EMAIL PROTECTED]>: > But when you have a templating system that mixes HTML and Python code, how > is this helping to keep things separate? You don't. Normally you embed only the code, that is absolutely necessary, e.g. for iterating over a list. Consider an online shop, that nee

Re: C++ or Python

2008-06-29 Thread Sebastian "lunar" Wiesner
Dan Stromberg <[EMAIL PROTECTED]>: > things like passing a method as a function parameter is a no-brainer > (requires extra syntax in java because of the cautious type system - not > sure about C++). C++ has function pointers and functors, therefore this is not really an issue with C++. -- Fre

Re: HTML Parsing

2008-06-29 Thread Sebastian "lunar" Wiesner
Stefan Behnel <[EMAIL PROTECTED]>: > [EMAIL PROTECTED] wrote: >> I am trying to build my own web crawler for an experiement and I don't >> know how to access HTTP protocol with python. >> >> Also, Are there any Opensource Parsing engine for HTML documents >> available in Python too? That would be

Re: raw_input into Tkinter ?

2008-06-30 Thread Sebastian "lunar" Wiesner
[EMAIL PROTECTED] <[EMAIL PROTECTED]>: > Is there any way to type into a Tkinter frame window? Maybe using a proper text/line edit widget? > I want to use raw_input() within a Tkinter frame. The builtin raw_input is for console input only. Of course, one could implement a raw_input using a Tki

Re: raw_input into Tkinter ?

2008-07-01 Thread Sebastian "lunar" Wiesner
Matimus <[EMAIL PROTECTED]>: > On Jun 30, 9:55 am, [EMAIL PROTECTED] wrote: >> Is there any way to type into a Tkinter frame window? >> I want to use raw_input() within a Tkinter frame. > > `raw_input(prompt)` just calls `sys.stdout.write(prompt)` and returns > `sys.stdin.readline()`. It does mor

Re: Scripting SAP GUI (Windows)

2008-07-02 Thread Sebastian "lunar" Wiesner
Thomas Guettler <[EMAIL PROTECTED]>: > Hi, > > I need to script SAP GUI running on MS-Windows: Doesn't that thing have a COM interface? -- Freedom is always the freedom of dissenters. (Rosa Luxemburg) -- http://mail.python.org/mailman/listinfo/python-list

Re: re.search much slower then grep on some regular expressions

2008-07-05 Thread Sebastian "lunar" Wiesner
Paddy <[EMAIL PROTECTED]>: > On Jul 4, 1:36 pm, Peter Otten <[EMAIL PROTECTED]> wrote: >> Henning_Thornblad wrote: >> > What can be the cause of the large difference between re.search and >> > grep? >> >> grep uses a smarter algorithm ;) >> >> >> >> > This script takes about 5 min to run on my com

Re: re.search much slower then grep on some regular expressions

2008-07-05 Thread Sebastian "lunar" Wiesner
Carl Banks <[EMAIL PROTECTED]>: > On Jul 5, 4:12 am, "Sebastian \"lunar\" Wiesner" > <[EMAIL PROTECTED]> wrote: >> Paddy <[EMAIL PROTECTED]>: >> >> >> >> > On Jul 4, 1:36 pm, Peter Otten <[EMAIL PROTECTED]&g

Re: re.search much slower then grep on some regular expressions

2008-07-05 Thread Sebastian "lunar" Wiesner
Terry Reedy <[EMAIL PROTECTED]>: > Mark Dickinson wrote: >> On Jul 5, 1:54 pm, Carl Banks <[EMAIL PROTECTED]> wrote: > >> Part of the problem is a lack of agreement on what >> 'regular expression' means. > > Twenty years ago, there was. Calling a extended re-derived grammar > expression like Pe

Re: Hands-on HTML Table Parser/Matrix?

2008-07-06 Thread Sebastian "lunar" Wiesner
robert <[EMAIL PROTECTED]>: > Often I want to extract some web table contents. Formats are > mostly static, simple text & numbers in it, other tags to be > stripped off. So a simple & fast approach would be ok. > > What of the different modules around is most easy to use, stable, > up-to-date, it

Re: re.search much slower then grep on some regular expressions

2008-07-06 Thread Sebastian "lunar" Wiesner
Mark Wooding <[EMAIL PROTECTED]>: > Sebastian "lunar" Wiesner <[EMAIL PROTECTED]> wrote: > >> I just wanted to illustrate, that the speed of the given search is >> somehow related to the complexity of the engine. >> >> Btw, other pcre i

Re: Problem with subprocess.Popen wget within a thread

2008-07-06 Thread Sebastian "lunar" Wiesner
Mathieu Prevot <[EMAIL PROTECTED]>: > it seems the script (A) finishes before the downloading ends, and the > (B) version doesn't (wanted behavior) ... this is unexpected. What > happens ? "readlines" blocks, until the pipe is closed, which usually happens, if the process dies. On the other ha

Re: re.search much slower then grep on some regular expressions

2008-07-07 Thread Sebastian "lunar" Wiesner
Mark Wooding <[EMAIL PROTECTED]>: > Sebastian "lunar" Wiesner <[EMAIL PROTECTED]> wrote: > >> # perl -e '("a" x 10) =~ /^(ab?)*$/;' >> zsh: segmentation fault perl -e '("a" x 10) =~ /^(ab?)*$/;' > > (

Re: GUI Programming by hand not code with Python Code

2008-07-07 Thread Sebastian "lunar" Wiesner
Jason Scheirer <[EMAIL PROTECTED]>: > On Jul 6, 7:33 pm, [EMAIL PROTECTED] wrote: >> Is their a program that lets you design a GUI by hand (like gambas) >> not by code (like wxpython) but the commands are in python? >> >> A program similar to gambas or vb >> >> Gambas with python code instead of g

Re: re.search much slower then grep on some regular expressions

2008-07-10 Thread Sebastian "lunar" Wiesner
Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]>: > On Mon, 07 Jul 2008 16:44:22 +0200, Sebastian \"lunar\" Wiesner wrote: > >> Mark Wooding <[EMAIL PROTECTED]>: >> >>> Sebastian "lunar" Wiesner <[EMAIL PROTECTED]> wrote:

Re: Emacs/Python Essentials?

2008-07-10 Thread Sebastian "lunar" Wiesner
xkenneth <[EMAIL PROTECTED]>: > What does everyone consider essential for emacs python dev? yasnippet is worth being looked at -- Freedom is always the freedom of dissenters. (Rosa Luxemburg) -- http://mail.python.org/mailman/listinfo/python-list

Re: plugins using cvs/distutils?

2008-07-10 Thread Sebastian "lunar" Wiesner
Deacon <[EMAIL PROTECTED]>: > Hi. I have an open-source application development environment that I > would like to enable an automated package download system for (like > downloadable plugins), using sourceforge as its repository. My > software will have a menu-based popup window, that will list t

Re: Converting from local -> UTC

2008-07-12 Thread Sebastian "lunar" Wiesner
Gabriel Genellina <[EMAIL PROTECTED]>: > En Fri, 11 Jul 2008 15:42:37 -0300, Keith Hughitt > <[EMAIL PROTECTED]> escribi�: > >> I am having a little trouble figuring out how to convert a python >> datetime to UTC. I have a UTC date (e.g. 2008-07-11 00:00:00). I would >> like to create a UTC date

Re: subprocess module

2008-07-14 Thread Sebastian "lunar" Wiesner
Peter Otten <[EMAIL PROTECTED]>: > - communicate() waits for the subprocess to terminate. > - stdout.read() is retried if an EINTR occurs (Not sure when this would > happen). EINTR happens, if the "read" syscall is interrupted by a signal handler. For instance, if a daemon handles SIGUSR to re-r

Re: About the slot declaration decorator in PyQt4

2008-07-14 Thread Sebastian "lunar" Wiesner
Bighead <[EMAIL PROTECTED]>: > I remember when I did UI Design in PyQt4 for the first time, I found a > manual. In it, no "connect" was used. Instead, an OO approach is > applied, new UI classes inherit from old ones, and all the slot > functions are automatically connected to some signals, using

Re: fork after creating temporary file using NamedTemporaryFile

2008-07-15 Thread Sebastian "lunar" Wiesner
[EMAIL PROTECTED] <[EMAIL PROTECTED]>: > When I create temporary file using the tempfile module, and forkI) > later on in my program, I always see errors when the program exits. Is > this because the child process deletes temp file? > Here's a stripped down version of my script that exhibits this

Re: Is it legal to rebuild Python.exe to include Version property tab?

2008-07-15 Thread Sebastian "lunar" Wiesner
[EMAIL PROTECTED] <[EMAIL PROTECTED]>: > My company distributes a COM object that can be license and userd by > our customers. Some of my company's internal application also use the > COM object. However, for internal applications, instead of licensing > the COM object, we just make the applicatio

Re: Is there any component-oriented (non-MVC) web framework available for Python?

2008-07-16 Thread Sebastian "lunar" Wiesner
Alis <[EMAIL PROTECTED]>: > Is there any component-oriented (non-MVC) web framework available for > Python? > > That is something like Apache Wicket, Tapestry or JSF, but I need it > to be in Python. Zope [1] might be worth trying. [1] http://www.zope.org -- Freedom is always the freedom of d

Re: Unexpected default arguments behaviour (Maybe bug?)

2008-07-18 Thread Sebastian "lunar" Wiesner
[EMAIL PROTECTED] <[EMAIL PROTECTED]>: > On 13 Lug, 19:42, [EMAIL PROTECTED] wrote: >> I expect it's because default values for parameters are evaluated and >> bound at definition time. So once "def m (self, param = a):" line >> executes, the default value for parameter is forever bound to be 1. >

Re: Problem with Python Server Pages (PSP)

2008-07-22 Thread Sebastian "lunar" Wiesner
[EMAIL PROTECTED] <[EMAIL PROTECTED]>: > Hi, > > I am facing a very basic problem with PSP. I have installed mod_python > (in fedora Core 1), added the lines required for loading Python > modules and handling PSP pages. I have created a hello.psp page. But > when I try to view this hello.psp page

Re: Proper way to query user and group database on a Unix host?

2008-07-23 Thread Sebastian "lunar" Wiesner
Chris Brannon <[EMAIL PROTECTED]>: Iirc since Python 2.5 these tuples are named ... > Instead, do this: > > import grp > groupname = 'users' > groupusers = grp.getgrnam(groupname)[3] ... thus this line could be written as: groupusers = grp.getgrnam(groupname).gr_mem Slightly more readable, imh

Re: Proper way to query user and group database on a Unix host?

2008-07-23 Thread Sebastian "lunar" Wiesner
Guilherme Polo <[EMAIL PROTECTED]>: > On Wed, Jul 23, 2008 at 9:16 AM, Sebastian lunar Wiesner > <[EMAIL PROTECTED]> wrote: >> Chris Brannon <[EMAIL PROTECTED]>: >> >> Iirc since Python 2.5 these tuples are named ... >> >>> In

Re: lxml, comparing nodes

2008-07-23 Thread Sebastian "lunar" Wiesner
code_berzerker <[EMAIL PROTECTED]>: > I'd like to know if there is any built in mechanism in lxml that lets > you check equality of two nodes from separate documents. I'd like it > to ignore attribute order and so on. It would be even better if there > was built in method for checking equality of

Re: Attack a sacred Python Cow

2008-07-24 Thread Sebastian "lunar" Wiesner
Jordan <[EMAIL PROTECTED]>: > # Blog code, not tested > class A(): > def __eq__(self, obj): > return True > a = A() > b = [] > assert a == b > assert not (a != b) > > The second assertion fails. Why? Because coding __eq__, the most > obvious way to make a class have equality based comparis

Re: Attack a sacred Python Cow

2008-07-24 Thread Sebastian "lunar" Wiesner
Jordan <[EMAIL PROTECTED]>: >> Fortunately, Python isn't designed according to your ideas, and won't >> change, so consider your posting a waste of time.  If feeling like >> bringing such old "issues" up again next time, spend your time learning >> another programming language, as you would obviou

Re: Attack a sacred Python Cow

2008-07-24 Thread Sebastian "lunar" Wiesner
Torsten Bronger <[EMAIL PROTECTED]>: > Hallöchen! > > Bruno Desthuilliers writes: > >> Torsten Bronger a écrit : >> >>> Bruno Desthuilliers writes: >>> [...] How would you handle this case with an implicit 'self' : class Foo(object): pass def bar(self):

Re: Python program as daemon?

2008-07-25 Thread Sebastian "lunar" Wiesner
Johny <[EMAIL PROTECTED]>: > Is it possible to run a Python program as daemon? You can write daemons in basically any language out there. -- Freedom is always the freedom of dissenters. (Rosa Luxemburg) -- http://mail.python.org/mailman/listinfo/python-list

Re: Anonymous email users

2024-06-23 Thread Sebastian Wells via Python-list
On Fri, 14 Jun 2024 18:00:37 -0400, avi.e.gross wrote: > I notice that in some recent discussions, we have users who cannot be > replied to directly as their email addresses are not valid ones, and I > believe on purpose. Examples in the thread I was going to reply to are: > >

How to find number of whole weeks between dates?

2015-06-10 Thread Sebastian M Cheung via Python-list
Say in 2014 April to May whole weeks would be 7th, 14th 28th April and May would be 5th, 12th and 19th. So expecting 7 whole weeks in total -- https://mail.python.org/mailman/listinfo/python-list

Re: How to find number of whole weeks between dates?

2015-06-10 Thread Sebastian M Cheung via Python-list
On Wednesday, June 10, 2015 at 6:06:09 PM UTC+1, Sebastian M Cheung wrote: > Say in 2014 April to May whole weeks would be 7th, 14th 28th April and May > would be 5th, 12th and 19th. So expecting 7 whole weeks in total What I mean is given two dates I want to find WHOLE weeks, so if giv

Re: How to find number of whole weeks between dates?

2015-06-10 Thread Sebastian M Cheung via Python-list
yes just whole weeks given any two months, I did looked into calendar module but couldn't find specifically what i need. -- https://mail.python.org/mailman/listinfo/python-list

How to pretty mathematical formulas in Python? Similar to Mathematica formats.

2015-06-11 Thread Sebastian M Cheung via Python-list
How to pretty mathematical formulas in Python? Similar to Mathematica formats. Are there good packages to prettify mathematica formulas in Python? -- https://mail.python.org/mailman/listinfo/python-list

Re: How to pretty mathematical formulas in Python? Similar to Mathematica formats.

2015-06-11 Thread Sebastian M Cheung via Python-list
On Thursday, June 11, 2015 at 7:33:12 PM UTC+1, Sebastian M Cheung wrote: > How to pretty mathematical formulas in Python? Similar to Mathematica formats. > > Are there good packages to prettify mathematica formulas in Python? Thanks Pythonistas -- https://mail.python.org/mailman

XCode and Python

2015-06-11 Thread Sebastian M Cheung via Python-list
For some reason I cannot build now in XCode: $ xcodebuild -find python /Users/sebc/anaconda/bin/python $python Python 2.7.10 |Anaconda 2.2.0 (x86_64)| (default, May 28 2015, 17:04:42) [GCC 4.2.1 (Apple Inc. build 5577)] on darwin Type "help", "copyright", "credits" or "license" for more informat

Re: XCode and Python

2015-06-11 Thread Sebastian M Cheung via Python-list
On Thursday, June 11, 2015 at 11:07:59 PM UTC+1, Sebastian M Cheung wrote: > For some reason I cannot build now in XCode: > > $ xcodebuild -find python > /Users/sebc/anaconda/bin/python > > $python > Python 2.7.10 |Anaconda 2.2.0 (x86_64)| (default, May 28 2015, 17:04:42)

Java to Python autoconverters

2015-06-12 Thread Sebastian M Cheung via Python-list
Are these available? Any good ones to recommend? -- https://mail.python.org/mailman/listinfo/python-list

python financial data cleaning

2015-06-15 Thread Sebastian M Cheung via Python-list
How to do financial data cleaning ? Say I assume a list of 1000 finance series data in myList = Open, High, Low and Close. For missing Close Price data, What is best practice to clean data in Python -- https://mail.python.org/mailman/listinfo/python-list

Re: python financial data cleaning

2015-06-15 Thread Sebastian M Cheung via Python-list
On Monday, June 15, 2015 at 11:13:07 AM UTC+1, Sebastian M Cheung wrote: > How to do financial data cleaning ? Say I assume a list of 1000 finance > series data in myList = Open, High, Low and Close. For missing Close Price > data, What is best practice to clean data in Python Thanks

Re: python financial data cleaning

2015-06-15 Thread Sebastian M Cheung via Python-list
On Monday, June 15, 2015 at 12:35:18 PM UTC+1, Laura Creighton wrote: > I don't know anything about this program, and in particular how > complete it is, but worth a look > https://github.com/benjaminmgross/clean-fin-data > > Laura Thanks Laura, I will check it out, but basically it is to clean f

Re: python financial data cleaning

2015-06-15 Thread Sebastian M Cheung via Python-list
On Monday, June 15, 2015 at 11:19:48 AM UTC+1, Mark Lawrence wrote: > On 15/06/2015 11:12, Sebastian M Cheung via Python-list wrote: > > How to do financial data cleaning ? Say I assume a list of 1000 finance > > series data in myList = Open, High, Low and Close. For missing Close

anaconda upgrade

2015-06-17 Thread Sebastian M Cheung via Python-list
What is the best way to upgrade an existing virtual environment anaconda from 2.7.9 to 2.7.10 -- https://mail.python.org/mailman/listinfo/python-list

<    1   2   3