Bug 834249

Summary: rhts-test-env should require pyOpenSSL
Product: [Retired] Beaker Reporter: Ales Zelinka <azelinka>
Component: beahAssignee: Qixiang Wan <qwan>
Status: CLOSED CURRENTRELEASE QA Contact: Amit Saha <asaha>
Severity: medium Docs Contact:
Priority: medium    
Version: 0.8CC: asaha, bpeck, dcallagh, ebaak, llim, pkis, qwan, rmancy, stl
Target Milestone: 0.12   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: Misc
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-04-11 04:55:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ales Zelinka 2012-06-21 10:28:33 UTC
Description of problem:
I got this error when running task which contains rhts-submit-log call:

:: [06:22:53] :: [ INFO    ] :: Sending /tmp/logs.__.tar.gz as tmp-logs.__.tar.gz
Traceback (most recent call last):
  File "/usr/bin/rhts-submit-log", line 24, in <module>
    import rhts
  File "/usr/lib/python2.7/site-packages/rhts/__init__.py", line 17, in <module>
    import OpenSSL.SSL
ImportError: No module named OpenSSL.SSL

OpenSSL.SSL module comes from pyOpenSSL packge - rhts-test-env should require it.


Version-Release number of selected component (if applicable):
rhts-test-env-4.48-1.el7.noarch

Comment 1 Nick Coghlan 2012-10-17 04:37:55 UTC
Bulk reassignment of issues as Bill has moved to another team.

Comment 2 Dan Callaghan 2012-10-29 05:53:50 UTC
We don't ever use pyOpenSSL directly in the RHTS code, it's only imported so we can handle an exception type from it. We can probably just make the import conditional.

Comment 3 Dan Callaghan 2013-01-31 21:47:52 UTC
*** Bug 905948 has been marked as a duplicate of this bug. ***

Comment 4 Qixiang Wan 2013-02-01 03:24:35 UTC
I can see pyOpenSSL is installed by default on RHEL7 while running beaker jobs, so there should be not problem for depending on the OpenSSL.SSL module.

Hi Patrik,
Could you give the job's url which you encountered the issue?

Comment 5 Patrik Kis 2013-02-01 08:12:30 UTC
Actually I did not face this problem on beaker machine but on a virtual machine hosted on my PC. It is quite common to tune beaker test locally. We just need to install the right rhts*rpm and beaker*rpm packages and all used to work up to now.

Comment 6 Qixiang Wan 2013-02-01 08:44:47 UTC
(In reply to comment #5)
> Actually I did not face this problem on beaker machine but on a virtual
> machine hosted on my PC. It is quite common to tune beaker test locally. We
> just need to install the right rhts*rpm and beaker*rpm packages and all used
> to work up to now.

OK, I understand it now, thanks for your reply.
So we just need to add rpm dependency of pyOpenSSL for rhts.

Comment 7 Qixiang Wan 2013-02-01 08:59:52 UTC
on gerrit: http://gerrit.beaker-project.org/#/c/1685/

Comment 8 Patrik Kis 2013-02-01 09:50:26 UTC
(In reply to comment #6)
> (In reply to comment #5)
> > Actually I did not face this problem on beaker machine but on a virtual
> > machine hosted on my PC. It is quite common to tune beaker test locally. We
> > just need to install the right rhts*rpm and beaker*rpm packages and all used
> > to work up to now.
> 
> OK, I understand it now, thanks for your reply.
> So we just need to add rpm dependency of pyOpenSSL for rhts.

Yes, that should ensure that also on non-beaker machines all is installed properly.

Comment 9 Qixiang Wan 2013-02-04 02:43:04 UTC
patch re-post: http://gerrit.beaker-project.org/#/c/1686/

Comment 11 Amit Saha 2013-04-02 05:30:46 UTC
When pyOpenSSL is installed:

>>> rhts.ssl_error
<class 'OpenSSL.SSL.Error'>

And, when pyOpenSSL is not installed:

>>> rhts.ssl_error
<class 'ssl.SSLError'>

Comment 12 Dan Callaghan 2013-04-11 04:55:52 UTC
Beaker 0.12 has been released.