On Tue, Mar 11, 2014 at 8:07 PM, Shawn Milochik <shawn.m...@gmail.com>wrote:
> > I tried to circumvent the entire problem by adding an "if __name__ == > '__main__'" block to the script and having it take a command-line argument > via argparse and print the desired output. Then I did a > subprocess.check_output call on *that* instead of importing the module. > This worked from "manage.py shell," but not within a view in Django -- the > same OS error 12. > > TL;DR; It's working now, but I don't know why. Thanks for looking, nothing to see here. I'm bored, tell me all about it: I just tried this again with runserver and gunicorn, and this workaround was working in both cases. Then I tried again importing the module directly and it continued to work. It's looking like there was some other problem and perhaps the "Django connection" was a red herring. I really don't think there's less load on this machine now compared to earlier in the day. This is really puzzling, because was able to replicate the problem *consistently* and *repeatedly* earlier in the day. Thanks to Russ, Drew, and Nick for taking the time to listen to my woes and try to help. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAOzwKwGGCcG1-dvUG_OXkgjeXYBXom9_ktEKfT9T3A06Cj%3DuNw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.