[ckan-dev] Virtualenv tips: how to reload the ini file

Mike Sinclair mm.sinclair08 at gmail.com
Fri Jun 13 02:50:06 UTC 2014


Hi John,

Python is not going to be running by default, it has to be invoked, so I'm
wondering what happened prior to step 1 above such that python is already
running. Is it that you're trying to run paster twice, using separate
terminals? Why?

It looks like you are serving paster on one terminal and then trying to
serve again on another, leading to the conflict.

As for joining and leaving the virutalenv - the commands are:

$ . /usr/lib/ckan/default/bin/activate
$ deactivate

Cheers,

Mike Sinclair
OpenGovGear
www.opengovgear.com


On Wed, Jun 11, 2014 at 10:01 PM, John Brisbin <john at boab.info> wrote:

> G'Day all,
>
> Thanks to some kindly orientation help from Jason Tan, I have managed to
> get python to reload the development.ini file and proceed onward on the
> path to creating a custom theme....but not without some lingering confusion.
>
> This is a request for advice on how to manage the virtualenv sessions
> properly.
>
> Starting from a fresh PuTTY login, I run $ netstat -lntp and can see that
> there's an existing Python process on a given PID (let's say 4506)
>
> (1) If I open another shell, activate a virtualenv (.
> /usr/lib/ckan/default/bin/activate), and try to run the paster command:
>
> paster serve --reload /etc/ckan/default/development.ini
>
> we will get the message that the server is starting in some other socket
> (eg 5304), and then will get the socket Errno 98 Address already in use.
>
> (2) If I kill the python process manually, and then re-run the paster
> command, the server appears to reload the ini file and start itself
> normally.
>
> It doesn't seem right that I have to manually kill Python before being
> able to run the --reload, but, given that Python should always be running,
> and I don't know how to join (or leave) an existing virtualenv session, I'm
> not sure what else to do.
>
> Thanks for any pointers!
>
> Kind regards,
>
> JB
>
>
>
> --
> John Brisbin
> Managing Director, BoaB interactive Pty Ltd
> POB 248, MT Molloy QLD 4871
>
> E: john at boab.info
> M: 0407 471 565 | P: 07 4094 2172
> Skype: boabjohn | Twitter: @boabjohn
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> https://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20140612/42edf5e9/attachment-0003.html>


More information about the ckan-dev mailing list