[Repoze-dev] Possible accept view-predicate enhancement?

2009-11-25 Thread Alberto Valverde
Hello, I'm trying to make use of the new-in-1.1 accept view predicate to register several views with the same name for the same context object to render a response in the content-type requested by the user but the result is not quite what I expect. The zcml looks like this: view

Re: [Repoze-dev] Possible accept view-predicate enhancement?

2009-11-25 Thread Malthe Borch
2009/11/25 Alberto Valverde albe...@toscat.net: Everything works fine when I request the application/json and application/json+xconfig mimetypes with a xhr since I can control the Accept header, however, when a browser makes a normal request the result is unpredictable (in practice) since '*/*

Re: [Repoze-dev] Possible accept view-predicate enhancement?

2009-11-25 Thread Chris McDonough
Alberto Valverde wrote: Hello, I'm trying to make use of the new-in-1.1 accept view predicate to register several views with the same name for the same context object to render a response in the content-type requested by the user but the result is not quite what I expect. The zcml looks

Re: [Repoze-dev] would like to registerViews in python but not via decorator

2009-11-25 Thread Chris McDonough
Tim Hoffman wrote: Hi Chris I am trying to register some views directly through python and not using the view decorator, I have tried using code very similiar to repoze.bfg.testing. However after doing so, whilst I can look the view up by doing a

Re: [Repoze-dev] would like to registerViews in python but not via decorator

2009-11-25 Thread Tim Hoffman
Hi Chris Yeah I figured I as getting the wrong registry, and in fact I was if I try and register stuff too early it all went in to the wrong bucket. I am still having some problems looking stuff up. I can manually look stuff up with

Re: [Repoze-dev] Possible accept view-predicate enhancement?

2009-11-25 Thread Chris McDonough
Alberto Valverde wrote: Hello, I'm trying to make use of the new-in-1.1 accept view predicate to register several views with the same name for the same context object to render a response in the content-type requested by the user but the result is not quite what I expect. The zcml looks