Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Websites UFRPE
Wagtail Videos
Commits
fda4cb06
Commit
fda4cb06
authored
Jul 28, 2016
by
Seb
Browse files
try and find out why da failure
parent
79a7a588
Changes
1
Hide whitespace changes
Inline
Side-by-side
wagtailvideos/models.py
View file @
fda4cb06
...
...
@@ -115,7 +115,7 @@ class AbstractVideo(CollectionMember, TagSearchable):
file_path
=
self
.
file
.
path
try
:
show_format
=
subprocess
.
check_output
([
'ffprobe'
,
'-i'
,
file_path
,
'-show_format'
,
'-v'
,
'quiet'
])
show_format
=
subprocess
.
check_output
([
'ffprobe'
,
'-i'
,
file_path
,
'-show_format'
])
show_format
=
show_format
.
decode
(
"utf-8"
)
# show_format comes out in key=value pairs seperated by newlines
duration
=
re
.
findall
(
r
'([duration^=]+)=([^=]+)(?:\n|$)'
,
show_format
)[
0
][
1
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment