mycroft-core: AttributeError: 'module' object has no attribute 'SSL_ST_INIT'

When installing mycroft-core from the AUR I get the following error when attempting to start the service.

systemctl --user status mycroft-service.service mycroft-skills.service mycroft-voice.service
● mycroft-service.service - Mycroft main service
   Loaded: loaded (/usr/lib/systemd/user/mycroft-service.service; disabled; vendor preset: enabled)
   Active: active (running) since Wed 2017-04-26 03:05:26 EDT; 49s ago
 Main PID: 14053 (bash)
   CGroup: /user.slice/user-1000.slice/user@1000.service/mycroft-service.service
           ├─14053 bash /usr/share/mycroft-core/start.sh service
           └─14068 python /usr/share/mycroft-core/mycroft/messagebus/service/main.py

Apr 26 03:05:26 $HOSTNAME systemd[1193]: Started Mycroft main service.
Apr 26 03:05:26 $HOSTNAME bash[14053]: Starting service
Apr 26 03:05:26 $HOSTNAME bash[14053]: 2017-04-26 03:05:26,395 - mycroft.configuration - WARNING - Failed to fetch remote configuration: AttributeError("'module' object has no attribute 'SSL_ST_INIT'",)

● mycroft-skills.service - Mycroft skills provider
   Loaded: loaded (/usr/lib/systemd/user/mycroft-skills.service; disabled; vendor preset: enabled)
   Active: active (running) since Tue 2017-04-25 21:52:28 EDT; 5h 13min ago
 Main PID: 2292 (bash)
   CGroup: /user.slice/user-1000.slice/user@1000.service/mycroft-skills.service
           ├─2292 bash /usr/share/mycroft-core/start.sh skills
           └─2318 python /usr/share/mycroft-core/mycroft/skills/main.py

Apr 26 03:01:21 $HOSTNAME bash[2292]: 2017-04-26 03:01:21,762 - mycroft.messagebus.client.ws - WARNING - WS Client will reconnect in 60 seconds.
Apr 26 03:02:21 $HOSTNAME bash[2292]: 2017-04-26 03:02:21,813 - mycroft.messagebus.client.ws - ERROR - Exception("Uncaught 'error' event.",)
Apr 26 03:02:21 $HOSTNAME bash[2292]: 2017-04-26 03:02:21,814 - mycroft.messagebus.client.ws - WARNING - WS Client will reconnect in 60 seconds.
Apr 26 03:03:21 $HOSTNAME bash[2292]: 2017-04-26 03:03:21,870 - mycroft.messagebus.client.ws - ERROR - Exception("Uncaught 'error' event.",)
Apr 26 03:03:21 $HOSTNAME bash[2292]: 2017-04-26 03:03:21,870 - mycroft.messagebus.client.ws - WARNING - WS Client will reconnect in 60 seconds.
Apr 26 03:04:21 $HOSTNAME bash[2292]: 2017-04-26 03:04:21,907 - mycroft.messagebus.client.ws - ERROR - Exception("Uncaught 'error' event.",)
Apr 26 03:04:21 $HOSTNAME bash[2292]: 2017-04-26 03:04:21,907 - mycroft.messagebus.client.ws - WARNING - WS Client will reconnect in 60 seconds.
Apr 26 03:05:21 $HOSTNAME bash[2292]: 2017-04-26 03:05:21,956 - mycroft.messagebus.client.ws - ERROR - Exception("Uncaught 'error' event.",)
Apr 26 03:05:21 $HOSTNAME bash[2292]: 2017-04-26 03:05:21,956 - mycroft.messagebus.client.ws - WARNING - WS Client will reconnect in 60 seconds.
Apr 26 03:05:36 $HOSTNAME systemd[1193]: [/usr/lib/systemd/user/mycroft-skills.service:3] Failed to add dependency on mycroft-service, ignoring: Invalid argument

● mycroft-voice.service - Mycroft voice processing
   Loaded: loaded (/usr/lib/systemd/user/mycroft-voice.service; disabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Wed 2017-04-26 03:05:38 EDT; 37s ago
  Process: 14083 ExecStart=/bin/bash -c source /usr/share/mycroft-core/.virtualenvs/mycroft/bin/activate && /usr/share/mycroft-core/start.sh voice (code=exited, status=1/FAILURE)
 Main PID: 14083 (code=exited, status=1/FAILURE)

Apr 26 03:05:38 $HOSTNAME bash[14083]:   File "/home/$USER/.virtualenvs/mycroft/lib/python2.7/site-packages/requests/packages/urllib3/contrib/pyopenssl.py", line 47, in <module>
Apr 26 03:05:38 $HOSTNAME bash[14083]:     import OpenSSL.SSL
Apr 26 03:05:38 $HOSTNAME bash[14083]:   File "/home/$USER/.virtualenvs/mycroft/lib/python2.7/site-packages/OpenSSL/__init__.py", line 8, in <module>
Apr 26 03:05:38 $HOSTNAME bash[14083]:     from OpenSSL import rand, crypto, SSL
Apr 26 03:05:38 $HOSTNAME bash[14083]:   File "/home/$USER/.virtualenvs/mycroft/lib/python2.7/site-packages/OpenSSL/SSL.py", line 124, in <module>
Apr 26 03:05:38 $HOSTNAME bash[14083]:     SSL_ST_INIT = _lib.SSL_ST_INIT
Apr 26 03:05:38 $HOSTNAME bash[14083]: AttributeError: 'module' object has no attribute 'SSL_ST_INIT'
Apr 26 03:05:38 $HOSTNAME systemd[1193]: mycroft-voice.service: Main process exited, code=exited, status=1/FAILURE
Apr 26 03:05:38 $HOSTNAME systemd[1193]: mycroft-voice.service: Unit entered failed state.
Apr 26 03:05:38 $HOSTNAME systemd[1193]: mycroft-voice.service: Failed with result 'exit-code'.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 18

Commits related to this issue

Most upvoted comments

You need to reinstall the pip package after the change.

pip uninstall pyOpenSSL pip install pyOpenSSL==16.2.0

Also what OS are you on?

Upgrading pyOpenSSL to 16.2.0 fixed my issue. pip uninstall pyOpenSSL pip install pyOpenSSL==16.2.0