Re: Problem with libxml2/libxlst

2010-06-10 Thread CinnamonDonkey
My mistake! *doh* I had an 'disable-output-escape="YES"' when it should have been "NO". -Shaun On 10 June, 10:17, CinnamonDonkey wrote: > Hi All, > > I could not find a dedicated libxml2/libxlst group so I thought I > would see if anyone here could he

Problem with libxml2/libxlst

2010-06-10 Thread CinnamonDonkey
Hi All, I could not find a dedicated libxml2/libxlst group so I thought I would see if anyone here could help. I have a system which captures the stdout from various sources and writes it into a generic xml file. This file then needs to be transformed to get the correct html format for rendering

Re: (Windows) Finding out which process has locked a file.

2009-05-15 Thread CinnamonDonkey
. I should actually read the links I post before posting them! (I actually posted them so that I could later read them at work). Yes, this thread is specifically about who has the *lock* on a file. Thanx TJG for the reality check ;-) Shaun On 15 May, 08:50, Tim Golden wrote: > CinnamonD

Re: (Windows) Finding out which process has locked a file.

2009-05-15 Thread CinnamonDonkey
/win32_how_do_i/get-the-owner-of-a-file.html On 15 May, 03:47, "Gabriel Genellina" wrote: > En Thu, 14 May 2009 08:42:07 -0300, Lawrence D'Oliveiro escribió: > > > In message <787d6072-3381-40bd- > > af20-8e1a40405...@h23g2000vbc.googlegroups.com>, CinnamonDonkey wrot

(Winows) Finding out which process has locked a file.

2009-05-13 Thread CinnamonDonkey
Hi all, Does anyone know how I can programatically find out which process (resolved to human friendly string, i.e. executable) has a lock on a file. I have a script running which occassionally fails because it is trying to delete a file in use by another process. When this happens I want it to lo

Re: Deleteing empty directories

2009-03-31 Thread CinnamonDonkey
Mar 2009 08:14:55 -0700, CinnamonDonkey wrote: > > My understanding was that rmtree removes a whole tree not just the empty > > directories? > > So it seems: > > >>> os.mkdir('die-die-die') > >>> os.mkdir('die-die-die/stuff') > >>

Re: Deleteing empty directories

2009-03-30 Thread CinnamonDonkey
shutil.rmtree(path) if __name__ == '__main__': RecurseTree( r"c:\temp" ) On 30 Mar, 16:14, CinnamonDonkey wrote: > My understanding was that rmtree removes a whole tree not just the > empty directories? > > eg. > > root >  - file1 >  - file2

Re: Deleteing empty directories

2009-03-30 Thread CinnamonDonkey
== '__main__': RecurseTree( r"c:\temp" ) But I'm not sure what the max recursion depth is in python? Plus I think this could be more efficient. On 30 Mar, 15:59, Tim Golden wrote: > CinnamonDonkey wrote: > > Hi All, > > > I've been scratc

Deleteing empty directories

2009-03-30 Thread CinnamonDonkey
Hi All, I've been scratching my head all afternoon trying to work out the best/ quickest way is to delete empty directories within a tree (Windows). I've looked at os.walk() but it seems to traverse the directory tree in the wrong order (is it possible to reverse the order?) It seems the only wa

Re: Caught out by daylight saving :-(

2009-03-30 Thread CinnamonDonkey
it was known to you at the > original change? > > And to make it more complex, suppose the disk drive involved was located > in France.  Just what time is correct? > > Anything other than UTC is subject to confusion. > > CinnamonDonkey wrote: > > Hi All, > > >

Re: Caught out by daylight saving :-(

2009-03-30 Thread CinnamonDonkey
Ah, I think I needed to use fromtimestamp() and not utcfromtimestamp (). :-) On 30 Mar, 13:42, CinnamonDonkey wrote: > Hi Chris, > > Thanx for the link... I had already found that. My problem is not > finding information but more understanding it. I've only been > Pythoni

Re: Caught out by daylight saving :-(

2009-03-30 Thread CinnamonDonkey
new class inheriting from tzinfo and refine the behaviour of the dst() function? If so, then what do I do with the class? On 30 Mar, 13:08, Chris wrote: > On Mar 30, 1:47 pm, CinnamonDonkey > wrote: > > > > > Hi All, > > > I had the following bit of code which was work

Caught out by daylight saving :-(

2009-03-30 Thread CinnamonDonkey
Hi All, I had the following bit of code which was working fine until we went into Daylight saving this weekend, now the result is an hour out. timeString = "20090330 15:45:23" timeFormat = '%Y-%m-%d %H:%M:%S' modificationTime = datetime.datetime.utcfromtimestamp( time.mktime ( time.

Re: Relative Imports, why the hell is it so hard?

2009-03-24 Thread CinnamonDonkey
lusion too quickly and for that I appologise. Cheers, Shaun On 24 Mar, 12:37, bearophileh...@lycos.com wrote: > CinnamonDonkey: > > > It is neither constructive nor educational. > > > It's a bit like saying "If you don't know what a function is, then > &

Re: Relative Imports, why the hell is it so hard?

2009-03-24 Thread CinnamonDonkey
lution. By the way, my project has about 50 files (modules) in it with a lot of shared code that could be used across other projects... seems as good a reason as any to try packages out ;-) Thanx anyway :) On 23 Mar, 18:57, bearophileh...@lycos.com wrote: > CinnamonDonkey: > > >wh

Re: Relative Imports, why the hell is it so hard?

2009-03-23 Thread CinnamonDonkey
My applogies if this is a silly question... but what makes something a package? and does that mean that what I am trying to do is not possible ? :( On 23 Mar, 15:53, "Gabriel Genellina" wrote: > En Mon, 23 Mar 2009 12:22:21 -0300, CinnamonDonkey   > escribió: > &g

Re: Relative Imports, why the hell is it so hard?

2009-03-23 Thread CinnamonDonkey
Hi Guys, Thanx for the quick responses, it is very much appreciated! Skip, that's a good point about "C++ != Python" and I assure you I am very much aware of that ;-). Looking at http://www.python.org/dev/peps/pep-0328/#guido-s-decision would suggest, unless I am completely miss-understanding th

Relative Imports, why the hell is it so hard?

2009-03-23 Thread CinnamonDonkey
Hi All, I'm fairly new to Python so I still have a lot to learn. But I'd like to know how to correectly use relative imports. Please, please... please! don't go off on rants about why you think relative imports should not be used. I've got 15+ years in C++ and relative inclusion of other sections

Microsoft Message Queues

2009-02-27 Thread CinnamonDonkey
Hi All, I am looking to use win32com to set-up a Microsoft Message Queue (MSMQ) between two or more computers connected on a LAN. I have found this posting: http://groups.google.co.uk/group/comp.lang.python/browse_thread/thread/80b42375ae84e3d7/989b864575997a9e?hl=en&lnk=gst&q=msmq#989b864575997