Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #47495
| Newsgroups | comp.lang.python |
|---|---|
| Date | 2013-06-09 13:51 -0700 |
| References | <cd1be83a-f560-4024-90b3-697a51bb1bb0@g7g2000vbv.googlegroups.com> <mailman.2932.1370808058.3114.python-list@python.org> <2cb97d50-87b1-4173-a4d9-0cb4342bfd5f@g2g2000vbk.googlegroups.com> <mailman.2935.1370809789.3114.python-list@python.org> |
| Message-ID | <a31dbfb2-5563-4db2-a2ea-da8116bd1db2@bz1g2000vbb.googlegroups.com> (permalink) |
| Subject | Re: problem with if then |
| From | Jean Dubois <jeandubois314@gmail.com> |
On 9 jun, 22:29, Fábio Santos <fabiosantos...@gmail.com> wrote: > On 9 Jun 2013 21:24, "Jean Dubois" > ...> And here is the result: > > > jean@antec4:~$ ./try.py > > wget -q -O - > > http://www.deredactie.be/cm/vrtnieuws/videozone/programmas/journaal/E...> >/dev/null ; echo $? > > 8 > > 2013-06-07 22:07:00.016807 stream is available > > wget -q -O - > > http://www.deredactie.be/cm/vrtnieuws/videozone/programmas/journaal/E...> >/dev/null ; echo $? > > 8 > > 2013-06-08 22:07:00.016795 stream is available > > wget -q -O - > > http://www.deredactie.be/cm/vrtnieuws/videozone/programmas/journaal/E... > > > >/dev/null ; echo $? > > 0 > > 2013-06-09 22:07:00.016763 stream is available > > You don't need to echo the return code. os.system should return that as an > int. > > The problem might be that os.system is returning the result from the echo > command instead. I removed the 'echo $?' and now the thing runs like expected, thanks a lot jean
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[newbie] problem with if then Jean Dubois <jeandubois314@gmail.com> - 2013-06-09 12:44 -0700
Re: [newbie] problem with if then Fábio Santos <fabiosantosart@gmail.com> - 2013-06-09 21:00 +0100
Re: problem with if then Jean Dubois <jeandubois314@gmail.com> - 2013-06-09 13:15 -0700
Re: problem with if then Fábio Santos <fabiosantosart@gmail.com> - 2013-06-09 21:29 +0100
Re: problem with if then Jean Dubois <jeandubois314@gmail.com> - 2013-06-09 13:51 -0700
Re: [newbie] problem with if then Roy Smith <roy@panix.com> - 2013-06-09 16:23 -0400
Re: problem with if then Jean Dubois <jeandubois314@gmail.com> - 2013-06-09 14:00 -0700
Re: problem with if then Roy Smith <roy@panix.com> - 2013-06-09 17:35 -0400
Re: problem with if then Jean Dubois <jeandubois314@gmail.com> - 2013-06-10 00:46 -0700
Re: [newbie] problem with if then Albert Dengg <albert@fsfe.org> - 2013-06-09 22:37 +0200
csiph-web