From 1549a246460020179f102254cdd5ed04f57ae9b4 Mon Sep 17 00:00:00 2001 From: Nam Vu Date: Mon, 14 Oct 2024 09:50:51 +0200 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Sebastian Poxhofer --- lib/modules/manager/pep621/processors/uv.ts | 5 ++--- lib/modules/manager/pep621/schema.ts | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/modules/manager/pep621/processors/uv.ts b/lib/modules/manager/pep621/processors/uv.ts index 6f811d27b8b692..d981d3fe265dda 100644 --- a/lib/modules/manager/pep621/processors/uv.ts +++ b/lib/modules/manager/pep621/processors/uv.ts @@ -182,12 +182,11 @@ export class UvProcessor implements PyProjectProcessor { function applyGitSource( dep: PackageDependency, - depSource: z.infer, + depSource: UvGitSource, ): void { const { git, rev, tag, branch } = depSource; if (tag) { - const { source, owner, name } = parseGitUrl(git); - const repo = `${owner}/${name}`; + const { source, full_name: repo } = parseGitUrl(git); if (source === 'github.com') { dep.datasource = GithubTagsDatasource.id; dep.packageName = repo; diff --git a/lib/modules/manager/pep621/schema.ts b/lib/modules/manager/pep621/schema.ts index 5bdd5585b61410..bbc6002fa65e3b 100644 --- a/lib/modules/manager/pep621/schema.ts +++ b/lib/modules/manager/pep621/schema.ts @@ -41,6 +41,7 @@ export const UvGitSource = z.object({ tag: z.string().optional(), branch: z.string().optional(), }); +export type UvGitSource = z.infer const UvUrlSource = z.object({ url: z.string(),