Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/root-ci-config/build_root.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
# the target branch in the ROOT repository using base_ref and head_ref:
# - The base_ref is e.g. "master" or "v6-38-00-patches"
# - The head_ref for PRs is formatted as <PR branch>:<Fork branch> e.g. "refs/pull/20742/head:cppyy_fixup"
if not ":" in args.head_ref:

Check failure on line 62 in .github/workflows/root-ci-config/build_root.py

View workflow job for this annotation

GitHub Actions / ruff

Ruff (E713)

.github/workflows/root-ci-config/build_root.py:62:16: E713 Test for membership should be `not in`

Check failure on line 62 in .github/workflows/root-ci-config/build_root.py

View workflow job for this annotation

GitHub Actions / ruff

Ruff (E713)

.github/workflows/root-ci-config/build_root.py:62:16: E713 Test for membership should be `not in`
build_utils.print_error(f"This has been identified as a PR build. However, the head-ref is {args.head_ref}.")
branch_in_fork = args.head_ref.split(":")[-1]
if branch_in_fork == args.base_ref:
Expand Down Expand Up @@ -270,7 +270,7 @@
""")
else:
returncode = subprocess_with_log(f"""
git clone --branch {branch} --single-branch {repository} "{targetdir}"
git clone --depth 1 --branch {branch} --single-branch {repository} "{targetdir}"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I ponder if 1 is the right number. If I remember correctly, we need some history to find the merging point between PR and the master in some circumstances.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe as a two-step process? If the search fails, then we clone fully?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is indeed what one can see in the incremental builds. I wonder whether it's an optimisation worth the complication in the code...

""")

if returncode == 0:
Expand Down
Loading