Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failure to install properly on brand new Ubuntu 20.04 server #16

Open
stevenmcastano opened this issue Feb 20, 2022 · 3 comments
Open

Comments

@stevenmcastano
Copy link

So I'm able to get certbot installed using pip, but the default version of python is 3.8.

So then when installing the powerdns plugin, the install runs, but I get the following error during the install:

ERROR: dns-lexicon 3.5.6 has requirement cryptography<4,>=2, but you'll have cryptography 36.0.1 which is incompatible.

Then certbot breaks completely and will not run anymore. Every time I try to run a certbot --text plugins or anything else for that matter, now I get the following error message:

An unexpected error occurred:
pkg_resources.ContextualVersionConflict: (cryptography 36.0.1 (/usr/local/lib/python3.8/dist-packages), Requirement.parse('cryptography<4,>=2'), {'dns-lexicon'})
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /tmp/tmpftmhu2z1/log or re-run Certbot with -v for more details.

I even tried manually install python 3.7, but that didn't seem to work either. I'm stuck here and not sure where to go next.

@stevenmcastano
Copy link
Author

Just for run I tried to install it under python 2.7 as well, but certbot is no longer compatible, that just gives me an error when I try to run it:

/usr/local/lib/python2.7/dist-packages/OpenSSL/crypto.py:14: CryptographyDeprecationWarning: Python 2 is no longer supported by the Python core team. Support for it is now deprecated in cryptography, and will be removed in the next release.
  from cryptography import utils, x509
Traceback (most recent call last):
  File "/usr/local/bin/certbot", line 5, in <module>
    from certbot.main import main
  File "/usr/local/lib/python2.7/dist-packages/certbot/main.py", line 2, in <module>
    from certbot._internal import main as internal_main
  File "/usr/local/lib/python2.7/dist-packages/certbot/_internal/main.py", line 22, in <module>
    from certbot._internal import cert_manager
  File "/usr/local/lib/python2.7/dist-packages/certbot/_internal/cert_manager.py", line 16, in <module>
    from certbot._internal import storage
  File "/usr/local/lib/python2.7/dist-packages/certbot/_internal/storage.py", line 83, in <module>
    def add_time_interval(base_time, interval, textparser=parsedatetime.Calendar()):
  File "/usr/local/lib/python2.7/dist-packages/parsedatetime/__init__.py", line 270, in __init__
    self.ptc = Constants()
  File "/usr/local/lib/python2.7/dist-packages/parsedatetime/__init__.py", line 2381, in __init__
    self.locale = get_icu(self.localeID)
  File "/usr/local/lib/python2.7/dist-packages/parsedatetime/pdt_locales/icu.py", line 56, in get_icu
    result['icu'] = icu = pyicu.Locale(locale)
AttributeError: 'module' object has no attribute 'Locale'

@viralpoetry
Copy link

hi @stevenmcastano sorry for a late response. We have internally moved to other dns provider and the previous maintainer also moved to another company...

Not sure if this description make sense, but colleague wrote me:

i found out that when we run this tasks [role-certbot : Installing certbot dns auth plugin from pypi] installing certbot-dns-powerdns==0.2.1
there is  ERROR: dns-lexicon 3.5.6 has requirement cryptography<4,>=2, but you'll have cryptography 36.0.0 which is incompatible.
then i install again:

pip install dns-lexicon

he made me downgrade of cryptography 36.0.0  to cryptography-3.4.8
after i run the role , everything was ok.

alternatively there should be more up-to-date version https://github.com/tmuncks/certbot-dns-powerdns

@mvforell
Copy link

mvforell commented Jul 3, 2022

Running pip install dns-lexicon downgraded cryptography to the right version for me, but then there was a new error because of pyopenssl. I was able to fix this by also running pip install pyopenssl==21.

For what it's worth, using tmuncks/certbot-dns-powerdns doesn't fix this issue for me. As far as I can tell, nothing has changed regarding the dependencies in that fork.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants