ValueError when self.GetTrackAttr('__length') is 'None' in xldbus.py

Bug #606335 reported by ragnarok2040
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Exaile
Fix Released
Medium
Unassigned

Bug Description

I was getting a ValueError when using the command 'exaile -q' while listening to some shoutcast streams using Exaile v0.3.2.0.

It seems GetTrackAttr('__length') was returning 'None', which results in a ValueError since a string literal is being cast to a float in line 389 of xl/xldbus.py.

This seems to work pretty well and should work if other string literals are returned. I would make a proper patch, but I don't have a clean source to diff against.

Line 389 of xl/xldbus.py:
        try:
                length = float(self.GetTrackAttr('__length'))
                length = '%d:%02d' % (length // 60, length %60)
        except ValueError:
                length = self.GetTrackAttr('__length')

Related branches

Revision history for this message
reacocard (reacocard) wrote :

fixed trunk/3644 and 0.3.2.x/3438, thanks!

Changed in exaile:
importance: Undecided → Medium
milestone: none → 0.3.2.1
status: New → Fix Committed
reacocard (reacocard)
Changed in exaile:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.