Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Make friendlyform dependency optional

  • Loading branch information...
commit 7433a538d0b1b43a8f6d1446bc33bc57cf0ab6e1 1 parent 4f960cf
@amol- amol- authored
Showing with 4 additions and 4 deletions.
  1. +1 −2  setup.py
  2. +3 −2 tgming/auth.py
View
3  setup.py
@@ -27,9 +27,8 @@
include_package_data=True,
zip_safe=False,
install_requires=[
- "repoze.who-friendlyform >= 1.0.4",
"repoze.who >= 1.0.19",
- "ming<0.3.2dev"
+ "ming"
# -*- Extra requirements: -*-
],
entry_points="""
View
5 tgming/auth.py
@@ -1,7 +1,5 @@
from zope.interface import implements
from repoze.who.interfaces import IAuthenticator, IMetadataProvider
-from repoze.who.plugins.friendlyform import FriendlyFormPlugin
-from repoze.who.plugins.auth_tkt import AuthTktCookiePlugin
class MingAuthenticatorPlugin(object):
implements(IAuthenticator)
@@ -43,6 +41,9 @@ def add_metadata(self, environ, identity):
environ['repoze.what.credentials']['repoze.what.userid'] = identity['repoze.who.userid']
def setup_ming_auth(app, skip_authentication, **auth_args):
+ from repoze.who.plugins.auth_tkt import AuthTktCookiePlugin
+ from repoze.who.plugins.friendlyform import FriendlyFormPlugin
+
cookie_secret = auth_args.get('cookie_secret', 'secret')
cookie_name = auth_args.get('cookie_name', 'authtkt')
Please sign in to comment.
Something went wrong with that request. Please try again.