diff mbox series

[2/2] CI: Make use of buildman requirements.txt

Message ID 20230426194436.1785433-2-trini@konsulko.com
State Superseded
Delegated to: Tom Rini
Headers show
Series [1/2] buildman: Create a requirements.txt file | expand

Commit Message

Tom Rini April 26, 2023, 7:44 p.m. UTC
Now that buildman has a requirements.txt file we need to make use of it.

Signed-off-by: Tom Rini <trini@konsulko.com>
---
 .azure-pipelines.yml | 3 +++
 .gitlab-ci.yml       | 4 ++++
 2 files changed, 7 insertions(+)

Comments

Simon Glass April 27, 2023, 4:25 p.m. UTC | #1
On Wed, 26 Apr 2023 at 13:45, Tom Rini <trini@konsulko.com> wrote:
>
> Now that buildman has a requirements.txt file we need to make use of it.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
>  .azure-pipelines.yml | 3 +++
>  .gitlab-ci.yml       | 4 ++++
>  2 files changed, 7 insertions(+)
>

Reviewed-by: Simon Glass <sjg@chromium.org>
Neha Malcom Francis May 3, 2023, 5:57 a.m. UTC | #2
Hi Tom

Thanks for these patches!

On 27/04/23 01:14, Tom Rini wrote:
> Now that buildman has a requirements.txt file we need to make use of it.
> 
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
>   .azure-pipelines.yml | 3 +++
>   .gitlab-ci.yml       | 4 ++++
>   2 files changed, 7 insertions(+)
> 

However, while trying to ensure CI/CD coverage, I'm running into this " 
error 'No module named 'jsonschema'" for am62ax [1], any idea why after 
building successfully for other devices?


[1] 
https://dev.azure.com/u-boot/u-boot/_build/results?buildId=6236&view=logs&jobId=6fe7c803-7a3b-5b46-f057-c1c62fd89ba1&j=22dc4ac5-ae35-5978-08ac-5f386151834e&t=fae48c67-4bb5-5f06-119f-00d23f780e3c
Tom Rini May 3, 2023, 1:04 p.m. UTC | #3
On Wed, May 03, 2023 at 11:27:20AM +0530, Neha Malcom Francis wrote:
> Hi Tom
> 
> Thanks for these patches!
> 
> On 27/04/23 01:14, Tom Rini wrote:
> > Now that buildman has a requirements.txt file we need to make use of it.
> > 
> > Signed-off-by: Tom Rini <trini@konsulko.com>
> > ---
> >   .azure-pipelines.yml | 3 +++
> >   .gitlab-ci.yml       | 4 ++++
> >   2 files changed, 7 insertions(+)
> > 
> 
> However, while trying to ensure CI/CD coverage, I'm running into this "
> error 'No module named 'jsonschema'" for am62ax [1], any idea why after
> building successfully for other devices?
> 
> 
> [1] https://dev.azure.com/u-boot/u-boot/_build/results?buildId=6236&view=logs&jobId=6fe7c803-7a3b-5b46-f057-c1c62fd89ba1&j=22dc4ac5-ae35-5978-08ac-5f386151834e&t=fae48c67-4bb5-5f06-119f-00d23f780e3c
o

We need to have the requirements.txt file installed in any job that's
using this part of binman now and I guess my patch above wasn't
complete? I didn't fully check what happened on Azure due to the other
problems (ie iot2050 boards not building).
Neha Malcom Francis May 4, 2023, 4:12 a.m. UTC | #4
Hi Tom,

On 03/05/23 18:34, Tom Rini wrote:
> On Wed, May 03, 2023 at 11:27:20AM +0530, Neha Malcom Francis wrote:
>> Hi Tom
>>
>> Thanks for these patches!
>>
>> On 27/04/23 01:14, Tom Rini wrote:
>>> Now that buildman has a requirements.txt file we need to make use of it.
>>>
>>> Signed-off-by: Tom Rini <trini@konsulko.com>
>>> ---
>>>    .azure-pipelines.yml | 3 +++
>>>    .gitlab-ci.yml       | 4 ++++
>>>    2 files changed, 7 insertions(+)
>>>
>>
>> However, while trying to ensure CI/CD coverage, I'm running into this "
>> error 'No module named 'jsonschema'" for am62ax [1], any idea why after
>> building successfully for other devices?
>>
>>
>> [1] https://dev.azure.com/u-boot/u-boot/_build/results?buildId=6236&view=logs&jobId=6fe7c803-7a3b-5b46-f057-c1c62fd89ba1&j=22dc4ac5-ae35-5978-08ac-5f386151834e&t=fae48c67-4bb5-5f06-119f-00d23f780e3c
> o
> 
> We need to have the requirements.txt file installed in any job that's
> using this part of binman now and I guess my patch above wasn't
> complete? I didn't fully check what happened on Azure due to the other
> problems (ie iot2050 boards not building).
> 

Probably, I'm not sure about how to rectify this. Could you have a look 
if possible? Regarding iot2050, I have started working on it.
Tom Rini May 4, 2023, 1:02 p.m. UTC | #5
On Thu, May 04, 2023 at 09:42:54AM +0530, Neha Malcom Francis wrote:
> Hi Tom,
> 
> On 03/05/23 18:34, Tom Rini wrote:
> > On Wed, May 03, 2023 at 11:27:20AM +0530, Neha Malcom Francis wrote:
> > > Hi Tom
> > > 
> > > Thanks for these patches!
> > > 
> > > On 27/04/23 01:14, Tom Rini wrote:
> > > > Now that buildman has a requirements.txt file we need to make use of it.
> > > > 
> > > > Signed-off-by: Tom Rini <trini@konsulko.com>
> > > > ---
> > > >    .azure-pipelines.yml | 3 +++
> > > >    .gitlab-ci.yml       | 4 ++++
> > > >    2 files changed, 7 insertions(+)
> > > > 
> > > 
> > > However, while trying to ensure CI/CD coverage, I'm running into this "
> > > error 'No module named 'jsonschema'" for am62ax [1], any idea why after
> > > building successfully for other devices?
> > > 
> > > 
> > > [1] https://dev.azure.com/u-boot/u-boot/_build/results?buildId=6236&view=logs&jobId=6fe7c803-7a3b-5b46-f057-c1c62fd89ba1&j=22dc4ac5-ae35-5978-08ac-5f386151834e&t=fae48c67-4bb5-5f06-119f-00d23f780e3c
> > o
> > 
> > We need to have the requirements.txt file installed in any job that's
> > using this part of binman now and I guess my patch above wasn't
> > complete? I didn't fully check what happened on Azure due to the other
> > problems (ie iot2050 boards not building).
> > 
> 
> Probably, I'm not sure about how to rectify this. Could you have a look if
> possible? Regarding iot2050, I have started working on it.

I see it now.  The "script" section at the bottom of
.azure-pipelines.yml needs the pip install as well, I had missed that.
Go ahead and take that up with your reposting of the series :)
Neha Malcom Francis May 5, 2023, 5:02 a.m. UTC | #6
Hi Tom

On 04/05/23 18:32, Tom Rini wrote:
> On Thu, May 04, 2023 at 09:42:54AM +0530, Neha Malcom Francis wrote:
>> Hi Tom,
>>
>> On 03/05/23 18:34, Tom Rini wrote:
>>> On Wed, May 03, 2023 at 11:27:20AM +0530, Neha Malcom Francis wrote:
>>>> Hi Tom
>>>>
>>>> Thanks for these patches!
>>>>
>>>> On 27/04/23 01:14, Tom Rini wrote:
>>>>> Now that buildman has a requirements.txt file we need to make use of it.
>>>>>
>>>>> Signed-off-by: Tom Rini <trini@konsulko.com>
>>>>> ---
>>>>>     .azure-pipelines.yml | 3 +++
>>>>>     .gitlab-ci.yml       | 4 ++++
>>>>>     2 files changed, 7 insertions(+)
>>>>>
>>>>
>>>> However, while trying to ensure CI/CD coverage, I'm running into this "
>>>> error 'No module named 'jsonschema'" for am62ax [1], any idea why after
>>>> building successfully for other devices?
>>>>
>>>>
>>>> [1] https://dev.azure.com/u-boot/u-boot/_build/results?buildId=6236&view=logs&jobId=6fe7c803-7a3b-5b46-f057-c1c62fd89ba1&j=22dc4ac5-ae35-5978-08ac-5f386151834e&t=fae48c67-4bb5-5f06-119f-00d23f780e3c
>>> o
>>>
>>> We need to have the requirements.txt file installed in any job that's
>>> using this part of binman now and I guess my patch above wasn't
>>> complete? I didn't fully check what happened on Azure due to the other
>>> problems (ie iot2050 boards not building).
>>>
>>
>> Probably, I'm not sure about how to rectify this. Could you have a look if
>> possible? Regarding iot2050, I have started working on it.
> 
> I see it now.  The "script" section at the bottom of
> .azure-pipelines.yml needs the pip install as well, I had missed that.
> Go ahead and take that up with your reposting of the series :)
> 

Thanks for catching that! Will add it in
diff mbox series

Patch

diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml
index 76ffdeebd667..22d634f4aa7a 100644
--- a/.azure-pipelines.yml
+++ b/.azure-pipelines.yml
@@ -162,6 +162,7 @@  stages:
           virtualenv -p /usr/bin/python3 /tmp/venv
           . /tmp/venv/bin/activate
           pip install -r test/py/requirements.txt
+          pip install -r tools/buildman/requirements.txt
           export UBOOT_TRAVIS_BUILD_DIR=/tmp/sandbox_spl
           export PYTHONPATH=${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc/pylibfdt
           export PATH=${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc:${PATH}
@@ -209,6 +210,7 @@  stages:
           git config --global --add safe.directory $(work_dir)
           export USER=azure
           pip install -r test/py/requirements.txt
+          pip install -r tools/buildman/requirements.txt
           pip install asteval pylint==2.12.2 pyopenssl
           export PATH=${PATH}:~/.local/bin
           echo "[MASTER]" >> .pylintrc
@@ -404,6 +406,7 @@  stages:
           if [ -n "${BUILD_ENV}" ]; then
               export ${BUILD_ENV};
           fi
+          pip install -r tools/buildman/requirements.txt
           tools/buildman/buildman -o ${UBOOT_TRAVIS_BUILD_DIR} -w -E -W -e --board ${TEST_PY_BD} ${OVERRIDE}
           cp ~/grub_x86.efi ${UBOOT_TRAVIS_BUILD_DIR}/
           cp ~/grub_x64.efi ${UBOOT_TRAVIS_BUILD_DIR}/
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index b193fee98f86..22ed61be642a 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -97,6 +97,7 @@  build all 32bit ARM platforms:
   script:
     - ret=0;
       git config --global --add safe.directory "${CI_PROJECT_DIR}";
+      pip install -r tools/buildman/requirements.txt;
       ./tools/buildman/buildman -o /tmp -PEWM arm -x aarch64 || ret=$?;
       if [[ $ret -ne 0 ]]; then
         ./tools/buildman/buildman -o /tmp -seP;
@@ -110,6 +111,7 @@  build all 64bit ARM platforms:
     - . /tmp/venv/bin/activate
     - ret=0;
       git config --global --add safe.directory "${CI_PROJECT_DIR}";
+      pip install -r tools/buildman/requirements.txt;
       ./tools/buildman/buildman -o /tmp -PEWM aarch64 || ret=$?;
       if [[ $ret -ne 0 ]]; then
         ./tools/buildman/buildman -o /tmp -seP;
@@ -208,6 +210,7 @@  Run binman, buildman, dtoc, Kconfig and patman testsuites:
       virtualenv -p /usr/bin/python3 /tmp/venv;
       . /tmp/venv/bin/activate;
       pip install -r test/py/requirements.txt;
+      pip install -r tools/buildman/requirements.txt;
       export UBOOT_TRAVIS_BUILD_DIR=/tmp/sandbox_spl;
       export PYTHONPATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc/pylibfdt";
       export PATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc:${PATH}";
@@ -240,6 +243,7 @@  Run pylint:
   script:
     - git config --global --add safe.directory "${CI_PROJECT_DIR}"
     - pip install -r test/py/requirements.txt
+    - pip install -r tools/buildman/requirements.txt
     - pip install asteval pylint==2.12.2 pyopenssl
     - export PATH=${PATH}:~/.local/bin
     - echo "[MASTER]" >> .pylintrc