Saturday, January 28, 2012

Re: problems running subprocess inside django view

You are not alone with this problem. But I haven't got any decision.
Maybe its django-specific with Popen??

I divided my task in two part: first cron-driven disk file generation.
Second - from django-view this file parsing.
It satisfied my goals, but question with Popen is still opened...


On 27 янв, 20:05, Mark Lancaster <geordib...@googlemail.com> wrote:
> I'm having problems running subprocess inside a django view using:
>
> result = subprocess.Popen([<A SCRIPT> , <SOME PARAMS>],
> stdout=subprocess.PIPE).communicate()[0]
>
> exactly the same method works perfectly inside a regular python
> script.
>
> Should I be using a different method to initiate a script?
>
> Thanks

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

No comments:

Post a Comment