Re: [Tutor] curious struct problem

2007-02-02 Thread Bob Gailer
Marcus Goldfish wrote: > I'm trying to read a binary file using struct. This code works > interactively in the IPython shell, but not as a function invoked from > a command line (Windows). > Can someone point out my error? Thanks! Not without more information: What are you entering on the

Re: [Tutor] curious struct problem

2007-02-02 Thread Alan Gauld
"Marcus Goldfish" <[EMAIL PROTECTED]> wrote > interactively in the IPython shell, but not as a function invoked > from a > command line (Windows). Can someone point out my error? Thanks! One problem I dsee is that the function does not return anything. It stores it in a local variable x which

Re: [Tutor] curious struct problem

2007-02-02 Thread Danny Yoo
On Fri, 2 Feb 2007, Marcus Goldfish wrote: > I'm trying to read a binary file using struct. This code works > interactively in the IPython shell, but not as a function invoked from a > command line (Windows). Can someone point out my error? Thanks! Hi Marcus, There is something very suspici

Re: [Tutor] Get variable values [Introduction to Planet RSS news aggregator] (fwd)

2007-02-02 Thread Mário Gamito
Hi, Danny Yoo wrote: > > Have you tried asking for help from the planet devel list? Yes, but the list is comfortably numb :( > From what I understand, Planet does it own on-disk caching already: it > really does look like you're trying to implement something that Planet > already does intern

[Tutor] curious struct problem

2007-02-02 Thread Marcus Goldfish
I'm trying to read a binary file using struct. This code works interactively in the IPython shell, but not as a function invoked from a command line (Windows). Can someone point out my error? Thanks! import struct def demux(filename, channel, nchannels): "Demultiplexes a stream of shorts (s

Re: [Tutor] Get variable values [Introduction to Planet RSS news aggregator] (fwd)

2007-02-02 Thread Danny Yoo
On Fri, 2 Feb 2007, Mário Gamito wrote: 1) This way i can only retrieve information from one blog. The one in the line c = planet.Channel(p, "http://blog.gamito.org/rss.php?blogId=1&profile=rss20";) How can i retrieve from them all ? Hi Mario, Have you tried asking for help from the plan

Re: [Tutor] Get variable values [Introduction to Planet RSS news aggregator] (fwd)

2007-02-02 Thread Mário Gamito
Hi, Now, i got into something: http://pastebin.com/873482 I'm already inserting data in MySQL. Just two glitches: 1) This way i can only retrieve information from one blog. The one in the line c = planet.Channel(p, "http://blog.gamito.org/rss.php?blogId=1&profile=rss20";) How can i retrieve

Re: [Tutor] Problems with date

2007-02-02 Thread Kent Johnson
Mário Gamito wrote: > Hi, > > I have this instruction > > print item.date that outputs > > (2007, 1, 23, 18, 35, 33, 1, 23, 0) > > What i'd like to do is to convert it to, for example > > 23-01-2007 18:35:33 That is a struct_time tuple such as would be returned by time.localtime() for exampl

Re: [Tutor] Problems with date

2007-02-02 Thread Mário Gamito
Hi, Don't bother, i already got there :) Warm Regards, Mário Gamito Mário Gamito wrote: > Hi, > > I have this instruction > > print item.date that outputs > > (2007, 1, 23, 18, 35, 33, 1, 23, 0) > > What i'd like to do is to convert it to, for example > > 23-01-2007 18:35:33 > > I've googl

[Tutor] Problems with date

2007-02-02 Thread Mário Gamito
Hi, I have this instruction print item.date that outputs (2007, 1, 23, 18, 35, 33, 1, 23, 0) What i'd like to do is to convert it to, for example 23-01-2007 18:35:33 I've googled for an answer, but couldn't get there. Something is escaping me. Any help would be appreciated. Warm Regards, Má