Re: [Repoze-dev] authorization debug problem
Wichert Akkerman wrote: I use a custom authorization problem, but noticed that when I enable BFG_DEBUG_AUTHORIZATION it always reports no authorization policy in use. I am guessing this happens because the authorization policy is registered after the routes are setup, so the queryUtility calls in authdebug_view happen too early. If I move them inside the _authdebug_view method things work properly. I'm not sure what the right fix is: reordering the configuration, or moving those queryUtility calls. A better fix is to actually move to the 1.2 series and pass the authorization policy to the Configurator at startup time: http://docs.repoze.org/bfg/1.2/api/configuration.html - C ___ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev
Re: [Repoze-dev] repoze.what.plugins.quickstart
Hello, Darryl. Thank you very much for the patches! I will have a look into it by this weekend, although I may have some time tomorrow night. Talk to you soon! - Gustavo. Darryl said: And here as is likely *should* be done, also 'logging-config.ini' for tests/fixtures as referenced in added tests. Sorry for the noise. Best, Darryl On Wed, Dec 2, 2009 at 2:55 PM, Darryl Cousins darryljcous...@gmail.com wrote: And also for docs/Config.rst Best regards, Darryl Cousins -- Gustavo Narea xri://=Gustavo. | Tech blog: =Gustavo/(+blog)/tech ~ About me: =Gustavo/about | ___ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev
[Repoze-dev] repoze.bfg 1.1.4 and 1.2a3 released
Two new releases of repoze.bfg are out. Install 1.1.4 via: easy_install -i http://dist.repoze.org/bfg/1.1/simple repoze.bfg Install 1.2a3 via: easy_install -i http://dist.repoze.org/bfg/1.2/simple repoze.bfg Or either is available via PyPI. These are bugfix releases. No release notice for for 1.1.3 went out, so I include it here. 1.1.4 (2009-12-02) == - When two views were registered with differering ``for`` interfaces or classes, and the ``for`` of first view registered was a superclass of the second, the ``repoze.bfg` view machinery would incorrectly associate the two views with the same multiview. Multiviews are meant to be collections of views that have *exactly* the same for/request/viewname values, without taking inheritance into account. Symptom: wrong view callable found even when you had correctly specified a ``for_`` interface/class during view configuration for one or both view configurations (backport from trunk). 1.1.3 (2009-12-02) == Bug Fixes - - The ``repoze.bfg.url.route_url`` function inappropriately passed along ``_query`` and/or ``_anchor`` arguments to the ``mapper.generate`` function, resulting in blowups (backport from trunk). 1.2a3 (2009-01-02) == Bug Fixes - - The ``repoze.bfg.url.route_url`` function inappropriately passed along ``_query`` and/or ``_anchor`` arguments to the ``mapper.generate`` function, resulting in blowups. - When two views were registered with differering ``for`` interfaces or classes, and the ``for`` of first view registered was a superclass of the second, the ``repoze.bfg` view machinery would incorrectly associate the two views with the same multiview. Multiviews are meant to be collections of views that have *exactly* the same for/request/viewname values, without taking inheritance into account. Symptom: wrong view callable found even when you had correctly specified a ``for_`` interface/class during view configuration for one or both view configurations. Backwards Incompatibilities --- - The ``repoze.bfg.templating`` module has been removed; it had been deprecated in 1.1 and never actually had any APIs in it. ___ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev
[Repoze-dev] Running repoze.bfg on Google’s A pp Engine
Hi All, I found that the recipe [1] to run repoze.bfg on gae **almost** works. The failure was that the resulting fresh application loads Chameleon via: include package=repoze.bfg.includes / which is included in paster jinja2 template configure.zcml [2] Just removing this line gets the app up and running but is missing directives from repoze.zcml:meta.zcml I see 2 options: 1. replace the above mentioned include with the following in the jinja2 paster template (attached patch.diff) include package=repoze.zcml file=meta.zcml / ... which has the drawback that those using the paster template do not have Chameleon (desirable in gae but perhaps not in other scenarios). 2. Make a mention in the tutorial (perhaps as in attached doc.diff) Hope that is helpful, Darryl Cousins [1] http://docs.repoze.org/bfg/1.2/tutorials/gae/index.html [2] http://svn.repoze.org/repoze.bfg.jinja2/trunk/repoze/bfg/jinja2/paster_template/+package+/configure.zcml patch.diff Description: Binary data doc.diff Description: Binary data ___ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev
Re: [Repoze-dev] Running repoze.bfg on Google’s A pp Engine
Darryl Cousins wrote: Hi All, I found that the recipe [1] to run repoze.bfg on gae **almost** works. Thanks for the analysis! I think the best solution would be to make all imports of Chameleon conditional.This actually *used* to be the case; something must have broken it since 1.0 (the last time I tested that tutorial). Can you provide the traceback that is emitted when the wrong thing happens? The failure was that the resulting fresh application loads Chameleon via: include package=repoze.bfg.includes / which is included in paster jinja2 template configure.zcml [2] Just removing this line gets the app up and running but is missing directives from repoze.zcml:meta.zcml I see 2 options: 1. replace the above mentioned include with the following in the jinja2 paster template (attached patch.diff) include package=repoze.zcml file=meta.zcml / ... which has the drawback that those using the paster template do not have Chameleon (desirable in gae but perhaps not in other scenarios). 2. Make a mention in the tutorial (perhaps as in attached doc.diff) Hope that is helpful, Darryl Cousins [1] http://docs.repoze.org/bfg/1.2/tutorials/gae/index.html [2] http://svn.repoze.org/repoze.bfg.jinja2/trunk/repoze/bfg/jinja2/paster_template/+package+/configure.zcml ___ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev ___ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev
[Repoze-dev] Running repoze.bfg on Google’s App Engine
Hi Chris On Thu, Dec 3, 2009 at 8:11 PM, Chris McDonough chr...@plope.com wrote: Darryl Cousins wrote: Hi All, I found that the recipe [1] to run repoze.bfg on gae **almost** works. Thanks for the analysis! I think the best solution would be to make all imports of Chameleon conditional. This actually *used* to be the case; something must have broken it since 1.0 (the last time I tested that tutorial). Can you provide the traceback that is emitted when the wrong thing happens? Yes. App starts ok, on first request the following traceback: Mac OS X 10.5.8 - using python2.5 mac ports Hope that helps, best, Darryl darrylcous...@lyrrad:~/projects/placerama $ dev_appserver.py app INFO 2009-12-03 07:53:00,113 appengine_rpc.py:157] Server: appengine.google.com WARNING 2009-12-03 07:53:00,118 datastore_file_stub.py:443] Could not read datastore data from /var/folders/I+/I+TKAJhUHkGqvthbu07a-U+++TI/-Tmp-/dev_appserver.datastore INFO 2009-12-03 07:53:00,162 dev_appserver_main.py:478] Running application placerama on port 8080: http://localhost:8080 WARNING 2009-12-03 07:53:06,429 py_zipimport.py:103] Can't open zipfile /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/setuptools-0.6c11-py2.5.egg: IOError: [Errno 13] file not accessible: '/opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/setuptools-0.6c11-py2.5.egg' ERROR 2009-12-03 07:53:07,652 dev_appserver.py:3009] Exception encountered handling request Traceback (most recent call last): File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/dev_appserver.py, line 2978, in _HandleRequest base_env_dict=env_dict) File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/dev_appserver.py, line 411, in Dispatch base_env_dict=base_env_dict) File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/dev_appserver.py, line 2244, in Dispatch self._module_dict) File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/dev_appserver.py, line 2162, in ExecuteCGI reset_modules = exec_script(handler_path, cgi_path, hook) File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/dev_appserver.py, line 2058, in ExecuteOrImportScript exec module_code in script_module.__dict__ File /Users/darrylcousins/projects/placerama/app/runner.py, line 56, in module application = application(*(config_args or ()), **(config_kwargs or {})) File /Users/darrylcousins/projects/placerama/app/placerama/run.py, line 10, in app return make_app(get_root, placerama, options=kw) File /Users/darrylcousins/projects/placerama/app/lib/python/repoze.bfg-1.1.3-py2.5.egg/repoze/bfg/router.py, line 183, in make_app settings) File /Users/darrylcousins/projects/placerama/app/lib/python/repoze.bfg-1.1.3-py2.5.egg/repoze/bfg/configuration.py, line 107, in make_registry zcml_configure(filename, package) File /Users/darrylcousins/projects/placerama/app/lib/python/repoze.bfg-1.1.3-py2.5.egg/repoze/bfg/configuration.py, line 147, in zcml_configure xmlconfig.include(context, name, package) File /Users/darrylcousins/projects/placerama/app/lib/python/zope.configuration-3.6.0-py2.5.egg/zope/configuration/xmlconfig.py, line 546, in include processxmlfile(f, context) File /Users/darrylcousins/projects/placerama/app/lib/python/zope.configuration-3.6.0-py2.5.egg/zope/configuration/xmlconfig.py, line 378, in processxmlfile parser.parse(src) File /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/xml/sax/expatreader.py, line 107, in parse xmlreader.IncrementalParser.parse(self, source) File /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/xml/sax/xmlreader.py, line 123, in parse self.feed(buffer) File /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/xml/sax/expatreader.py, line 207, in feed self._parser.Parse(data, isFinal) File /opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/xml/sax/expatreader.py, line 349, in end_element_ns self._cont_handler.endElementNS(pair, None) File /Users/darrylcousins/projects/placerama/app/lib/python/zope.configuration-3.6.0-py2.5.egg/zope/configuration/xmlconfig.py, line 357, in endElementNS self.context.end() File /Users/darrylcousins/projects/placerama/app/lib/python/zope.configuration-3.6.0-py2.5.egg/zope/configuration/config.py, line 537, in end self.stack.pop().finish() File