#4371 *-show --all --raw --rights fails with internal error
Closed: Fixed None Opened 9 years ago by rcritten.

I tested permission-show and user-show --all --raw --rights and it fails with an internal error:

$ ipa user-show --all --raw --rights admin
ipa: ERROR: an internal error has occurred

The traceback is this:

[Mon Jun 09 13:02:17.336497 2014] [:error] [pid 14621] ipa: INFO: [jsonserver_session] admin@EXAMPLE.COM: service_show(u'test1/grindle.example.com@EXAMPLE.COM', rights=True, all=True, raw=False, version=u'2.88', no_members=False): SUCCESS
[Mon Jun 09 13:03:35.056401 2014] [:error] [pid 14620] ipa: ERROR: non-public: TypeError: unhashable type: 'dict'
[Mon Jun 09 13:03:35.056427 2014] [:error] [pid 14620] Traceback (most recent call last):
[Mon Jun 09 13:03:35.056431 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipaserver/rpcserver.py", line 343, in wsgi_execute
[Mon Jun 09 13:03:35.056435 2014] [:error] [pid 14620]     result = self.Command[name](*args, **options)
[Mon Jun 09 13:03:35.056439 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipalib/frontend.py", line 436, in __call__
[Mon Jun 09 13:03:35.056443 2014] [:error] [pid 14620]     ret = self.run(*args, **options)
[Mon Jun 09 13:03:35.056447 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipalib/frontend.py", line 752, in run
[Mon Jun 09 13:03:35.056451 2014] [:error] [pid 14620]     result = self.execute(*args, **options)
[Mon Jun 09 13:03:35.056455 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipalib/plugins/baseldap.py", line 1261, in execute
[Mon Jun 09 13:03:35.056459 2014] [:error] [pid 14620]     entry_attrs = entry_to_dict(entry_attrs, **options)
[Mon Jun 09 13:03:35.056463 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipalib/plugins/baseldap.py", line 239, in entry_to_dict
[Mon Jun 09 13:03:35.056467 2014] [:error] [pid 14620]     for attr, value in entry.raw.iteritems():
[Mon Jun 09 13:03:35.056470 2014] [:error] [pid 14620]   File "/usr/lib64/python2.7/_abcoll.py", line 387, in iteritems
[Mon Jun 09 13:03:35.056474 2014] [:error] [pid 14620]     yield (key, self[key])
[Mon Jun 09 13:03:35.056478 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipapython/ipaldap.py", line 1087, in __getitem__
[Mon Jun 09 13:03:35.056482 2014] [:error] [pid 14620]     return self._entry._get_raw(name)
[Mon Jun 09 13:03:35.056486 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipapython/ipaldap.py", line 923, in _get_raw
[Mon Jun 09 13:03:35.056490 2014] [:error] [pid 14620]     self._sync_attr(name)
[Mon Jun 09 13:03:35.056494 2014] [:error] [pid 14620]   File "/usr/lib/python2.7/site-packages/ipapython/ipaldap.py", line 778, in _sync_attr
[Mon Jun 09 13:03:35.056497 2014] [:error] [pid 14620]     nice_adds = set(nice) - set(nice_sync)
[Mon Jun 09 13:03:35.056501 2014] [:error] [pid 14620] TypeError: unhashable type: 'dict'
[Mon Jun 09 13:03:35.056792 2014] [:error] [pid 14620] ipa: INFO: [jsonserver_session] admin@EXAMPLE.COM: user_show(u'admin', rights=True, all=True, raw=True, version=u'2.88', no_members=False): TypeError

It works without --raw.


FreeIPA 4.0.1 was released, moving to next bugfixing release milestone.

master:

  • 785e13d Exclude attributelevelrights from --raw result processing in baseldap.

ipa-4-1:

  • 785e13d Exclude attributelevelrights from --raw result processing in baseldap.

ipa-4-0:

  • 2eee606 Exclude attributelevelrights from --raw result processing in baseldap.

entry_to_dict unit test:

master:

  • 34de955 Add test for baseldap.entry_to_dict.

ipa-4-0:

  • c93fe68 Add test for baseldap.entry_to_dict.

ipa-4-1:

  • 34de955 Add test for baseldap.entry_to_dict.

Metadata Update from @rcritten:
- Issue assigned to jcholast
- Issue set to the milestone: FreeIPA 4.0.2

7 years ago

Login to comment on this ticket.

Metadata