Opened 10 years ago

Closed 10 years ago

#8982 closed defect (fixed)

python bindings scanStorageGroups(deleteold=True) fails

Reported by: daniel@… Owned by: Raymond Wagner
Priority: minor Milestone: 0.23-fixes
Component: Bindings - Python Version: 0.23.1
Severity: low Keywords:
Cc: Ticket locked: no


In the python bindings using scanStorageGroups(deleteold=True) from MythVideo? causes this error when there are old entries to remove.

>>> m = MythVideo(db=db1)
>>> m.scanStorageGroups(deleteold=True)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.6/dist-packages/MythTV/", line 1035, in scanStorageGroups
  File "/usr/lib/python2.6/dist-packages/MythTV/", line 1195, in delete
  File "/usr/lib/python2.6/dist-packages/MythTV/", line 1116, in clean
  File "/usr/lib/python2.6/dist-packages/MythTV/", line 1113, in delete
    def delete(self, member): DBDataCRef.delete(self,(member,))
  File "/usr/lib/python2.6/dist-packages/MythTV/", line 738, in delete
    index = self.hash.index[dat]
TypeError: 'builtin_function_or_method' object is unsubscriptable

MythTV Version   : 26407
MythTV Branch    : branches/release-0-23-fixes
Network Protocol : 23056
Library API      :
QT Version       : 4.5.2
Options compiled in:
 linux debug using_oss using_alsa using_pulse using_jack using_pulseoutput using_backend using_dvb using_firewire using_frontend using_glx_proc_addr_arb using_hdhomerun using_hdpvr using_iptv using_ivtv using_joystick_menu using_libudev using_lirc using_mheg using_opengl_video using_opengl_vsync using_qtdbus using_qtwebkit using_v4l using_x11 using_xrandr using_xv using_xvmc using_xvmc_vld using_xvmcw using_bindings_perl using_bindings_python using_opengl using_vdpau using_ffmpeg_threads using_libavc_5_3 using_live using_mheg

Change History (2)

comment:1 Changed 10 years ago by Raymond Wagner

Milestone: unknown0.23-fixes
Status: newaccepted

comment:2 Changed 10 years ago by Raymond Wagner

Resolution: fixed
Status: acceptedclosed

(In [26437]) This should fix the problem as reported. It's not tested, as I don't currently have a 0.23 system set up to test on. When I wrote this, I considered it cludgy and half broken, so I ended up rewriting the whole thing for trunk. If this continues to be a problem, I will likely backport the new code. Fixes #8982.

Note: See TracTickets for help on using tickets.