[Freeipa-devel] [PATCH] 309 Fix addattr internal error

Rob Crittenden rcritten at redhat.com
Thu Sep 13 19:19:34 UTC 2012


Martin Kosek wrote:
> When ADD command is being executed and a single-value object attribute
> is being set with both option and addattr IPA ends up in an internal
> error.
>
> Make better value sanitizing job in this case and let IPA throw
> a user-friendly error. Unit test exercising this situation is added.
>
> https://fedorahosted.org/freeipa/ticket/2429

+                if not isinstance(val, (list, tuple)):
+                    val = [val]
+            val.extend(adddict[attr])

I val is a tuple the extend is still going to fail. Can val ever be a 
tuple? If so we'd need to convert it to a list.

rob




More information about the Freeipa-devel mailing list