From cefb56b2b19d9c7f2795dab4e58be90759444469 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: May 04 2015 11:07:07 +0000 Subject: [PATCH 1/3] Port our local copy of flask_fas_openid to python-munch --- diff --git a/pagure/flask_fas_openid.py b/pagure/flask_fas_openid.py index 2afb4d9..65646ae 100644 --- a/pagure/flask_fas_openid.py +++ b/pagure/flask_fas_openid.py @@ -29,7 +29,7 @@ FAS-OpenID authentication plugin for the flask web framework import datetime from functools import wraps -from bunch import Bunch +from munch import Munch import flask from openid.consumer import consumer @@ -169,8 +169,8 @@ class FAS(object): # pragma: no cover for group in user['groups']: membership = dict() membership['name'] = group - user['approved_memberships'].append(Bunch.fromDict(membership)) - flask.g.fas_user = Bunch.fromDict(user) + user['approved_memberships'].append(Munch.fromDict(membership)) + flask.g.fas_user = Munch.fromDict(user) flask.g.fas_user.groups = frozenset(flask.g.fas_user.groups) flask.g.fas_session_id = 0 From 0fb5f188797d4b5dba4360c824fa6784125e9a01 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: May 04 2015 11:11:37 +0000 Subject: [PATCH 2/3] Add python-munch to the list of dependencies in the spec file --- diff --git a/files/pagure.spec b/files/pagure.spec index 8eeb88b..5ea51c7 100644 --- a/files/pagure.spec +++ b/files/pagure.spec @@ -33,6 +33,7 @@ BuildRequires: python-openid-cla BuildRequires: python-openid-teams BuildRequires: python-straight-plugin BuildRequires: python-wtforms +BuildRequires: python-munch # EPEL6 %if ( 0%{?rhel} && 0%{?rhel} == 6 ) @@ -60,6 +61,7 @@ Requires: python-openid-cla Requires: python-openid-teams Requires: python-straight-plugin Requires: python-wtforms +Requires: python-munch Requires: mod_wsgi # No dependency of the app per say, but required to make it working. From dc9f1641c738e5cfb162aa78341c210a4833683d Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: May 04 2015 11:11:55 +0000 Subject: [PATCH 3/3] Add munch to the list of requirements in requirements.txt --- diff --git a/requirements.txt b/requirements.txt index 42877b2..8746b13 100644 --- a/requirements.txt +++ b/requirements.txt @@ -8,6 +8,7 @@ docutils flask flask-wtf markdown +munch psutil pygit2 >= 0.20.1 pygments