File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -317,12 +317,20 @@ def parse_libyear_list(dependency_list):
317317 #print(dep)
318318 if dep [- 2 ] >= 0 :
319319 date = datetime .datetime .strptime (dep [- 1 ], '%Y-%m-%dT%H:%M:%S.%f' )
320+
321+ dep_dict = {
322+ "dep_name" : dep [- 3 ],
323+ "libyear_value" : dep [- 2 ],
324+ "libyear_date_last_updated" : date
325+ }
326+
327+ if len (dep ) > 3 :
328+ dep_dict ['repo_name' ] = dep [0 ]
329+ else :
330+ dep_dict ['repo_name' ] = ''
331+
320332 to_return .append (
321- {
322- "dep_name" : dep [- 3 ],
323- "libyear_value" : dep [- 2 ],
324- "libyear_date_last_updated" : date
325- }
333+ dep_dict
326334 )
327335
328336 #return list sorted by date
@@ -362,7 +370,10 @@ def generate_libyears_graph(oss_entity):
362370 #We are going to treat the y-axis as having one dep per level in the graph
363371 elevation = 0
364372 for dep in dep_list :
365- dateline .add (dep ["dep_name" ], [
373+
374+ label = f"{ dep ["dep_name" ]} /{ dep ["repo_name" ]} "
375+
376+ dateline .add (label , [
366377 (timedelta (), elevation ),
367378 (timedelta (days = dep ["libyear_value" ] * 365 ), elevation ),
368379 ])
You can’t perform that action at this time.
0 commit comments