diff options
author | Gavin Mak <gavinmak@google.com> | 2025-04-10 18:09:41 +0000 |
---|---|---|
committer | LUCI <gerrit-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2025-04-10 11:30:42 -0700 |
commit | 97dc5c1bd9527c2abe2183b16a4b7ef037dc34a7 (patch) | |
tree | ebeb0137734d570eb5235e378d8ac0cbb19ce108 | |
parent | 0214730c9afaf732b3571f3f63416fea9f98a65c (diff) | |
download | git-repo-97dc5c1bd9527c2abe2183b16a4b7ef037dc34a7.tar.gz |
Some users are reporting a "curl: (26) .netrc error: no such file"
message on sync caused by an change to curl behavior.
See https://github.com/curl/curl/issues/16163.
Use --netrc-optional which was introduced in curl version 7.9.8
released in 2002.
Bug: 409354839
Change-Id: I8365c6e806968a4ee765a7e023b4bced30489c20
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/467026
Reviewed-by: Mike Frysinger <vapier@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Tested-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org>
-rw-r--r-- | project.py | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -2875,7 +2875,14 @@ class Project: | |||
2875 | 2875 | ||
2876 | # We do not use curl's --retry option since it generally doesn't | 2876 | # We do not use curl's --retry option since it generally doesn't |
2877 | # actually retry anything; code 18 for example, it will not retry on. | 2877 | # actually retry anything; code 18 for example, it will not retry on. |
2878 | cmd = ["curl", "--fail", "--output", tmpPath, "--netrc", "--location"] | 2878 | cmd = [ |
2879 | "curl", | ||
2880 | "--fail", | ||
2881 | "--output", | ||
2882 | tmpPath, | ||
2883 | "--netrc-optional", | ||
2884 | "--location", | ||
2885 | ] | ||
2879 | if quiet: | 2886 | if quiet: |
2880 | cmd += ["--silent", "--show-error"] | 2887 | cmd += ["--silent", "--show-error"] |
2881 | if os.path.exists(tmpPath): | 2888 | if os.path.exists(tmpPath): |