Sqlalchemy access to Firefox's places.sqlite

2010-11-17 Thread Kent Tenney
Howdy, Lazy, wanting to access Firefox's places.sqlite via Sqlalchemy. How about this: Sqlite Manager -> places.sqlite -> Export Wizard -> table name sqlite_manager this produces file sqlite_manager.sql which looks like: BEGIN TRANSACTION; INSERT INTO "sqlite_master" VALUES('table','moz_bookmar

question

2010-05-26 Thread Kent Tenney
In a docutils svn checkout. [docutils/trunk/docutils]$ python setup.py install --root /tmp OK [docutils/trunk/docutils]$ python setup.py install_data --root /tmp distutils.errors.DistutilsFileError: could not delete '/usr/local/lib/python2.6/dist-packages/docutils/parsers/rst/include/README.txt'

Re: Trying to run a sudo command from script

2010-01-03 Thread Kent Tenney
On Fri, Jan 1, 2010 at 5:08 PM, Diez B. Roggisch wrote: > Kent Tenney schrieb: >> >> Howdy, >> >> A script running as a regular user sometimes wants >> to run sudo commands. >> >> It gets the password with getpass. >> pw = getpass.getpass()

Trying to run a sudo command from script

2010-01-01 Thread Kent Tenney
Howdy, A script running as a regular user sometimes wants to run sudo commands. It gets the password with getpass. pw = getpass.getpass() I've fiddled a bunch with stuff like proc = subprocess.Popen('sudo touch /etc/foo'.split(), stdin=subprocess.PIPE) proc.communicate(input=pw) getting assorte

Problem building Python from source

2009-09-30 Thread Kent Tenney
Trying to do a vanilla cmmi: ~/Python-2.6.3rc1$ ./configure ~/Python-2.6.3rc1$ make ... Traceback (most recent call last): ... ImportError: No module named cStringIO make: *** [sharedmods] Error 1 The fix is to uncomment the line in Modules/Setup #cStringIO cStringIO.c Question: Is there an arg

Re: Suggestion for improved ImportError message

2008-08-13 Thread Kent Tenney
> > Then go for it You can prepare a patch and ask on python-dev > > if the developers are interested. hehe, I'll get a C level patch accepted right after I out-swim Mike Phelps. > > > > I was never hacking the import things on C level before, > > but a hint: you have to modify import_from func

Re: datetime from uuid1 timestamp

2008-08-13 Thread Kent Tenney
> I'm interested in the use case for this. > Why would you want to extract the exact timestamp from the uuid? Because I can :-] At this point it's primarily academic, but I'll be creating lots of files and naming them with uuid's. I like the capability of determining creation date solely from t

Suggestion for improved ImportError message

2008-08-13 Thread Kent Tenney
Howdy, I was just bit by from image import annotate ImportError: cannot import name annotate I found the problem via import image print image.__file__ which made it clear that the wrong image module had been found. It would be nice if ImportError announced this up front. cannot import name

Re: datetime from uuid1 timestamp

2008-08-13 Thread Kent Tenney
> Howdy, > > I have not found a routine to extract usable > date/time information from the 60 bit uuid1 timestamp. > > Is there not a standard solution? I submitted an ASPN recipe to do it. http://code.activestate.com/recipes/576420/ -- http://mail.python.org/mailman/listinfo/python-list

datetime from uuid1 timestamp

2008-08-13 Thread Kent Tenney
Howdy, I have not found a routine to extract usable date/time information from the 60 bit uuid1 timestamp. Is there not a standard solution? Thanks, Kent -- http://mail.python.org/mailman/listinfo/python-list

Re: sending to an xterm

2008-08-08 Thread Kent Tenney
Derek Martin pizzashack.org> writes: > > On Fri, Aug 08, 2008 at 08:25:19PM +0000, Kent Tenney wrote: > > Howdy, > > > > I want to open an xterm, send it a command and have it execute it. > > You can't do that. xterm doesn't execute shell com

Re: sending to an xterm

2008-08-08 Thread Kent Tenney
Derek Martin pizzashack.org> writes: > > On Fri, Aug 08, 2008 at 08:25:19PM +0000, Kent Tenney wrote: > > Howdy, > > > > I want to open an xterm, send it a command and have it execute it. > > You can't do that. xterm doesn't execute shell com

sending to an xterm

2008-08-08 Thread Kent Tenney
Howdy, I want to open an xterm, send it a command and have it execute it. I thought pexpect would do this, but I've been unsuccessful. term = pexpect.spawn('xterm') starts an xterm, but term.sendline('ls') doesn't seem to do anything. Suggestions? Thanks, Kent -- http://mail.python.org/ma

Re: Problems with ElementTree and ProcessingInstruction

2007-01-28 Thread Kent Tenney
On Jan 28, 7:46 pm, Gabriel Genellina <[EMAIL PROTECTED]> wrote: > At Sunday 28/1/2007 11:28, Kent Tenney wrote: > > >I want to generate the following file; > > > > > > >stuff > > >How should I be doing this?open("filename","w"

Problems with ElementTree and ProcessingInstruction

2007-01-28 Thread Kent Tenney
Howdy, I want to generate the following file; stuff How should I be doing this? As far as I can tell, ElementTree() requires everything to be inside the root element (leo_file) Thanks, Kent -- http://mail.python.org/mailman/listinfo/python-list

Status of Epydoc

2006-08-09 Thread Kent Tenney
Howdy, I would very like to use Epydoc 3.0, however I've found a couple bugs and the mailing list; http://sourceforge.net/mailarchive/forum.php?forum_id=39919 doesn't seem to be working, the last couple messages I've posted haven't shown up. Does anyone know the status of Epydoc 3.0 development?

CDDB.py binaries for Python 2.4

2005-12-04 Thread Kent Tenney
Howdy, I'm using Python 2.4 on W2K I would love to use the tools at http://cddb-py.sourceforge.net/ the newest Win binaries are for Python 2.0 The dll won't load, I assume this is due to version mismatch. I'm not set up with a C compiler. Does anyone know of a source of current binaries for thi