Re: docs unclear re using zope global registry

2011-02-18 Thread Chris Withers
On 19/02/2011 00:25, Iain Duncan wrote: Further, in case it's useful, if you do this in your app start up code. gsm = getGlobalSiteManager() config = Configurator( registry=gsm ) then whenever you use request.registry you're using the zope global registry, in case you have some special need f

Re: Pyramid authentication options

2011-02-18 Thread Mariano Mara
On 18.02.11 15:13, whit wrote: > > >Ben Bangert was working on Velruse > >http://packages.python.org/velruse/index.html during pyramid's formative > >months. I'd look there for starters. > > > > has anyone done an integration between velruse and pyramid that > they'd care to share? > > -w > I

Re: docs unclear re using zope global registry

2011-02-18 Thread Daniel Holth
I think you are correct. -- You received this message because you are subscribed to the Google Groups "pylons-devel" group. To post to this group, send email to pylons-devel@googlegroups.com. To unsubscribe from this group, send email to pylons-devel+unsubscr...@googlegroups.com. For more optio

wsgi env still getting bfg attributes

2011-02-18 Thread Iain Duncan
I'm guessing this is know, but just wondering why we still have the following in the wsgi env when a route is matched: 'bfg.routes.matchdict': {u'key': u'foo'}, 'bfg.routes.route': , Would it be good to have them aliased in there as pyramid? I'm using that to get the matched route object for my o

Re: docs unclear re using zope global registry

2011-02-18 Thread Iain Duncan
Further, in case it's useful, if you do this in your app start up code. gsm = getGlobalSiteManager() config = Configurator( registry=gsm ) then whenever you use request.registry you're using the zope global registry, in case you have some special need for it to be so. thanks iain -- You rece

Re: docs unclear re using zope global registry

2011-02-18 Thread Iain Duncan
On Fri, Feb 18, 2011 at 3:44 PM, Daniel Holth wrote: > If you want to use the global ZCA then you should call > Configurator.hook_zca. See > http://docs.pylonsproject.org/projects/pyramid/dev/api/config.html#pyramid.config.Configurator.hook_zca > > Global ZCA means calls to > > zope.component.get

Re: docs unclear re using zope global registry

2011-02-18 Thread Daniel Holth
If you want to use the global ZCA then you should call Configurator.hook_zca. See http://docs.pylonsproject.org/projects/pyramid/dev/api/config.html#pyramid.config.Configurator.hook_zca Global ZCA means calls to zope.component.getUtility(ISomething) instead of request.registry.getUtility(ISomet

Re: Global variables

2011-02-18 Thread Iain Duncan
On Sat, Feb 12, 2011 at 9:53 AM, Chris McDonough wrote: > On Sat, 2011-02-12 at 09:43 -0800, Mike Orr wrote: > > On Wed, Feb 9, 2011 at 2:46 PM, Tres Seaver > wrote: > > > One bit I noticed: In > > > > https://bytebucket.org/sluggo/pyramid-docs/wiki/html/migration.html#app-globals-and-cache > ,

Re: Pyramid authentication options

2011-02-18 Thread whit
Ben Bangert was working on Velruse http://packages.python.org/velruse/index.html during pyramid's formative months. I'd look there for starters. has anyone done an integration between velruse and pyramid that they'd care to share? -w -- >>> Whit Morriss CodeMonkey w...@surveymonkey.com

Re: simulating pylons 1 static handling in pyramid

2011-02-18 Thread Iain Duncan
On Thu, Feb 17, 2011 at 7:53 PM, Chris McDonough wrote: > On Thu, 2011-02-17 at 19:36 -0800, Iain Duncan wrote: > > Thanks Jeff, I've made a custom predicate before, that should work. > > > > To the powers-that-be, is there the possibility of a more elegant way > > of doing that? > Cool, makes s

Re: docs unclear re using zope global registry

2011-02-18 Thread Iain Duncan
On Fri, Feb 18, 2011 at 6:12 AM, Chris Withers wrote: > On 18/02/2011 04:35, Iain Duncan wrote: > >> And I see the following: >> "If the registry argument is passed as a non-None value, it must be an >> instance of the pyramid.registry.Registry class representing the >> registry to configure." >>

Re: pyramid_who

2011-02-18 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/18/2011 05:06 PM, Tres Seaver wrote: >> - the link to http://docs.pylonshq.com/pyramid_who/dev/ redirects to >> http://docs.pylonsproject.org/ with no sign of "who" on the page. > > I think I requested that page be added on IRC. I will ask ag

Re: pyramid_who

2011-02-18 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/18/2011 01:14 PM, Chris Withers wrote: > Hi Tres, > > I see from: > > http://lists.repoze.org/pipermail/repoze-dev/2011-February/003770.html > > ...that I should use pyramid_who to get a Pyramid authentication policy > that will work with rep

Re: pyramid_who

2011-02-18 Thread Gael Pasgrimaud
On Fri, Feb 18, 2011 at 9:07 PM, Chris Withers wrote: > Even with repoze.who v2? The docs say no. Sorry, I missed this point. I'm mostly use repoze.what which depends on v1. > > On 18 Feb 2011, at 19:45, Gael Pasgrimaud wrote: > >> Hi, >> >> There is a builtin repoze.who policy in pyramid: >> >

Re: pyramid_who

2011-02-18 Thread Chris Withers
Even with repoze.who v2? On 18 Feb 2011, at 19:45, Gael Pasgrimaud wrote: > Hi, > > There is a builtin repoze.who policy in pyramid: > > http://docs.pylonsproject.org/projects/pyramid/dev/api/authentication.html#pyramid.authentication.RepozeWho1AuthenticationPolicy > > It work fine for me. >

Re: pyramid_who

2011-02-18 Thread Gael Pasgrimaud
Hi, There is a builtin repoze.who policy in pyramid: http://docs.pylonsproject.org/projects/pyramid/dev/api/authentication.html#pyramid.authentication.RepozeWho1AuthenticationPolicy It work fine for me. -- Gael On Fri, Feb 18, 2011 at 7:14 PM, Chris Withers wrote: > Hi Tres, > > I see from: >

Re: [Paste] Re: Passing on primary WebOb maintainership to Sergey Schetinin

2011-02-18 Thread Sergey Schetinin
On 17 February 2011 20:46, Chris McDonough wrote: > We've listed "attempt to port WebOb to Python 3" as one of the tasks at > the PyCon Pylons/Pyramid sprint > (http://us.pycon.org/2011/sprints/projects/).  I think basically this > task translates to "give WebOb 100% test coverage" as a first step

pyramid_who

2011-02-18 Thread Chris Withers
Hi Tres, I see from: http://lists.repoze.org/pipermail/repoze-dev/2011-February/003770.html ...that I should use pyramid_who to get a Pyramid authentication policy that will work with repoze.who 2.0? This leads to: http://pypi.python.org/pypi/pyramid_who ...which appears to be in a bit of

Re: default permission overriding

2011-02-18 Thread Chris Withers
On 18/02/2011 16:48, Chris McDonough wrote: @view_config(context=Blog, name='add_entry.html', permission=None) ...seems an explicit and less cumbersome way of specifying the same thing, what am I missing? You're missing the fact that the default value of the permission= argument to view_config

Re: default permission overriding

2011-02-18 Thread Chris McDonough
On Fri, 2011-02-18 at 16:43 +, Chris Withers wrote: > Hi All, > > Glad to see this feature: > http://docs.pylonsproject.org/projects/pyramid/1.0/narr/security.html#setting-a-default-permission > > Slightly confused by the cumbersome '__no_permission_required__' > requirement. > > @view_conf

default permission overriding

2011-02-18 Thread Chris Withers
Hi All, Glad to see this feature: http://docs.pylonsproject.org/projects/pyramid/1.0/narr/security.html#setting-a-default-permission Slightly confused by the cumbersome '__no_permission_required__' requirement. @view_config(context=Blog, name='add_entry.html', permission=None) ...seems an ex

Re: docs unclear re using zope global registry

2011-02-18 Thread Chris Withers
On 18/02/2011 04:35, Iain Duncan wrote: And I see the following: "If the registry argument is passed as a non-None value, it must be an instance of the pyramid.registry.Registry class representing the registry to configure." I certainly hope this isn't true. It would be frustrating if Pyramid n

mortar_rdb 1.0.0 released!

2011-02-18 Thread Chris Withers
Hi All, I'm very pleased to finally announce the release of mortar_rdb 1.0.0. This package ties together SQLAlchemy, sqlalchemy-migrate and the component architecture to make it easy to develop projects using SQLAlchemy through their complete lifecycle. While I'll be using it with Pyramid, the