[Freeipa-devel] [freeipa PR#444][comment] Allow nsaccountlock to be searched in user-find and user-show commands

2017-02-09 Thread redhatrises
  URL: https://github.com/freeipa/freeipa/pull/444
Title: #444: Allow nsaccountlock to be searched in user-find and user-show 
commands

redhatrises commented:
"""
> Why user-show needs --nsaccountlock option?

I didn't want to limit it to user-find. However, it looks like adding the 
option is actually pointless as that information is in the output already. I 
can fix that.

> Could be this done by changing flags instead of overriding get_options? IMO 
> it is compatible

@MartinBasti sure. Not sure where we are with ABI/API compatibility issues 
which is why I didn't use the overriding get_options. I guess we will see what 
@HonzaCholasta says.
"""

See the full comment at 
https://github.com/freeipa/freeipa/pull/444#issuecomment-278701548
-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

[Freeipa-devel] [freeipa PR#444][comment] Allow nsaccountlock to be searched in user-find and user-show commands

2017-02-09 Thread MartinBasti
  URL: https://github.com/freeipa/freeipa/pull/444
Title: #444: Allow nsaccountlock to be searched in user-find and user-show 
commands

MartinBasti commented:
"""
Hello,

thank you for PR!

I have a few comments:
- Why user-show needs --nsaccountlock option?
- Could be this done by changing flags instead of overriding get_options?  IMO 
it is compatible
```diff
diff --git a/ipaserver/plugins/user.py b/ipaserver/plugins/user.py
index 0194f1b..3df2723 100644
--- a/ipaserver/plugins/user.py
+++ b/ipaserver/plugins/user.py
@@ -371,7 +371,7 @@ class user(baseuser):
 takes_params = baseuser.takes_params + (
 Bool('nsaccountlock?',
 label=_('Account disabled'),
-flags=['no_option'],
+flags=['no_create', 'no_update'],
 ),
 Bool('preserved?',
 label=_('Preserved user'),
```

Adding @HonzaCholasta to make sure that changing options in this way is  
compatible
"""

See the full comment at 
https://github.com/freeipa/freeipa/pull/444#issuecomment-278676072
-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code