File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -91,7 +91,7 @@ def get_most_recent_course_archives(
9191 reversed ( # noqa: C413
9292 sorted (
9393 [
94- obj
94+ ( obj . key , obj . last_modified )
9595 for obj in bucket .objects .filter (
9696 # Use s3_prefix for OLL, "20" for all others
9797 Prefix = s3_prefix
@@ -100,17 +100,17 @@ def get_most_recent_course_archives(
100100 )
101101 if re .search (course_tar_regex , obj .key )
102102 ],
103- key = lambda obj : obj . last_modified ,
103+ key = lambda obj : obj [ 1 ] ,
104104 )
105105 )
106106 )
107107 if override_base_prefix :
108108 # More hoops to get desired result from OLL compared to other sources
109109 most_recent_export_date = "/" .join (
110- [s3_prefix , most_recent_export_file . key .lstrip (s3_prefix ).split ("/" )[0 ]]
110+ [s3_prefix , most_recent_export_file [ 0 ] .lstrip (s3_prefix ).split ("/" )[0 ]]
111111 )
112112 else :
113- most_recent_export_date = most_recent_export_file . key .split ("/" )[0 ]
113+ most_recent_export_date = most_recent_export_file [ 0 ] .split ("/" )[0 ]
114114 log .info ("Most recent export date is %s" , most_recent_export_date )
115115 return [
116116 obj .key
You can’t perform that action at this time.
0 commit comments