Skip to content
Snippets Groups Projects
Commit fc4f3694 authored by Guillaume Pernot's avatar Guillaume Pernot
Browse files

Added CI_ALLOW_FAILURE for cdash_handler.py

parent 3ac6903b
No related branches found
No related tags found
3 merge requests!758Release 7.2 integration into master,!648Ci rcjob,!630CI: Added CI_ALLOW_FAILURE for cdash_handler.py
......@@ -140,6 +140,9 @@ debian-build:
allow_failure: true
script:
- xvfb-run -a -n 1 -s "-screen 0 1024x768x24 -dpi 96" ctest -V -S CI/main_ci.cmake -DIMAGE_NAME:string=debian-unstable-gcc
after_script:
- export CI_ALLOW_FAILURE=ON
- python3 -u CI/cdash_handler.py
dependencies: []
## Ubuntu superbuild
......
......@@ -246,6 +246,9 @@ if __name__ == "__main__":
if ( len(sys.argv) < 6 and len(sys.argv) > 1 ):
print("Usage : "+sys.argv[0]+" commit_sha1 project_id project_directory token ref_name")
sys.exit(1)
allow_failure = os.environ.get('CI_ALLOW_FAILURE', False)
if ( len(sys.argv) >= 6):
sha1 = sys.argv[1]
proj = sys.argv[2]
......@@ -286,6 +289,10 @@ if __name__ == "__main__":
sys.exit(0)
gitlab_url = "https://gitlab.orfeo-toolbox.org/api/v4/projects/"
gitlab_url += proj + "/statuses/" + sha1
if allow_failure:
state = 'success'
params = urllib.parse.urlencode({'name':'cdash:' + handler.site , 'state': state ,\
'target_url' : cdash_url , 'description' : error , 'ref' : refn })
gitlab_request = urllib.request.Request(gitlab_url)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment