Bugs item #1622266, was opened at 2006-12-26 08:17
Message generated for change (Comment added) made by duncanwebb
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=446895&aid=1622266&group_id=46652
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: video
Group: kaa svn
>Status: Pending
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Frank Naude (naudefj)
Assigned to: Nobody/Anonymous (nobody)
Summary: Chapter' object has no attribute 'url'
Initial Comment:
Traceback (most recent call last):
File "/usr/lib/python2.4/site-packages/freevo/skins/main/info_area.py", line
99, in update_content
self.sellist = self.eval_expressions( self.list )
File "/usr/lib/python2.4/site-packages/freevo/skins/main/info_area.py", line
251, in eval_expressions
if exp and eval(exp, {'attr': item.getattr}, function_calls):
File "<string>", line 0, in ?
File "/usr/lib/python2.4/site-packages/freevo/item.py", line 444, in getattr
return Unicode(r)
File "/usr/lib/python2.4/site-packages/freevo/util/__init__.py", line 53, in
Unicode
return unicode(str(string), config.LOCALE)
File "/usr/lib64/python2.4/site-packages/kaa/metadata/core.py", line 152, in
__repr__
return '<%s %s>' % (str(self.__class__)[8:-2], self.url)
AttributeError: 'Chapter' object has no attribute 'url'
----------------------------------------------------------------------
>Comment By: Duncan Webb (duncanwebb)
Date: 2006-12-28 18:03
Message:
Logged In: YES
user_id=104395
Originator: NO
At last, this is now solved. kaa.metadata returns a list of chapters,
mmpyhon returned the number of chapters. The skins needed updating for this
to work correctly.
In rel-1 at r8851
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-12-28 17:14
Message:
Logged In: YES
user_id=104395
Originator: NO
Many thanks, dischi has confirmed that the patch is correct.
However it does not really do what it should, instread of the crash we
get
17 Subtitles
[<kaa.metadata.video.core.Chapter>] Chapters, it should be returning the
numbers of chapters.
Patch applied to kaa at r2291
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 21:26
Message:
Logged In: YES
user_id=1196812
Originator: NO
If you look at the patch I supplied it does just that. It first
determines if a object has the attribute URL and then passes it do the
correct function.
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-12-27 19:43
Message:
Logged In: YES
user_id=104395
Originator: NO
It is definately a bug in kaa.metadata, but what is the intention, if you
look a __str__ above there is no self.url and chapters don't have a url
attribute, I suspect the intention is just:
return '<%s>' % (str(self.__class__)[8:-2])
Need to wait until dischi returns from his holidays for a fix.
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 19:32
Message:
Logged In: YES
user_id=1196812
Originator: NO
Index: metadata/src/core.py
===================================================================
--- metadata/src/core.py (revision 2288)
+++ metadata/src/core.py (working copy)
@@ -149,7 +149,10 @@
def __repr__(self):
- return '<%s %s>' % (str(self.__class__)[8:-2], self.url)
+ if hasattr(self, 'url'):
+ return '<%s %s>' % (str(self.__class__)[8:-2], self.url)
+ else:
+ return '<%s>' % (str(self.__class__)[8:-2])
#
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 19:19
Message:
Logged In: YES
user_id=1196812
Originator: NO
Why is it that when you select a chapter it uses MPlayer not Xine?
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 19:14
Message:
Logged In: YES
user_id=1196812
Originator: NO
I was able to reproduce it finally:
File "/usr/lib/python2.4/site-packages/freevo/skins/main/info_area.py",
line 99, in update_content
self.sellist = self.eval_expressions( self.list )
File "/usr/lib/python2.4/site-packages/freevo/skins/main/info_area.py",
line 251, in eval_expressions
if exp and eval(exp, {'attr': item.getattr}, function_calls):
File "<string>", line 0, in ?
File "/usr/lib/python2.4/site-packages/freevo/item.py", line 434, in
getattr
return Unicode(r)
File "/usr/lib/python2.4/site-packages/freevo/util/__init__.py", line
56, in Unicode
return unicode(str(string), config.LOCALE)
File "/usr/lib/python2.4/site-packages/kaa/metadata/core.py", line 152,
in __repr__
return '<%s %s>' % (str(self.__class__)[8:-2], self.url)
AttributeError: 'Chapter' object has no attribute 'url'
----------------------------------------------------------------------
Comment By: Frank Naude (naudefj)
Date: 2006-12-27 19:10
Message:
Logged In: YES
user_id=143611
Originator: YES
I've tested with encoding = "iso-8859-1", but get the same traceback.
Looks like no URL is generated, that's why xine is complaining about
invalid options.
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 18:24
Message:
Logged In: YES
user_id=1196812
Originator: NO
I can not get the problem to recreate. Your error log shows that the
error is happening when returning the url, which has unicode functions.
Try this:
change your encoding line in /usr/lib/python2.4/site.py to:
encoding = "iso-8859-1"
It has fixed several issues for me. You can change it back if nothing
happens.
----------------------------------------------------------------------
Comment By: Frank Naude (naudefj)
Date: 2006-12-27 18:21
Message:
Logged In: YES
user_id=143611
Originator: YES
It doesn't look like a unicode problem to me - no special or strange
characters. And, yes, I do run to on the latest SVN (updated a couple of
hours ago). Can you simulate the problem?
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 18:17
Message:
Logged In: YES
user_id=1196812
Originator: NO
Have you updated to the latest SVN? There are a lot of Unicode bug fixes.
----------------------------------------------------------------------
Comment By: Frank Naude (naudefj)
Date: 2006-12-27 18:14
Message:
Logged In: YES
user_id=143611
Originator: YES
That's good news. And, since you've messed-up my bug report, can you
please try to reproduce the reported issue?
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 17:37
Message:
Logged In: YES
user_id=1196812
Originator: NO
The current SVN release seems to have fixed the issue
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 17:25
Message:
Logged In: YES
user_id=1196812
Originator: NO
I tried that and I still have the same problem. The DVD drive shows as
empty. LSDVD shows all the proper track info, but Freevo does not detect
it. I am running the current SVN.
----------------------------------------------------------------------
Comment By: Frank Naude (naudefj)
Date: 2006-12-27 07:11
Message:
Logged In: YES
user_id=143611
Originator: YES
I has the same problem before this one. See solution to your problem at
http://www.mail-archive.com/[email protected]/msg12491.html
----------------------------------------------------------------------
Comment By: ryan (ryanroth)
Date: 2006-12-27 01:23
Message:
Logged In: YES
user_id=1196812
Originator: NO
I tried reproducing this error and the current SVN build looks to be
broken. It always shows my DVD drive as empty now. I know it was working
last week, but I update SVN daily.
----------------------------------------------------------------------
Comment By: Frank Naude (naudefj)
Date: 2006-12-26 11:08
Message:
Logged In: YES
user_id=143611
Originator: YES
Steps to reproduce:
1. Insert DVD into drive
2. Navigate to Watch a Movie -> DVD
3. Hit ENTER (back to the menu - I expected it to start paying the DVD)
4. Hit DISPLAY and select "Play DVD" (not working either)
5. Select "DVD Title List" - 3 titles are shown and the above error
reported in log.
$ lsdvd
Disc Title: SKOUSPEL_2006
Title: 01, Length: 02:38:52.330 Chapters: 51, Cells: 51, Audio streams:
02, Subpictures: 00
Title: 02, Length: 00:18:55.130 Chapters: 01, Cells: 01, Audio streams:
01, Subpictures: 00
Title: 03, Length: 00:09:05.330 Chapters: 01, Cells: 01, Audio streams:
01, Subpictures: 00
Longest track: 01
---
PS: /tmp/freevo/xine-stdout.log reports usage info as if invalid
parameters were passed to it:
Usage: xine [OPTIONS]... [MRL]
----------------------------------------------------------------------
Comment By: Duncan Webb (duncanwebb)
Date: 2006-12-26 10:46
Message:
Logged In: YES
user_id=104395
Originator: NO
Can you provide a little more information, the back trace helps but
doesn't say what steps are needed to reproduce the problem.
This looks like a kaa medata problem, but I'm not sure.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=446895&aid=1622266&group_id=46652
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Freevo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-devel