ovirt-engine-cli job fails

Hi, Can you take a look on this job [1] ? Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build) [1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/ - Kiril

On 04/30/2013 01:02 PM, Kiril Nesenko wrote:
Hi, Can you take a look on this job [1] ?
Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build)
[1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/
- Kiril
I think that the CLI .spec needs something like this: diff --git a/ovirt-engine-cli.spec.in b/ovirt-engine-cli.spec.in index badfa8d..ca78590 100644 --- a/ovirt-engine-cli.spec.in +++ b/ovirt-engine-cli.spec.in @@ -11,6 +11,7 @@ BuildRequires: python2-devel BuildRequires: python-setuptools-devel BuildRequires: python-ply BuildRequires: python-kitchen +BuildRequires: ovirt-engine-sdk >= 3.2.0.3 BuildArch: noarch And then the ovirt-engine-cli package needs to be installed in the machines that run the jobs. -- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.

On 04/30/2013 02:04 PM, Juan Hernandez wrote:
On 04/30/2013 01:02 PM, Kiril Nesenko wrote:
Hi, Can you take a look on this job [1] ?
Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build)
[1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/
- Kiril
I think that the CLI .spec needs something like this:
diff --git a/ovirt-engine-cli.spec.in b/ovirt-engine-cli.spec.in index badfa8d..ca78590 100644 --- a/ovirt-engine-cli.spec.in +++ b/ovirt-engine-cli.spec.in @@ -11,6 +11,7 @@ BuildRequires: python2-devel BuildRequires: python-setuptools-devel BuildRequires: python-ply BuildRequires: python-kitchen +BuildRequires: ovirt-engine-sdk >= 3.2.0.3
the spec already has this, also there is no change been done in this area.
BuildArch: noarch
And then the ovirt-engine-cli package needs to be installed in the machines that run the jobs.
not sure about this, afaiu this job only builds rpms, Kiril, how do you trigger rpm build? and what you do afterwords? (i cannot reproduce this on my f17)
-- Michael Pasternak RedHat, ENG-Virtualization R&D

----- Original Message -----
From: "Michael Pasternak" <mpastern@redhat.com> To: "Juan Hernandez" <jhernand@redhat.com> Cc: "Ori Liel" <oliel@redhat.com>, "Kiril Nesenko" <kiril@redhat.com>, "infra" <infra@ovirt.org> Sent: Tuesday, April 30, 2013 2:36:41 PM Subject: Re: ovirt-engine-cli job fails
On 04/30/2013 02:04 PM, Juan Hernandez wrote:
On 04/30/2013 01:02 PM, Kiril Nesenko wrote:
Hi, Can you take a look on this job [1] ?
Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build)
[1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/
- Kiril
I think that the CLI .spec needs something like this:
diff --git a/ovirt-engine-cli.spec.in b/ovirt-engine-cli.spec.in index badfa8d..ca78590 100644 --- a/ovirt-engine-cli.spec.in +++ b/ovirt-engine-cli.spec.in @@ -11,6 +11,7 @@ BuildRequires: python2-devel BuildRequires: python-setuptools-devel BuildRequires: python-ply BuildRequires: python-kitchen +BuildRequires: ovirt-engine-sdk >= 3.2.0.3
the spec already has this, also there is no change been done in this area.
BuildArch: noarch
And then the ovirt-engine-cli package needs to be installed in the machines that run the jobs.
not sure about this, afaiu this job only builds rpms, Kiril, how do you trigger rpm build? and what you do afterwords? (i cannot reproduce this on my f17)
the job triggers on each commit, these are the changes that the build failed after thier commit: cli: recognize AmbiguousQueryError as COMMAND_ERROR (detail) cli: normalize sdk errors (detail) cli: remove pexpect dependency (detail) cli: do not use preserved "type" as param name (detail) cli: datetime.datetime object has no attribute __dict__ #957519 (detail) job runs: RPMS_DIR=$WORKSPACE/rpms/ TAR_DIR=$WORKSPACE/tarball ### cleanup #### rm -rf rpmtop || /bin/true rm -rf $RPMS_DIR || /bin/true rm -rf ${WORKSPACE}/tarball/*.tar.gz mkdir -p $RPMS_DIR $TAR_DIR git_head=$(git log -1 --pretty=format:%h) GIT_RELEASE=$(date --utc +%Y%m%d).git${git_head} make rpmrelease=1.${GIT_RELEASE} rpm mv rpmtop/RPMS/noarch/*.rpm $RPMS_DIR mv rpmtop/SRPMS/*.rpm $RPMS_DIR mv *.tar.gz $TAR_DIR
--
Michael Pasternak RedHat, ENG-Virtualization R&D _______________________________________________ Infra mailing list Infra@ovirt.org http://lists.ovirt.org/mailman/listinfo/infra

On 04/30/2013 02:49 PM, Eyal Edri wrote:
----- Original Message -----
From: "Michael Pasternak" <mpastern@redhat.com> To: "Juan Hernandez" <jhernand@redhat.com> Cc: "Ori Liel" <oliel@redhat.com>, "Kiril Nesenko" <kiril@redhat.com>, "infra" <infra@ovirt.org> Sent: Tuesday, April 30, 2013 2:36:41 PM Subject: Re: ovirt-engine-cli job fails
On 04/30/2013 02:04 PM, Juan Hernandez wrote:
On 04/30/2013 01:02 PM, Kiril Nesenko wrote:
Hi, Can you take a look on this job [1] ?
Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build)
[1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/
- Kiril
I think that the CLI .spec needs something like this:
diff --git a/ovirt-engine-cli.spec.in b/ovirt-engine-cli.spec.in index badfa8d..ca78590 100644 --- a/ovirt-engine-cli.spec.in +++ b/ovirt-engine-cli.spec.in @@ -11,6 +11,7 @@ BuildRequires: python2-devel BuildRequires: python-setuptools-devel BuildRequires: python-ply BuildRequires: python-kitchen +BuildRequires: ovirt-engine-sdk >= 3.2.0.3
the spec already has this, also there is no change been done in this area.
BuildArch: noarch
And then the ovirt-engine-cli package needs to be installed in the machines that run the jobs.
not sure about this, afaiu this job only builds rpms, Kiril, how do you trigger rpm build? and what you do afterwords? (i cannot reproduce this on my f17)
the job triggers on each commit,
these are the changes that the build failed after thier commit: cli: recognize AmbiguousQueryError as COMMAND_ERROR (detail) cli: normalize sdk errors (detail) cli: remove pexpect dependency (detail) cli: do not use preserved "type" as param name (detail) cli: datetime.datetime object has no attribute __dict__ #957519 (detail)
job runs:
RPMS_DIR=$WORKSPACE/rpms/ TAR_DIR=$WORKSPACE/tarball
### cleanup #### rm -rf rpmtop || /bin/true rm -rf $RPMS_DIR || /bin/true rm -rf ${WORKSPACE}/tarball/*.tar.gz mkdir -p $RPMS_DIR $TAR_DIR git_head=$(git log -1 --pretty=format:%h) GIT_RELEASE=$(date --utc +%Y%m%d).git${git_head}
make rpmrelease=1.${GIT_RELEASE} rpm mv rpmtop/RPMS/noarch/*.rpm $RPMS_DIR mv rpmtop/SRPMS/*.rpm $RPMS_DIR mv *.tar.gz $TAR_DIR
works for me, from the logs looks like [1] is triggers "cli/__init__.py without sdk been installed, i think you accidentally trying to import (ovirt) cli.parser instead of some other module. [1] /usr/bin/python -c 'import cli.parser; parser = cli.parser.Parser(); parser._write_tables()'
--
Michael Pasternak RedHat, ENG-Virtualization R&D _______________________________________________ Infra mailing list Infra@ovirt.org http://lists.ovirt.org/mailman/listinfo/infra
-- Michael Pasternak RedHat, ENG-Virtualization R&D

On 04/30/2013 03:03 PM, Michael Pasternak wrote:
[1] /usr/bin/python -c 'import cli.parser; parser = cli.parser.Parser(); parser._write_tables()'
found the problem, here is the fix. http://gerrit.ovirt.org/14343 -- Michael Pasternak RedHat, ENG-Virtualization R&D

On 04/30/2013 02:19 PM, Michael Pasternak wrote:
On 04/30/2013 03:03 PM, Michael Pasternak wrote:
[1] /usr/bin/python -c 'import cli.parser; parser = cli.parser.Parser(); parser._write_tables()'
found the problem, here is the fix.
Right, that solves the problem, at least in my environment. The alternative to install ovirt-engine-sdk also works. -- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.

On 04/30/2013 03:26 PM, Juan Hernandez wrote:
On 04/30/2013 02:19 PM, Michael Pasternak wrote:
On 04/30/2013 03:03 PM, Michael Pasternak wrote:
[1] /usr/bin/python -c 'import cli.parser; parser = cli.parser.Parser(); parser._write_tables()'
found the problem, here is the fix.
Right, that solves the problem, at least in my environment. The alternative to install ovirt-engine-sdk also works.
thanks a lot Juan.
-- Michael Pasternak RedHat, ENG-Virtualization R&D

On 04/30/2013 01:36 PM, Michael Pasternak wrote:
On 04/30/2013 02:04 PM, Juan Hernandez wrote:
On 04/30/2013 01:02 PM, Kiril Nesenko wrote:
Hi, Can you take a look on this job [1] ?
Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build)
[1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/
- Kiril
I think that the CLI .spec needs something like this:
diff --git a/ovirt-engine-cli.spec.in b/ovirt-engine-cli.spec.in index badfa8d..ca78590 100644 --- a/ovirt-engine-cli.spec.in +++ b/ovirt-engine-cli.spec.in @@ -11,6 +11,7 @@ BuildRequires: python2-devel BuildRequires: python-setuptools-devel BuildRequires: python-ply BuildRequires: python-kitchen +BuildRequires: ovirt-engine-sdk >= 3.2.0.3
the spec already has this, also there is no change been done in this area.
I am checking the latest upstream code, and it doesn't have the "BuildRequires", it does have the "Requires". I guess that we are running this jobs in a machine where ovirt-engine-sdk is not installed. The backtrace clearly complains about missing ovirtsdk.infrastructure.errors. Not sure why this happens now and not before, but it is worth testing: just install ovirt-engine-sdk in the Jenkins machine and try again.
BuildArch: noarch
And then the ovirt-engine-cli package needs to be installed in the machines that run the jobs.
not sure about this, afaiu this job only builds rpms, Kiril, how do you trigger rpm build? and what you do afterwords? (i cannot reproduce this on my f17)
-- Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta 3ºD, 28016 Madrid, Spain Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.

On 04/30/2013 02:57 PM, Juan Hernandez wrote:
On 04/30/2013 01:36 PM, Michael Pasternak wrote:
On 04/30/2013 02:04 PM, Juan Hernandez wrote:
On 04/30/2013 01:02 PM, Kiril Nesenko wrote:
Hi, Can you take a look on this job [1] ?
Traceback (most recent call last): File "<string>", line 1, in <module> File "cli/__init__.py", line 3, in <module> from cli.context import ExecutionContext File "cli/context.py", line 38, in <module> from ovirtsdk.infrastructure.errors import \ ImportError: No module named ovirtsdk.infrastructure.errors error: Bad exit status from /var/tmp/rpm-tmp.jEpk66 (%build)
[1] - http://jenkins.ovirt.org/job/ovirt-engine-cli_create_rpms/
- Kiril
I think that the CLI .spec needs something like this:
diff --git a/ovirt-engine-cli.spec.in b/ovirt-engine-cli.spec.in index badfa8d..ca78590 100644 --- a/ovirt-engine-cli.spec.in +++ b/ovirt-engine-cli.spec.in @@ -11,6 +11,7 @@ BuildRequires: python2-devel BuildRequires: python-setuptools-devel BuildRequires: python-ply BuildRequires: python-kitchen +BuildRequires: ovirt-engine-sdk >= 3.2.0.3
the spec already has this, also there is no change been done in this area.
I am checking the latest upstream code, and it doesn't have the "BuildRequires", it does have the "Requires". I guess that we are running this jobs in a machine where ovirt-engine-sdk is not installed.
right, i was talking about Requires [1], not BuildRequires (as we don't need sdk to build cli) [1] http://gerrit.ovirt.org/gitweb?p=ovirt-engine-cli.git;a=blob_plain;f=ovirt-e...
The backtrace clearly complains about missing ovirtsdk.infrastructure.errors. Not sure why this happens now and not before, but it is worth testing: just install ovirt-engine-sdk in the Jenkins machine and try again.
it's sounds like wrong import in script, please see my reply to Eyal on this.
BuildArch: noarch
And then the ovirt-engine-cli package needs to be installed in the machines that run the jobs.
not sure about this, afaiu this job only builds rpms, Kiril, how do you trigger rpm build? and what you do afterwords? (i cannot reproduce this on my f17)
-- Michael Pasternak RedHat, ENG-Virtualization R&D
participants (4)
-
Eyal Edri
-
Juan Hernandez
-
Kiril Nesenko
-
Michael Pasternak