Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
5
Merge Requests
5
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jérome Perrin
slapos
Commits
2cb191b3
Commit
2cb191b3
authored
Oct 04, 2023
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
theia retry downloads
parent
764bfc38
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
component/theia/generate_download_plugins_cfg.py
component/theia/generate_download_plugins_cfg.py
+11
-1
No files found.
component/theia/generate_download_plugins_cfg.py
View file @
2cb191b3
...
...
@@ -100,7 +100,17 @@ for plugin_and_version in '''\
api_url
=
f'https://open-vsx.org/api/
{
publisher
}
/
{
extension_name
}
/
{
version
}
'
logger
.
info
(
plugin_and_version
)
download_url
=
session
.
get
(
api_url
,
timeout
=
timeout
).
json
()[
'files'
][
'download'
]
retries
=
3
while
retries
:
try
:
download_url
=
session
.
get
(
api_url
,
timeout
=
timeout
).
json
()[
'files'
][
'download'
]
except
Exception
:
retries
=
retries
-
1
if
not
retries
:
raise
else
:
break
md5sum
=
hashlib
.
md5
(
session
.
get
(
download_url
,
timeout
=
timeout
).
content
).
hexdigest
()
urls
.
append
(
f'
{
publisher
}
-
{
extension_name
}
{
download_url
}
{
md5sum
}
'
)
...
...
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