[Freeipa-devel] [PATCH] 103 Fix automountkey-mod

Martin Kosek mkosek at redhat.com
Thu Jul 28 09:49:20 UTC 2011


On Wed, 2011-07-27 at 14:53 -0400, Rob Crittenden wrote:
> Martin Kosek wrote:
> > On Wed, 2011-07-27 at 12:11 -0400, Dmitri Pal wrote:
> >> On 07/27/2011 12:00 PM, Martin Kosek wrote:
> >>> On Wed, 2011-07-27 at 10:41 -0400, Rob Crittenden wrote:
> >>>> Martin Kosek wrote:
> >>>>> Fix automountkey-mod so that automountkey attribute is correctly
> >>>>> updated. Add this test case to the unit tests.
> >>>>>
> >>>>> https://fedorahosted.org/freeipa/ticket/1528
> >>>> It fixes the problem but I've found another: --key isn't required so if
> >>>> you don't pass it in then a backtrace will occur:
> >>>>
> >>>> Traceback (most recent call last):
> >>>>     File "/home/rcrit/redhat/freeipa-master/ipaserver/rpcserver.py", line
> >>>> 220, in wsgi_execute
> >>>>       result = self.Command[name](*args, **options)
> >>>>     File "/home/rcrit/redhat/freeipa-master/ipalib/frontend.py", line
> >>>> 425, in __call__
> >>>>       ret = self.run(*args, **options)
> >>>>     File "/home/rcrit/redhat/freeipa-master/ipalib/frontend.py", line
> >>>> 731, in run
> >>>>       return self.execute(*args, **options)
> >>>>     File "/home/rcrit/redhat/freeipa-master/ipalib/plugins/automount.py",
> >>>> line 873, in execute
> >>>>       keys += (self.obj.get_pk(options['automountkey'],
> >>>> KeyError: 'automountkey'
> >>>>
> >>>> Also, automountinformation is already required. This may be a leftover
> >>>> from when we used it in description, this can probably be lifted too.
> >>>>
> >>>> rob
> >>> Good catch. I fixed this bug too and I also made --newinfo optional so
> >>> that automountkey may be just renamed without changing its info
> >>> attribute.
> >>>
> >>> I didn't bump up API VERSION as these are either compatible changes or
> >>> they caused server internal error.
> >>>
> >>> Martin
> >>
> >> Should the ticket be moved into 2.1 July sprint then?
> >
> > Yes, I would like this to be included in 2.1. I will move ticket to
> > correct milestone (2.1) if we manage to review&push it before release.
> >
> > Martin
> 
> nack. Something is up with _mod. I can't be sure it is this patch or it 
> was always here.
> 
> In the UI every change wanted to try to rename the entry. On the 
> command-line I wasn't able to update the info at all.
> 
> rob

Hm, I think this problem was in the _mod command all the time.
'description' field was being filled every time which triggered rename
operation. This caused problems.

I rewrote _mod command so that 'description' (i.e. rename) is filled
only when needed.

I checked UI and automountkey_mod command worked OK for me.

Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: freeipa-mkosek-103-3-fix-automountkey-mod.patch
Type: text/x-patch
Size: 10055 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20110728/10c89c76/attachment.bin>


More information about the Freeipa-devel mailing list