Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-video-pipeline
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-video-pipeline
Commits
25764205
Commit
25764205
authored
Jul 10, 2017
by
Gregory Martin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update val url handling
parent
b06c4005
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
24 deletions
+6
-24
control/veda_val.py
+6
-24
No files found.
control/veda_val.py
View file @
25764205
...
...
@@ -205,11 +205,12 @@ class VALAPICall():
if
self
.
val_status
!=
'invalid_token'
:
for
f
in
self
.
video_object
.
inst_class
.
local_storedir
.
split
(
','
):
if
f
.
strip
()
not
in
val_courses
:
val_courses
.
append
(
f
.
strip
()
)
val_courses
.
append
(
{
f
.
strip
():
None
}
)
for
g
in
self
.
video_proto
.
platform_course_url
:
if
g
.
strip
()
not
in
val_courses
:
val_courses
.
append
(
g
.
strip
())
if
len
(
val_courses
)
==
0
:
for
g
in
self
.
video_proto
.
platform_course_url
:
if
g
.
strip
()
not
in
val_courses
:
val_courses
.
append
({
g
.
strip
():
None
})
self
.
val_data
=
{
'client_video_id'
:
self
.
video_proto
.
client_title
,
...
...
@@ -237,7 +238,7 @@ class VALAPICall():
self
.
send_404
()
elif
r1
.
status_code
==
200
:
val_api_return
=
ast
.
literal_eval
(
r1
.
text
)
val_api_return
=
ast
.
literal_eval
(
r1
.
text
.
replace
(
'null'
,
'None'
)
)
self
.
send_200
(
val_api_return
)
"""
...
...
@@ -390,25 +391,6 @@ class VALAPICall():
def
main
():
pass
from
veda_utils
import
VideoProto
V1
=
VideoProto
()
V1
.
veda_id
=
'XXXC93BC2016-V000100'
V1
.
duration
=
'00:05:32.00'
V1
.
client_title
=
'ELEN7070_2016_S1_04_01.mp4'
V1
.
bitrate
=
'8718 kb/s'
V1
.
valid
=
False
V1
.
filesize
=
361804005
V1
.
platform_course_url
=
'test'
V1
.
s3_filename
=
'test'
V
=
VALAPICall
(
video_proto
=
V1
,
encode_profile
=
'mobile_high'
,
val_status
=
'duplicate'
,
endpoint_url
=
'DUPLICATE'
)
V
.
call
()
if
__name__
==
'__main__'
:
...
...
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