paster

CKAN Install: paster error

不问归期 提交于 2019-12-03 09:19:44
Installing CKAN locally on OSX 10.9, based on http://docs.ckan.org/en/latest/maintaining/installing/install-from-source.html . I've created and activated the python virtualenv and now need to create a CKAN config file: $ paster make-config ckan /etc/ckan/default/development.ini The output is as follows (ImportError at the last line): Distribution already installed: ckan 2.2 from ~/ckan/lib/default/src/ckan Traceback (most recent call last): File "/usr/lib/ckan/default/bin/paster", line 9, in <module> load_entry_point('PasteScript==1.7.5', 'console_scripts', 'paster')() File "/usr/lib/ckan

How to debug long running python scripts or services remotely?

半世苍凉 提交于 2019-12-03 07:53:26
Pretty much what the title says, I would like to be able to connect to a python process running under paster or uwsgi and utilize pdb functionality. Using winpdb , you can attach to a running process like this: Insert import rpdb2; rpdb2.start_embedded_debugger('mypassword') inside your script. Launch your script (through paster or uwsgi) as usual. Run winpdb Click File>Attach Type in password (e.g. "mypassword"), select the process. To detach, click File>Detach. The script will continue to run, and can be attached to again later. 来源: https://stackoverflow.com/questions/7082093/how-to-debug

Paste (Python) Web Server - Autoreload Problem

扶醉桌前 提交于 2019-12-01 08:57:19
When I start the `Paste' web server in daemon mode, it seems to kill off it's ability to reload when the timestamp of a source file is updated. Here is how I start the daemon... cd ${project} && ../bin/paster serve --reload --daemon development.ini; cd ..; ...which defeats one of the main points of using Paste (for me). Has anyone come across this or know what I'm doing wrong? To be complete, the file that I'm changing is a controller file. The version is `PasteScript 1.7.3' I believe that the two options are essentially incompatible, since the reloader stops the server with a SIGTERM and the

Can I have multiple ini config files in Pyramid?

社会主义新天地 提交于 2019-11-30 14:10:28
问题 I'd like an equivalent of the Django One True Way settings layout: a shared base file, and then a production file and a development file, each of which import the shared base. Is this possible with Pyramid's config? 回答1: Yes that's possible. In one of my projects I have a production_base.ini file and all other production inis inherit from it: production_base.ini [app:main] use = egg:xxx maintenance_mode = False production_www.ini [app:main] use = config:production_base.ini maintenance_mode =

Why is my log level not being used when using loadapp from paste.deploy?

左心房为你撑大大i 提交于 2019-11-29 08:49:19
I want to temporailiy turn on debug messages in a production pyramid web project so I adjusted the production.ini file, pushed it to Heroku and saw only error and warn level messages. So I thought, that seems odd since if I start the pyramid application like the following on my local PC I get all the log level messages. env/bin/pserve production.ini OK, so that's not exactly how it runs on Heroku, it is actually run from a little bit of python that looks like this (in a file called runapp.py ): import os from paste.deploy import loadapp from waitress import serve if __name__ == "__main__":