fixed # 修复工作流BUG

This commit is contained in:
2026-10-20 10:55:24 +08:00
parent 2761be6c3f
commit 6227fd4979
9 changed files with 60 additions and 33 deletions
-2
View File
@@ -55,8 +55,6 @@ def publish(package, confirmed=False, request=None):
repository = call("GET", "", None)
if not repository:
raise ValueError(f"Target repository is not accessible: {REPOSITORY}")
if repository.get("default_branch") == BRANCH:
raise ValueError("Preview must not be the repository default branch")
ref = call("GET", f"git/ref/heads/{BRANCH}", None)
parent = ref["object"]["sha"] if ref else None
if parent: