git://git.onelab.eu
/
sfa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f814241
)
AddPerson is more picky
author
Thierry Parmentelat
<thierry.parmentelat@inria.fr>
Wed, 12 Dec 2012 08:59:42 +0000
(09:59 +0100)
committer
Mohamed Larabi
<mohamed.larabi@inria.fr>
Thu, 20 Dec 2012 10:30:17 +0000
(11:30 +0100)
sfa/planetlab/pldriver.py
patch
|
blob
|
history
diff --git
a/sfa/planetlab/pldriver.py
b/sfa/planetlab/pldriver.py
index
db9a2dd
..
c47d170
100644
(file)
--- a/
sfa/planetlab/pldriver.py
+++ b/
sfa/planetlab/pldriver.py
@@
-91,7
+91,10
@@
class PlDriver (Driver):
if not persons:
for key in ['first_name','last_name']:
if key not in sfa_record: sfa_record[key]='*from*sfa*'
- pointer = self.shell.AddPerson(dict(sfa_record))
+ # AddPerson does not allow everything to be set
+ can_add = ['first_name', 'last_name', 'title','email', 'password', 'phone', 'url', 'bio']
+ add_person_dict=dict ( [ (k,sfa_record[k]) for k in sfa_record if k in can_add ] )
+ pointer = self.shell.AddPerson(add_person_dict)
else:
pointer = persons[0]['person_id']