Ticket #9637 (closed Bug Report - General: fixed)
Opened 2 years ago
Last modified 2 years ago
Jamu.py crashes - unable to decode unicode
| Reported by: | troy@… | Owned by: | robertm |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.24.1 |
| Component: | Plugin - MythVideo | Version: | 0.24-fixes |
| Severity: | low | Keywords: | jamu.py mythvideo scripts |
| Cc: | Ticket locked: | no |
Description (last modified by wagnerrp) (diff)
Jamu.py crashes with the following error:
troy@ebony:/usr/local/bin$ jamu -MVI
Traceback (most recent call last):
File "/usr/local/bin/jamu", line 6420, in <module>
main()
File "/usr/local/bin/jamu", line 6388, in main
configuration.setUseroptions(default_config)
File "/usr/local/bin/jamu", line 1287, in setUseroptions
self.config['ignore-directory'].append(unicode(cfg.get(section, option), 'utf8'))
TypeError: decoding Unicode is not supported
jamu.conf contains the following entries for ignore-directory:
[ignore-directory] ignore01: /var/lib/mythtv/videos/Movies/.AppleDouble/ ignore02: /var/lib/mythtv/videos/Movies/Childrens/.AppleDouble/ ignore03: /var/lib/mythtv/videos/Series/.AppleDouble/ ignore04: /var/lib/mythtv/videos/Documentaries/.AppleDouble/ ignore05: .AppleDouble/ ignore08: Movies/.AppleDouble/
Removing the ignore-directory options stops the crash.
Alternatively altering line 1287 in jamu.py fixes the crash:
from:
self.config['ignore-directory'].append(unicode(cfg.get(section, option), 'utf8'))
to:
self.config['ignore-directory'].append(cfg.get(section, option))
Attachments
Change History
comment:1 Changed 2 years ago by kenni
comment:3 Changed 2 years ago by kenni
pastebin-copy of the patch expires today - patch attached to this ticket instead.
comment:4 Changed 2 years ago by Kenni Lund
Fix a bug which caused jamu to crash due to multiple unicode conversions.
Refs #9637.
Changeset: 454f85387c51cd71bd24f350083a1f90ad515be0
comment:5 Changed 2 years ago by Kenni Lund
- Status changed from new to closed
- Resolution set to fixed
Fix a bug which caused jamu to crash due to multiple unicode conversions.
Fixes #9637. ACKed by Doug Vaughan.
Changeset: 464fa2837373d5f0c9277482a06bbb871369f7b7

The regex entry also needs fixing: http://mythtv.pastebin.com/pHurujGD
I'm awaiting approval from Doug Vaughan, the author of Jamu, before comitting the above patch.