[arch-commits] Commit in certbot/trunk (PKGBUILD certbot-lexicon-3.6.patch)

Felix Yan felixonmars at archlinux.org
Thu May 20 23:10:59 UTC 2021


    Date: Thursday, May 20, 2021 @ 23:10:58
  Author: felixonmars
Revision: 939670

upgpkg: certbot 1.15.0-2: add a patch to fix compatibility with dns-lexicon 3.6

Added:
  certbot/trunk/certbot-lexicon-3.6.patch
Modified:
  certbot/trunk/PKGBUILD

---------------------------+
 PKGBUILD                  |   18 ++++++----
 certbot-lexicon-3.6.patch |   76 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 88 insertions(+), 6 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-05-20 23:10:27 UTC (rev 939669)
+++ PKGBUILD	2021-05-20 23:10:58 UTC (rev 939670)
@@ -3,7 +3,7 @@
 
 pkgname=certbot
 pkgver=1.15.0
-pkgrel=1
+pkgrel=2
 pkgdesc="A tool to automatically receive and install X.509 certificates to enable TLS on servers. The client will interoperate with the Let’s Encrypt CA which will be issuing browser-trusted certificates for free."
 arch=('any')
 license=('Apache')
@@ -16,26 +16,32 @@
 optdepends=('certbot-apache: Apache plugin for Let’s Encrypt client'
             'certbot-nginx: Nginx plugin for Let’s Encrypt client')
 replaces=("letsencrypt")
-source=("https://pypi.io/packages/source/c/$pkgname/$pkgname-$pkgver.tar.gz"{,.asc})
+source=("https://pypi.io/packages/source/c/$pkgname/$pkgname-$pkgver.tar.gz"{,.asc}
+        $pkgname-lexicon-3.6.patch)
 validpgpkeys=('148C30F6F7E429337A72D992B00B9CC82D7ADF2C'
               '1B41B758F9A78C7F444C20FA3E5B4152E3ADB1FD'
               'A2CFB51FA275A7286234E7B24D17C995CD9775F2')
 sha512sums=('97307afdb795e1bb53c520b928081f3b7a3b4ec49c37a8306b015193e27c03c51771227bac0566a8bf5213675335b12132d8e1c23d49d86c4ff7c43216d6c15a'
-            'SKIP')
+            'SKIP'
+            'f6714b20a277d8e2369e48749ea33389b024d1dce0b257cb43d74acc469f11f6104169c59a342a6ec42df1198d9a6863bdf066183f989842397cf468a376d8cc')
 
+prepare() {
+  patch -d $pkgname-$pkgver -p2 < $pkgname-lexicon-3.6.patch
+}
+
 build() {
-  cd "$srcdir"/$pkgname-$pkgver
+  cd $pkgname-$pkgver
   export PYTHONHASHSEED=0
   python setup.py build
 }
 
 check() {
-  cd "$srcdir"/$pkgname-$pkgver
+  cd $pkgname-$pkgver
   python -m pytest
 }
 
 package() {
-  cd "$srcdir"/$pkgname-$pkgver
+  cd $pkgname-$pkgver
   python setup.py install --root="$pkgdir"
 
   mkdir -p "$pkgdir"/{etc,var/lib,var/log}/letsencrypt

Added: certbot-lexicon-3.6.patch
===================================================================
--- certbot-lexicon-3.6.patch	                        (rev 0)
+++ certbot-lexicon-3.6.patch	2021-05-20 23:10:58 UTC (rev 939670)
@@ -0,0 +1,76 @@
+From bc23e07ee5c144aa9b1d5cf9e0ba303d9e91a695 Mon Sep 17 00:00:00 2001
+From: Thomas G <t_glaessle at gmx.de>
+Date: Sun, 16 May 2021 15:03:53 +0200
+Subject: [PATCH] Fix incompatibility with lexicon >= v3.6.0 (#8819)
+
+---
+ certbot-dns-cloudxns/setup.py                      | 2 +-
+ certbot-dns-dnsimple/setup.py                      | 2 +-
+ certbot-dns-dnsmadeeasy/setup.py                   | 2 +-
+ certbot-dns-gehirn/setup.py                        | 2 +-
+ certbot-dns-linode/local-oldest-requirements.txt   | 1 -
+ certbot-dns-linode/setup.py                        | 2 +-
+ certbot-dns-luadns/setup.py                        | 2 +-
+ certbot-dns-nsone/setup.py                         | 2 +-
+ certbot-dns-ovh/local-oldest-requirements.txt      | 1 -
+ certbot-dns-ovh/setup.py                           | 2 +-
+ certbot-dns-sakuracloud/setup.py                   | 2 +-
+ certbot/CHANGELOG.md                               | 4 ++--
+ certbot/certbot/plugins/dns_common_lexicon.py      | 4 ++--
+ certbot/certbot/plugins/dns_test_common_lexicon.py | 6 +++---
+ tools/oldest_constraints.txt                       | 6 +++---
+ 15 files changed, 19 insertions(+), 21 deletions(-)
+
+diff --git a/certbot/certbot/plugins/dns_common_lexicon.py b/certbot/certbot/plugins/dns_common_lexicon.py
+index a4d46587e9d..32213999def 100644
+--- a/certbot/certbot/plugins/dns_common_lexicon.py
++++ b/certbot/certbot/plugins/dns_common_lexicon.py
+@@ -45,7 +45,7 @@ def add_txt_record(self, domain, record_name, record_content):
+         self._find_domain_id(domain)
+ 
+         try:
+-            self.provider.create_record(type='TXT', name=record_name, content=record_content)
++            self.provider.create_record(rtype='TXT', name=record_name, content=record_content)
+         except RequestException as e:
+             logger.debug('Encountered error adding TXT record: %s', e, exc_info=True)
+             raise errors.PluginError('Error adding TXT record: {0}'.format(e))
+@@ -67,7 +67,7 @@ def del_txt_record(self, domain, record_name, record_content):
+             return
+ 
+         try:
+-            self.provider.delete_record(type='TXT', name=record_name, content=record_content)
++            self.provider.delete_record(rtype='TXT', name=record_name, content=record_content)
+         except RequestException as e:
+             logger.debug('Encountered error deleting TXT record: %s', e, exc_info=True)
+ 
+diff --git a/certbot/certbot/plugins/dns_test_common_lexicon.py b/certbot/certbot/plugins/dns_test_common_lexicon.py
+index 5c6f09d208d..203adf0090c 100644
+--- a/certbot/certbot/plugins/dns_test_common_lexicon.py
++++ b/certbot/certbot/plugins/dns_test_common_lexicon.py
+@@ -94,7 +94,7 @@ class BaseLexiconClientTest:
+     def test_add_txt_record(self: _LexiconAwareTestCase):
+         self.client.add_txt_record(DOMAIN, self.record_name, self.record_content)
+ 
+-        self.provider_mock.create_record.assert_called_with(type='TXT',
++        self.provider_mock.create_record.assert_called_with(rtype='TXT',
+                                                             name=self.record_name,
+                                                             content=self.record_content)
+ 
+@@ -103,7 +103,7 @@ def test_add_txt_record_try_twice_to_find_domain(self: _LexiconAwareTestCase):
+ 
+         self.client.add_txt_record(DOMAIN, self.record_name, self.record_content)
+ 
+-        self.provider_mock.create_record.assert_called_with(type='TXT',
++        self.provider_mock.create_record.assert_called_with(rtype='TXT',
+                                                             name=self.record_name,
+                                                             content=self.record_content)
+ 
+@@ -147,7 +147,7 @@ def test_add_txt_record_error_adding_record(self: _LexiconAwareTestCase):
+     def test_del_txt_record(self: _LexiconAwareTestCase):
+         self.client.del_txt_record(DOMAIN, self.record_name, self.record_content)
+ 
+-        self.provider_mock.delete_record.assert_called_with(type='TXT',
++        self.provider_mock.delete_record.assert_called_with(rtype='TXT',
+                                                             name=self.record_name,
+                                                             content=self.record_content)
+ 



More information about the arch-commits mailing list