Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cubicweb
cube-doctor
Commits
c71da65e5d09
Commit
71ae7899
authored
Apr 17, 2021
by
Laurent Peuch
Browse files
fix(core): handle rare case where the repository is so broken than 'hg up' fails
parent
73226eb63be0
Changes
1
Show whitespace changes
Inline
Side-by-side
cube_doctor/__init__.py
View file @
c71da65e
...
...
@@ -423,10 +423,19 @@ class Command:
cube
,
repo
,
root_files
,
branches
,
other_args
)
while
True
:
try
:
repo
.
run_command
(
'hg up -C -r "last(public() and branch(default))"'
,
capture_output
=
True
,
)
except
Exception
:
import
traceback
traceback
.
print_exc
()
logger
.
error
(
"failed to 'hg up', the repository is probably broken, skip it"
)
return
try
:
# {"branch_name": ..., "commit_message": ...}
logger
.
info
(
f
"run modification command for
{
self
}
"
)
...
...
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