Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
95e55534
Unverified
Commit
95e55534
authored
Dec 29, 2021
by
Bogdan Lukin
Committed by
GitHub
Dec 29, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
retry curl without `--continue-at -` flag (#95629)
parent
6054eda8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
0 deletions
+15
-0
update_dart_sdk.sh
bin/internal/update_dart_sdk.sh
+15
-0
No files found.
bin/internal/update_dart_sdk.sh
View file @
95e55534
...
...
@@ -116,6 +116,21 @@ if [ ! -f "$ENGINE_STAMP" ] || [ "$ENGINE_VERSION" != `cat "$ENGINE_STAMP"` ]; t
fi
curl
${
verbose_curl
}
--retry
3
--continue-at
-
--location
--output
"
$DART_SDK_ZIP
"
"
$DART_SDK_URL
"
2>&1
||
{
curlExitCode
=
$?
# Handle range errors specially: retry again with disabled ranges (`--continue-at -` argument)
# When this could happen:
# - missing support of ranges in proxy servers
# - curl with broken handling of completed downloads
# This is not a proper fix, but doesn't require any user input
# - mirror of flutter storage without support of ranges
#
# 33 HTTP range error. The range "command" didn't work.
# https://man7.org/linux/man-pages/man1/curl.1.html#EXIT_CODES
if
[
$curlExitCode
!=
33
]
;
then
return
$curlExitCode
fi
curl
${
verbose_curl
}
--retry
3
--location
--output
"
$DART_SDK_ZIP
"
"
$DART_SDK_URL
"
2>&1
}
||
{
>
&2
echo
>
&2
echo
"Failed to retrieve the Dart SDK from:
$DART_SDK_URL
"
>
&2
echo
"If you're located in China, please see this page:"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment