Skip to content
This repository was archived by the owner on Nov 9, 2020. It is now read-only.

Error when using run_module() - 'module' object has no attribute 'SSL_ST_INIT' #145

Description

@Xiol

Hi,

With a fresh install of 0.5.0 using pip (pip install column in a fresh virtualenv), I'm getting the error "'module' object has no attribute 'SSL_ST_INIT'" when attempting to use run_module().

In [1]: from column import APIRunner

In [2]: ar = APIRunner()

In [3]: ar.inventory_file

In [4]: ar.run_module('localhost', remote_user=None)

...snip...

/usr/lib/python2.7/dist-packages/OpenSSL/SSL.py in <module>()
    116 SSL_ST_ACCEPT = _lib.SSL_ST_ACCEPT
    117 SSL_ST_MASK = _lib.SSL_ST_MASK
--> 118 SSL_ST_INIT = _lib.SSL_ST_INIT
    119 SSL_ST_BEFORE = _lib.SSL_ST_BEFORE
    120 SSL_ST_OK = _lib.SSL_ST_OK

AttributeError: 'module' object has no attribute 'SSL_ST_INIT'

This seems to be down to me having an old version of PyOpenSSL installed system-wide, rather than as part of the virtualenv, and it's being imported somewhere.

Might be worth adding PyOpenSSL to your requirements.txt to avoid clashes with the system packages, if installed?

(My knowledge of how virtualenvs work and interact with system packages is limited, so this may very well be a feature rather than a bug.)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions