Re: [Repoze-dev] repoze.what-pylons bug

2009-02-17 Thread binet bruno
Great! I'll test it today and i'll post my feedback.
Thanks.

Bruno

2009/2/16 Gustavo Narea m...@gustavonarea.net:
 I'm sorry about the delay.

 This is fixed in the third beta:
 http://code.gustavonarea.net/repoze.what-pylons/News.html

 To upgrade:
easy_install -U repoze.what-pylons

 Happy coding!

 On Wednesday February 11, 2009 16:46:08 binet bruno wrote:
 I get the same error with v1.0b2... :(

 I look at protectors.py code, and you still don't use module decorator
 which preserve the signature. Why don't you use it, as it is done by
 other pylons built-in decorators?

 Cheers.

 2009/2/11 Gustavo Narea m...@gustavonarea.net:
  Hello, Bruno.
 
  That's right, today I released v1.0b2 to fix it.
 
  Please upgrade and let me know if now it works for you.
 
  Cheers!
 
  On Wednesday February 11, 2009 16:32:09 binet bruno wrote:
  Hi.
 
  I am currently testing the new repoze.what plugin for pylons (
  http://wiki.pylonshq.com/display/pylonscookbook/Authorization+with+repoz
 e.w hat )
  But an error occured when
  repoze.what.plugins.pylonshq.ActionController is decorating my index
  action of my main controller :
  TypeError: index() got an unexpected keyword argument 'action'
  Here is the traceback :
  http://beta.pylonshq.com/tracebacks/5ea1b0dab9e46b046bb516cff61a5c50
 
  After submitting my issue to pylons irc channel, Jon Rosebaugh told me
  it's a bug in repoze.what's plugin related to decorators and routing.
  Here is its investigation :
  Specifically, Pylons and Routes inspects the controller action to see
  what parameters it takes. The current plugin decorator destroys the
  action's signature and makes it look like it takes *args, **kwargs,
  when actually it does not. So, they should use the decorator module
  (http://pypi.python.org/pypi/decorator/) to preserve signature.
 
  Cheers,
 
  Bruno
  ___
  Repoze-dev mailing list
  Repoze-dev@lists.repoze.org
  http://lists.repoze.org/listinfo/repoze-dev
 
  --
  Gustavo Narea http://gustavonarea.net/.
 
  Get rid of unethical constraints! Get freedomware:
  http://www.getgnulinux.org/

 --
 Gustavo Narea http://gustavonarea.net/.

 Get rid of unethical constraints! Get freedomware:
 http://www.getgnulinux.org/

___
Repoze-dev mailing list
Repoze-dev@lists.repoze.org
http://lists.repoze.org/listinfo/repoze-dev


Re: [Repoze-dev] ActionProtector

2009-02-17 Thread binet bruno
Hi,

You should use version 1.0b3 of repoze.what-pylons, which Gustavo has
released today, instead of 1.0b2. It should solve your problem.
Cheers,

Bruno

2009/2/17 Iain Campbell i...@kandaba.com:
 Hi,

 Having sorted out the authentication, I'm now having a (presumably
 small) problem protecting controller actions. Following the quick
 start, if I do:

 @ActionProtector(has_permission('something'))
  def index(self):
return render('/derived/document/index.html')

 I get the following traceback:

 File 
 '/usr/lib/python2.5/site-packages/repoze.what_pylons-1.0b2-py2.5.egg/repoze/what/plugins/pylonshq/protectors.py',
 line 95 in check
  return func(*args, **kwargs)
 TypeError: index() got an unexpected keyword argument 'action'

 The actual arguments being passed to the controller action are:

 action, start_response, controller, environ, pylon

 I'm assuming I shouldn't actually have to handle these in the controller 
 action?

 Thanks,

 Iain

 --
 www.kandaba.com

 web | iptv | mobile
 development  consultancy

 t: +44 (0) 203 051 7792
 m: +44 (0) 7815 821 678
 gtalk: i...@kandaba.com
 ___
 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


Re: [Repoze-dev] ActionProtector

2009-02-17 Thread Iain Campbell
Oh, I'm using Python 2.5...

-- 
www.kandaba.com

web | iptv | mobile
development  consultancy

t: +44 (0) 203 051 7792
m: +44 (0) 7815 821 678
gtalk: i...@kandaba.com
___
Repoze-dev mailing list
Repoze-dev@lists.repoze.org
http://lists.repoze.org/listinfo/repoze-dev


[Repoze-dev] [issue63] Mention all the known repoze.who plugin implementations

2009-02-17 Thread Gustavo Narea

New submission from Gustavo Narea m...@gustavonarea.net:

The documentation for repoze.who should include a page which lists all the 
known plugin
implementations. Something similar to:
http://static.repoze.org/whatdocs/Manual/Plugins/index.html

--
assignedto: Gustavo
messages: 145
nosy: Gustavo
priority: feature
status: unread
title: Mention all the known repoze.who plugin implementations
topic: repoze.who

__
Repoze Bugs b...@bugs.repoze.org
http://bugs.repoze.org/issue63
__
___
Repoze-dev mailing list
Repoze-dev@lists.repoze.org
http://lists.repoze.org/listinfo/repoze-dev


[Repoze-dev] repoze.who-friendlyform and repoze.what-quickstart

2009-02-17 Thread Gustavo Narea
Hello, everybody.

This is just to let you know that I just moved the 
FriendlyRedirectingFormPlugin from repoze.what-quickstart to the new 
repoze.who-friendlyform project. So now it's safe to import it (you don't have 
to copy its code anymore).

Keep in mind that if you ignored the warning where I said that 
repoze.what.plugins.quickstart was a temporary location for 
FriendlyRedirectingForm plugin, your code is going to break.

The relevant changelogs:
http://code.gustavonarea.net/repoze.what-quickstart/News.html
http://code.gustavonarea.net/repoze.who-friendlyform/News.html

Cheers.
-- 
Gustavo Narea http://gustavonarea.net/.

Get rid of unethical constraints! Get freedomware:
http://www.getgnulinux.org/
___
Repoze-dev mailing list
Repoze-dev@lists.repoze.org
http://lists.repoze.org/listinfo/repoze-dev