Skip to content

Commit 9c13209

Browse files
author
Trong Nhan Mai
committed
fix: use the correct analysis_id foreign key to map with Analaysis in the get latest component for purl select statement
1 parent 309c845 commit 9c13209

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/macaron/build_spec_generator/macaron_db_extractor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ def get_sql_stmt_latest_component_for_purl(purl: PackageURL) -> Select[tuple[Com
160160
.select_from(Component)
161161
.join(
162162
Analysis,
163-
onclause=Component.id == Analysis.id,
163+
onclause=Component.analysis_id == Analysis.id,
164164
)
165165
.where(Component.purl == purl.to_string())
166166
.order_by(

0 commit comments

Comments
 (0)