On 30.6.2016 10:32, Jan Cholasta wrote:
On 29.6.2016 10:21, Jan Cholasta wrote:
On 29.6.2016 09:22, David Kupka wrote:
On 28/04/16 14:45, Jan Cholasta wrote:

I have pushed my thin client WIP branch to GitHub:

All commits up to "ipalib: use relative imports for cross-plugin
imports" should be good for review. The rest is subject to change
(WARNING: I will force push into this branch).



Commit "schema: fix Flag arguments on the client" fixes regression
reported in https://fedorahosted.org/freeipa/ticket/6009, ACK.

Thanks, pushed to master: a77e21cbca05be422fe5826857cfba7e0ba6e71f

Attaching the patch for reference.

Martin found a regression caused by this patch. The attached patch
should fix it.

Self-NACK, correct patch attached.

Jan Cholasta
From 195dd2f8acf9e7461e25b505a2a6a7d2067765ed Mon Sep 17 00:00:00 2001
From: Jan Cholasta <jchol...@redhat.com>
Date: Thu, 30 Jun 2016 10:27:05 +0200
Subject: [PATCH] schema: properly fix Flag arguments on the client

The previous fix in commit a77e21cbca05be422fe5826857cfba7e0ba6e71f made
some Bool arguments appear as Flag on the client. This change fixes that.

 ipaclient/remote_plugins/schema.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ipaclient/remote_plugins/schema.py b/ipaclient/remote_plugins/schema.py
index 7d5c8d0..da917a9 100644
--- a/ipaclient/remote_plugins/schema.py
+++ b/ipaclient/remote_plugins/schema.py
@@ -219,8 +219,8 @@ class _SchemaPlugin(object):
             cls = Password
             sensitive = False
         elif (type_name == 'bool' and
-                'default' in schema and
-                schema['default'][0] == u'False'):
+                'default' in schema and schema['default'][0] == u'False' and
+                not schema.get('alwaysask', False)):
             cls = Flag
             del schema['default']

Manage your subscription for the Freeipa-devel mailing list:
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to