# Mark Huang <mlhuang@cs.princeton.edu>
# Copyright (C) 2005 The Trustees of Princeton University
#
-# $Id$
-# $URL$
-#
# python-pycurl and python-psycopg2 avail. from fedora 5
# we used to ship our own version of psycopg2 and pycurl, for fedora4
if 'admin' not in self.caller['roles']:
# check caller is affiliated with this person's person
if not self.caller.can_update(person):
- raise PLCPermissionDenied, "Not a member of the person's persons: %s"%person['person_ids']
+ raise PLCPermissionDenied, "person_id %s doesn't have access to person_tag_id %s" % (
+ person['person_id'],
+ person_tag['person_tag_id'])
required_min_role = person_tag['min_role_id']
if required_min_role is not None and \
min(self.caller['role_ids']) > required_min_role:
- raise PLCPermissionDenied, "Not allowed to modify the specified person setting, requires role %d",required_min_role
+ raise PLCPermissionDenied, "Not allowed to modify the specified person setting, requires role %d" % required_min_role
person_tag['value'] = value
person_tag.sync()