From b0dd17adcf0c5322afe7992ca82a19dc1af6a78d Mon Sep 17 00:00:00 2001 From: Brennan Magee Date: Wed, 7 Jul 2021 14:55:15 +0100 Subject: [PATCH 1/6] Use xtagctl to reset xcore-ai boards --- Jenkinsfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Jenkinsfile b/Jenkinsfile index 7ccc604..b871b38 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -90,6 +90,10 @@ pipeline { steps { sh '/XMOS/get_tools.py ' + params.TOOLS_VERSION installDependencies() + withVenv { + sh 'pip install git+git://github0.xmos.com/xmos-int/xtagctl.git@v1.3.1' + sh 'xtagctl reset_all XCORE-AI-EXPLORER' + } } } stage('xrun'){ From cf42ac96bbff6f2a82f95f65401cc97679f95fc6 Mon Sep 17 00:00:00 2001 From: Brennan Magee Date: Wed, 7 Jul 2021 15:40:05 +0100 Subject: [PATCH 2/6] Move xtagctl stuff into xrun stage --- Jenkinsfile | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index b871b38..e58bc19 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -90,25 +90,27 @@ pipeline { steps { sh '/XMOS/get_tools.py ' + params.TOOLS_VERSION installDependencies() - withVenv { - sh 'pip install git+git://github0.xmos.com/xmos-int/xtagctl.git@v1.3.1' - sh 'xtagctl reset_all XCORE-AI-EXPLORER' - } } } stage('xrun'){ steps{ toolsEnv(TOOLS_PATH) { // load xmos tools - //Run this and diff against expected output. Note we have the lib files here available - unstash 'debug_printf_test' - sh 'xrun --io --id 0 bin/xcoreai/debug_printf_test.xe &> debug_printf_test.txt' - sh 'cat debug_printf_test.txt && diff debug_printf_test.txt tests/test.expect' + withVenv { // activate virtualenv + //Install xtagctl and reset xtags + sh 'pip install git+git://github0.xmos.com/xmos-int/xtagctl.git@v1.3.1' + sh 'xtagctl reset_all XCORE-AI-EXPLORER' + + //Run this and diff against expected output. Note we have the lib files here available + unstash 'debug_printf_test' + sh 'xrun --io --id 0 bin/xcoreai/debug_printf_test.xe &> debug_printf_test.txt' + sh 'cat debug_printf_test.txt && diff debug_printf_test.txt tests/test.expect' - //Just run these and error on exception - unstash 'AN00239' - sh 'xrun --io --id 0 bin/xcoreai/AN00239.xe' - unstash 'app_debug_printf' - sh 'xrun --io --id 0 bin/xcoreai/app_debug_printf.xe' + //Just run these and error on exception + unstash 'AN00239' + sh 'xrun --io --id 0 bin/xcoreai/AN00239.xe' + unstash 'app_debug_printf' + sh 'xrun --io --id 0 bin/xcoreai/app_debug_printf.xe' + } } } } From 2ee6588c92f3422fd8dc5758c706b7c393e2f41c Mon Sep 17 00:00:00 2001 From: Brennan Magee Date: Thu, 8 Jul 2021 14:40:33 +0100 Subject: [PATCH 3/6] Update xcore.ai tools version to 15.0.5 this brings get_tools veersion in line ith that from tools_released --- Jenkinsfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index e58bc19..7e17b02 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -8,7 +8,7 @@ pipeline { parameters { string( name: 'TOOLS_VERSION', - defaultValue: '15.0.2', + defaultValue: '15.0.5', description: 'The tools version to build with (check /projects/tools/ReleasesTools/)' ) } @@ -83,7 +83,7 @@ pipeline { } environment { // '/XMOS/tools' from get_tools.py and rest from tools installers - TOOLS_PATH = "/XMOS/tools/${params.TOOLS_VERSION}/XMOS/xTIMEcomposer/${params.TOOLS_VERSION}" + TOOLS_PATH = "/XMOS/tools/${params.TOOLS_VERSION}/XMOS/XTC/${params.TOOLS_VERSION}" } stages{ stage('Install Dependencies') { From d575bd407a4fd0d993d5082cde10fc86448e810c Mon Sep 17 00:00:00 2001 From: Brennan Magee Date: Fri, 9 Jul 2021 09:32:57 +0100 Subject: [PATCH 4/6] Run xcore.ai block like previous This means using tools_released, xcorePrepareSandbox and checking out the whole viewfile --- Jenkinsfile | 59 ++++++++++++++++++++++------------------------------- 1 file changed, 24 insertions(+), 35 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 7e17b02..d8aa6ff 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -4,26 +4,18 @@ getApproval() pipeline { agent none - //Tools for AI verif stage. Tools for standard stage in view file - parameters { - string( - name: 'TOOLS_VERSION', - defaultValue: '15.0.5', - description: 'The tools version to build with (check /projects/tools/ReleasesTools/)' - ) + environment { + REPO = 'lib_logging' + VIEW = getViewName(REPO) + } + options { + skipDefaultCheckout() } stages { stage('Standard build and XS2 tests') { agent { label 'x86_64&&brew' } - environment { - REPO = 'lib_logging' - VIEW = getViewName(REPO) - } - options { - skipDefaultCheckout() - } stages{ stage('Get view') { steps { @@ -81,35 +73,32 @@ pipeline { agent { label 'xcore.ai-explorer' } - environment { - // '/XMOS/tools' from get_tools.py and rest from tools installers - TOOLS_PATH = "/XMOS/tools/${params.TOOLS_VERSION}/XMOS/XTC/${params.TOOLS_VERSION}" - } stages{ - stage('Install Dependencies') { + stage('Get view') { steps { - sh '/XMOS/get_tools.py ' + params.TOOLS_VERSION - installDependencies() + xcorePrepareSandbox("${VIEW}", "${REPO}") } } stage('xrun'){ steps{ - toolsEnv(TOOLS_PATH) { // load xmos tools - withVenv { // activate virtualenv - //Install xtagctl and reset xtags - sh 'pip install git+git://github0.xmos.com/xmos-int/xtagctl.git@v1.3.1' - sh 'xtagctl reset_all XCORE-AI-EXPLORER' + dir("{REPO}") { + viewEnv { // load xmos tools + withVenv { // activate virtualenv + //Install xtagctl and reset xtags + sh "pip install -e ${WORKSPACE}/xtagctl" + sh 'xtagctl reset_all XCORE-AI-EXPLORER' - //Run this and diff against expected output. Note we have the lib files here available - unstash 'debug_printf_test' - sh 'xrun --io --id 0 bin/xcoreai/debug_printf_test.xe &> debug_printf_test.txt' - sh 'cat debug_printf_test.txt && diff debug_printf_test.txt tests/test.expect' + //Run this and diff against expected output. Note we have the lib files here available + unstash 'debug_printf_test' + sh 'xrun --io --id 0 bin/xcoreai/debug_printf_test.xe &> debug_printf_test.txt' + sh 'cat debug_printf_test.txt && diff debug_printf_test.txt tests/test.expect' - //Just run these and error on exception - unstash 'AN00239' - sh 'xrun --io --id 0 bin/xcoreai/AN00239.xe' - unstash 'app_debug_printf' - sh 'xrun --io --id 0 bin/xcoreai/app_debug_printf.xe' + //Just run these and error on exception + unstash 'AN00239' + sh 'xrun --io --id 0 bin/xcoreai/AN00239.xe' + unstash 'app_debug_printf' + sh 'xrun --io --id 0 bin/xcoreai/app_debug_printf.xe' + } } } } From 4fa1f25010c1a6dd76c451103527cfc228b92eb6 Mon Sep 17 00:00:00 2001 From: Brennan Magee Date: Fri, 9 Jul 2021 10:28:40 +0100 Subject: [PATCH 5/6] Fix Jenkinsfile REPO variable --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index d8aa6ff..7a5aedb 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -81,7 +81,7 @@ pipeline { } stage('xrun'){ steps{ - dir("{REPO}") { + dir("${REPO}") { viewEnv { // load xmos tools withVenv { // activate virtualenv //Install xtagctl and reset xtags From e26b9d9152fb9234e399040961aed7c12b0a9be1 Mon Sep 17 00:00:00 2001 From: mbanth Date: Mon, 27 Sep 2021 17:42:34 +0100 Subject: [PATCH 6/6] Bump version to v3.1.1. --- CHANGELOG.rst | 5 +++++ lib_logging/module_build_info | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 6429bc9..c201ace 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -1,6 +1,11 @@ Logging change log ================== +3.1.1 +----- + + * CHANGED: Jenkinsfile used for CI + 3.1.0 ----- diff --git a/lib_logging/module_build_info b/lib_logging/module_build_info index 6d5b5b1..35d3625 100644 --- a/lib_logging/module_build_info +++ b/lib_logging/module_build_info @@ -1,4 +1,4 @@ -VERSION = 3.1.0 +VERSION = 3.1.1 DEPENDENT_MODULES =