From ca6c237c551e78b44983e2ab0ade982f36bef9a53086f20c76ea8d3ced3b583b Mon Sep 17 00:00:00 2001
From: Benjamin Greiner <code@bnavigator.de>
Date: Fri, 26 Nov 2021 18:49:41 +0000
Subject: [PATCH 1/2] Accepting request 934148 from
 home:bnavigator:branches:devel:languages:python:numeric

- Update to 1.3.1
  * Fix tests for Jedi 0.18.1
  * Option `jedi_completion.resolve_at_most_labels` was renamed to
    `jedi_completion.resolve_at_most` because now it controls how
    many labels and snippets will be resolved per request.
  * Option `jedi_completion.cache_labels_for` was renamed to
    `jedi_completion.cache_for` because now it controls the modules
    for which labels and snippets should be cached.
  * Update requirements on Pylint, flake8, pycodestyle, pyflakes
    and autopep8.
- Drop python-lsp-server-pr102-unpin-flake8.patch

OBS-URL: https://build.opensuse.org/request/show/934148
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-python-lsp-server?expand=0&rev=11
---
 python-lsp-server-1.2.4.tar.gz             |  3 --
 python-lsp-server-1.3.1.tar.gz             |  3 ++
 python-lsp-server-pr102-unpin-flake8.patch | 44 ----------------------
 python-python-lsp-server.changes           | 15 ++++++++
 python-python-lsp-server.spec              |  8 ++--
 5 files changed, 23 insertions(+), 50 deletions(-)
 delete mode 100644 python-lsp-server-1.2.4.tar.gz
 create mode 100644 python-lsp-server-1.3.1.tar.gz
 delete mode 100644 python-lsp-server-pr102-unpin-flake8.patch

diff --git a/python-lsp-server-1.2.4.tar.gz b/python-lsp-server-1.2.4.tar.gz
deleted file mode 100644
index 1b96d33..0000000
--- a/python-lsp-server-1.2.4.tar.gz
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:007278c4419339bd3a61ca6d7eb8648ead28b5f1b9eba3b6bae8540046116335
-size 62073
diff --git a/python-lsp-server-1.3.1.tar.gz b/python-lsp-server-1.3.1.tar.gz
new file mode 100644
index 0000000..142dc57
--- /dev/null
+++ b/python-lsp-server-1.3.1.tar.gz
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9869545b980091f57865e01cc2ba5f82b0f4298545b8c67829b0cb1c8b2a0794
+size 62464
diff --git a/python-lsp-server-pr102-unpin-flake8.patch b/python-lsp-server-pr102-unpin-flake8.patch
deleted file mode 100644
index 26945f6..0000000
--- a/python-lsp-server-pr102-unpin-flake8.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From e51767c76ab294645917536f44bce9a1b9342649 Mon Sep 17 00:00:00 2001
-From: Carlos Cordoba <ccordoba12@gmail.com>
-Date: Sat, 30 Oct 2021 12:42:28 -0500
-Subject: [PATCH 1/3] Update requirement on flake8 and its dependencies
-
----
- setup.py | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
-
-Index: python-lsp-server-1.2.4/setup.py
-===================================================================
---- python-lsp-server-1.2.4.orig/setup.py
-+++ python-lsp-server-1.2.4/setup.py
-@@ -46,22 +46,22 @@ setup(
-     python_requires='>=3.6',
-     extras_require={
-         'all': [
--            'autopep8',
--            'flake8>=3.8.0,<4.0.0',
-+            'autopep8>=1.6.0,<1.7.0',
-+            'flake8>=4.0.0,<4.1.0',
-             'mccabe>=0.6.0,<0.7.0',
--            'pycodestyle>=2.7.0',
-+            'pycodestyle>=2.8.0,<2.9.0',
-             'pydocstyle>=2.0.0',
--            'pyflakes>=2.3.0,<2.4.0',
-+            'pyflakes>=2.4.0,<2.5.0',
-             'pylint>=2.5.0,<2.10.0',
-             'rope>=0.10.5',
-             'yapf',
-         ],
--        'autopep8': ['autopep8'],
--        'flake8': ['flake8>=3.8.0,<4.0.0'],
-+        'autopep8': ['autopep8>=1.6.0,<1.7.0'],
-+        'flake8': ['flake8>=4.0.0,<4.1.0'],
-         'mccabe': ['mccabe>=0.6.0,<0.7.0'],
--        'pycodestyle': ['pycodestyle>=2.7.0'],
-+        'pycodestyle': ['pycodestyle>=2.8.0,<2.9.0'],
-         'pydocstyle': ['pydocstyle>=2.0.0'],
--        'pyflakes': ['pyflakes>=2.3.0,<2.4.0'],
-+        'pyflakes': ['pyflakes>=2.4.0,<2.5.0'],
-         'pylint': ['pylint>=2.5.0,<2.10.0'],
-         'rope': ['rope>0.10.5'],
-         'yapf': ['yapf'],
diff --git a/python-python-lsp-server.changes b/python-python-lsp-server.changes
index d017fa0..9615bce 100644
--- a/python-python-lsp-server.changes
+++ b/python-python-lsp-server.changes
@@ -1,3 +1,18 @@
+-------------------------------------------------------------------
+Fri Nov 26 18:40:47 UTC 2021 - Ben Greiner <code@bnavigator.de>
+
+- Update to 1.3.1
+  * Fix tests for Jedi 0.18.1
+  * Option `jedi_completion.resolve_at_most_labels` was renamed to
+    `jedi_completion.resolve_at_most` because now it controls how
+    many labels and snippets will be resolved per request.
+  * Option `jedi_completion.cache_labels_for` was renamed to
+    `jedi_completion.cache_for` because now it controls the modules
+    for which labels and snippets should be cached.
+  * Update requirements on Pylint, flake8, pycodestyle, pyflakes
+    and autopep8.
+- Drop python-lsp-server-pr102-unpin-flake8.patch
+
 -------------------------------------------------------------------
 Sat Nov 20 19:57:52 UTC 2021 - Ben Greiner <code@bnavigator.de>
 
diff --git a/python-python-lsp-server.spec b/python-python-lsp-server.spec
index a56d7c7..5274ba5 100644
--- a/python-python-lsp-server.spec
+++ b/python-python-lsp-server.spec
@@ -19,14 +19,12 @@
 %{?!python_module:%define python_module() python3-%{**}}
 %define skip_python2 1
 Name:           python-python-lsp-server
-Version:        1.2.4
+Version:        1.3.1
 Release:        0
 Summary:        Python Language Server for the Language Server Protocol
 License:        MIT
 URL:            https://github.com/python-lsp/python-lsp-server
 Source:         https://files.pythonhosted.org/packages/source/p/python-lsp-server/python-lsp-server-%{version}.tar.gz
-# PATCH-FIX-UPSTREAM python-lsp-server-pr102-unpin-flake8.patch -- gh#python-lsp/python-lsp-server#102
-Patch0:         python-lsp-server-pr102-unpin-flake8.patch
 BuildRequires:  %{python_module setuptools >= 39.0.0}
 BuildRequires:  python-rpm-macros >= 20210628
 # SECTION test requirements
@@ -57,11 +55,15 @@ Requires:       python-python-lsp-jsonrpc >= 1.0.0
 Requires:       python-setuptools >= 39.0.0
 Requires:       python-ujson >= 3.0.0
 Suggests:       python-autopep8 >= 1.6.0
+Conflicts:      python-autopep8 >= 1.7.0
 Suggests:       python-flake8 >= 4.0.0
+Conflicts:      python-flake8 >= 4.1.0
 Suggests:       python-mccabe >= 0.6.0
 Suggests:       python-pycodestyle >= 2.8.0
+Conflicts:      python-pycodestyle >= 2.9.0
 Suggests:       python-pydocstyle >= 2.0.0
 Suggests:       python-pyflakes >= 2.4.0
+Conflicts:      python-pyflakes >= 2.5.0
 Suggests:       python-pylint >= 2.5.0
 Suggests:       python-rope >= 0.10.5
 Suggests:       python-yapf

From 5d0d6859cda052957ba9beb5ad623a86be36781c3344489f02e721be7e394129 Mon Sep 17 00:00:00 2001
From: Benjamin Greiner <code@bnavigator.de>
Date: Fri, 26 Nov 2021 18:52:25 +0000
Subject: [PATCH 2/2] OBS-URL:
 https://build.opensuse.org/package/show/devel:languages:python/python-python-lsp-server?expand=0&rev=12

---
 python-python-lsp-server.spec | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/python-python-lsp-server.spec b/python-python-lsp-server.spec
index 5274ba5..6f95192 100644
--- a/python-python-lsp-server.spec
+++ b/python-python-lsp-server.spec
@@ -91,9 +91,6 @@ will be enabled:
 
 %prep
 %autosetup -p1 -n python-lsp-server-%{version}
-# the only relevant changes from https://github.com/python-lsp/python-lsp-server/pull/94
-sed -i 's/pylint>=2.5.0,<2.10.0/pylint>=2.5.0/' setup.py
-sed -i "s/open(document.path, 'w')/open(document.path, 'w', encoding='utf-8')/" test/plugins/test_pylint_lint.py
 
 %build
 %python_build