YAMJ / yamj-v2

Yet Another Movie Jukebox (YAMJ) v2
GNU General Public License v3.0
28 stars 11 forks source link

Invalid runtime in xml file #2770

Closed danielpaten closed 8 years ago

danielpaten commented 8 years ago

Hello, I try the last build and the problem persists (yamj-2.10-SNAPSHOT-2016-01-16-0120-1c8673a-bin)

The runtime information for some films is wrong in the generated xml file. For example yamj generate : <runtime source="MEDIAINFO">131h 42m</runtime> :-) And mediainfo give me : Duration : 2h 11mn It seems that the problem appears when time is > 2 hours (but I'm not sure of that)

danielpaten commented 8 years ago

Perhaps an idea to follow... For all the films with incorrect runtime, mediainfo display the duration with a real number with 6 zero after a dot. Duration : 4054466.000000 <== the problem ? Duration : 1h 7mn Duration : 1h 7mn 34s 466ms

And for other films Duration : 5405275 Duration : 1h 30mn

Edit : I create a file mediainfo.sh to remove the .000000

!/bin/bash

/usr/bin/mediainfo "$1" "$2" "$3" "$4" | sed -e 's/.000000//g'

And a link mediainfo to this file. Now the problem is gone.

modmax commented 8 years ago

Hi daniel, your assumption is correct. If a . is contained within the runtime string, then this is not correctly parsed.

I will fix this problem as soon as possible.