Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #87723
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!goblin3!goblin2!goblin.stu.neva.ru!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <cloverobert@gmail.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.007 |
| X-Spam-Evidence | '*H*': 0.99; '*S*': 0.00; 'subject:Python': 0.06; 'subject:file': 0.07; 'wednesday,': 0.07; 'subject:script': 0.09; 'cc:addr:python-list': 0.11; '>>': 0.16; '(when': 0.16; '>on': 0.16; 'cet': 0.16; 'proc': 0.16; 'thursday,': 0.16; 'wrote:': 0.18; 'wed,': 0.18; 'command': 0.22; '>>>': 0.22; 'email addr:gmail.com>': 0.22; 'cc:addr:python.org': 0.22; '>>>': 0.24; 'cc:2**0': 0.24; '>': 0.26; 'header:In- Reply-To:1': 0.27; 'robert': 0.30; 'message-id:@mail.gmail.com': 0.30; 'url:mailman': 0.30; 'file': 0.32; 'run': 0.32; 'url:python': 0.33; 'skip:s 30': 0.35; 'received:google.com': 0.35; 'url:listinfo': 0.36; 'method': 0.36; 'thanks': 0.36; 'url:org': 0.36; 'skip:- 20': 0.37; 'skip:& 10': 0.38; 'pm,': 0.38; 'skip:. 10': 0.39; 'skip:p 20': 0.39; 'url:mail': 0.40; 'how': 0.40; 'march': 0.61; 'name': 0.63; 'to:addr:gmail.com': 0.65; 'mar': 0.68; '2015': 0.84 |
| DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=IPKC5Iw+Zjs8apUPCgvc/EShX9PXEOmD5D8feAD7598=; b=j0merLPmv/plwiw7g+1qZoBTAzIwD0Wxca182Hu4m7gmHySpHQG7JQB6RdyV+R8HcH rLdr1tBh3/B9Ic4bkMqil7QgiCAmS5m77pBIzHcOfsQlcGydTe/45lmh1tcfS6nSZsrP FJUBZCjAGzSLRkcW8TcbmDlZQz6ugJ2+HV8CwzjYyr8LIrN0ovE4QHYCN+FDlIHAMVzU PMmqvb7PsX5+ie1F6K7VPOTekWlcX3Cfo/ap3RTi4Ulu++lNt1eNpMZXyFyNOxOcaOTL v3096xeMfPaEH0mX7Jv4RTpGWElSDk5wNKP/tzZJKswBfMrfWrcw4IYL2gl8Uxswkmvv s7PQ== |
| MIME-Version | 1.0 |
| X-Received | by 10.202.210.215 with SMTP id j206mr27978712oig.131.1426737405666; Wed, 18 Mar 2015 20:56:45 -0700 (PDT) |
| In-Reply-To | <6250eebf-2730-4eb4-a4a5-f6f1881ab3a2@googlegroups.com> |
| References | <mailman.7.1426710494.10327.python-list@python.org> <6250eebf-2730-4eb4-a4a5-f6f1881ab3a2@googlegroups.com> |
| Date | Wed, 18 Mar 2015 20:56:45 -0700 |
| Subject | Re: Python script output in file |
| From | Robert Clove <cloverobert@gmail.com> |
| To | Rustom Mody <rustompmody@gmail.com> |
| Cc | "python-list@python.org" <python-list@python.org> |
| Content-Type | multipart/alternative; boundary=001a113d299440adea05119c30af |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.19 |
| Precedence | list |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe> |
| List-Archive | <http://mail.python.org/pipermail/python-list/> |
| List-Post | <mailto:python-list@python.org> |
| List-Help | <mailto:python-list-request@python.org?subject=help> |
| List-Subscribe | <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.16.1426737741.10327.python-list@python.org> (permalink) |
| Lines | 70 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1426737741 news.xs4all.nl 2867 [2001:888:2000:d::a6]:39214 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:87723 |
Show key headers only | View raw
[Multipart message — attachments visible in raw view] - view raw
On Wed, Mar 18, 2015 at 7:10 PM, Rustom Mody <rustompmody@gmail.com> wrote:
> On Thursday, March 19, 2015 at 1:58:29 AM UTC+5:30, Albert-Jan Roskam
> wrote:
> > ----------------------------
> > On Wed, Mar 18, 2015 7:06 PM CET Rustom Mody wrote:
> >
> > >On Wednesday, March 18, 2015 at 8:12:12 PM UTC+5:30, Robert Clove wrote:
> > >> ./my_eth_script.pl eth0 M > a.txt
> > >>
> > >> How can i run this command with subprocess.popen
> > >
> > >Something like this I guess?
> > >
> > >>> proc = Popen("cat", shell=True, stdout=open(inname, "w"),
> stdin=open(outname,"r"))
> >
> >
> > How will the file object associated with in name be closed? (When is
> close() method called?
>
> Just like the close-paren in the line above <wink>
> --
> https://mail.python.org/mailman/listinfo/python-list
Thanks all :)
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: Python script output in file Albert-Jan Roskam <fomcl@yahoo.com> - 2015-03-18 13:22 -0700
Re: Python script output in file Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-03-19 10:16 +1100
Re: Python script output in file Rustom Mody <rustompmody@gmail.com> - 2015-03-18 19:10 -0700
Re: Python script output in file Robert Clove <cloverobert@gmail.com> - 2015-03-18 20:56 -0700
csiph-web