Skip to content

Commit d6edec0

Browse files
committedSep 23, 2023
Add delay before querying base ref
This is another attempt to fix the 422 fast forward errors we've been getting.
1 parent ce600b9 commit d6edec0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed
 

‎homu/main.py

+5
Original file line numberDiff line numberDiff line change
@@ -912,6 +912,11 @@ def branch_equal_to_merge(git_cmd, state, branch):
912912

913913
def create_merge(state, repo_cfg, branch, logger, git_cfg,
914914
ensure_merge_equal=False):
915+
# Add some delay to try to make sure the base repo fetch is accurate.
916+
# It seems like in some cases we're getting the previous commit from GH,
917+
# e.g., see https://github.com/rust-lang/homu/issues/75#issuecomment-1729058969
918+
# Hopefully a delay helps.
919+
time.sleep(60)
915920
base_sha = state.get_repo().ref('heads/' + state.base_ref).object.sha
916921

917922
state.refresh()

0 commit comments

Comments
 (0)