Gentoo Archives: gentoo-commits

From: Andrew Ammerlaan <andrewammerlaan@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/spyder/
Date: Sat, 12 Jun 2021 10:25:29
Message-Id: 1623493520.5bb6a621811604d741a34f93b8e95ec960c2e167.andrewammerlaan@gentoo
1 commit: 5bb6a621811604d741a34f93b8e95ec960c2e167
2 Author: Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jun 12 10:23:39 2021 +0000
4 Commit: Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
5 CommitDate: Sat Jun 12 10:25:20 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5bb6a621
7
8 dev-python/spyder: switch pyls --> python-lsp-server
9
10 We are running into a dependency mess with pyls because it
11 hasn't been updated for over 6 months. We can no longer
12 wait for upstream to make the switch to their own fork of the
13 project (though I still expect this soonish)
14
15 Bug: https://bugs.gentoo.org/783618
16 Bug: https://bugs.gentoo.org/783615
17 Package-Manager: Portage-3.0.19, Repoman-3.0.3
18 Signed-off-by: Andrew Ammerlaan <andrewammerlaan <AT> gentoo.org>
19
20 ...{spyder-4.2.5.ebuild => spyder-4.2.5-r1.ebuild} | 35 +++++++++++++++------
21 ...{spyder-5.0.4.ebuild => spyder-5.0.4-r1.ebuild} | 36 ++++++++++++++++------
22 2 files changed, 52 insertions(+), 19 deletions(-)
23
24 diff --git a/dev-python/spyder/spyder-4.2.5.ebuild b/dev-python/spyder/spyder-4.2.5-r1.ebuild
25 similarity index 87%
26 rename from dev-python/spyder/spyder-4.2.5.ebuild
27 rename to dev-python/spyder/spyder-4.2.5-r1.ebuild
28 index 0fac6b43bcb..cb91fff8bf7 100644
29 --- a/dev-python/spyder/spyder-4.2.5.ebuild
30 +++ b/dev-python/spyder/spyder-4.2.5-r1.ebuild
31 @@ -59,24 +59,22 @@ RDEPEND="
32 >=dev-python/psutil-5.3[${PYTHON_USEDEP}]
33 >=dev-python/pygments-2.0[${PYTHON_USEDEP}]
34 >=dev-python/pylint-1.0[${PYTHON_USEDEP}]
35 - >=dev-python/python-language-server-0.36.2[${PYTHON_USEDEP}]
36 + >=dev-python/python-lsp-server-1.0.1[${PYTHON_USEDEP}]
37
38 dev-python/autopep8[${PYTHON_USEDEP}]
39 >=dev-python/flake8-3.8.0[${PYTHON_USEDEP}]
40 >=dev-python/mccabe-0.6.0[${PYTHON_USEDEP}]
41 <dev-python/mccabe-0.7.0[${PYTHON_USEDEP}]
42 - >=dev-python/pycodestyle-2.6.0[${PYTHON_USEDEP}]
43 - <dev-python/pycodestyle-2.7.0[${PYTHON_USEDEP}]
44 + >=dev-python/pycodestyle-2.7.0[${PYTHON_USEDEP}]
45 >=dev-python/pydocstyle-2.0.0[${PYTHON_USEDEP}]
46 - >=dev-python/pyflakes-2.2.0[${PYTHON_USEDEP}]
47 - <dev-python/pyflakes-2.3.0[${PYTHON_USEDEP}]
48 - dev-python/pylint[${PYTHON_USEDEP}]
49 + >=dev-python/pyflakes-2.3.0[${PYTHON_USEDEP}]
50 + <dev-python/pyflakes-2.4.0[${PYTHON_USEDEP}]
51 + >=dev-python/pylint-2.5.0[${PYTHON_USEDEP}]
52 >=dev-python/rope-0.10.5[${PYTHON_USEDEP}]
53 dev-python/yapf[${PYTHON_USEDEP}]
54
55 - <dev-python/python-language-server-1.0.0[${PYTHON_USEDEP}]
56 - >=dev-python/pyls-black-0.4.6[${PYTHON_USEDEP}]
57 - >=dev-python/pyls-spyder-0.3.2[${PYTHON_USEDEP}]
58 + >=dev-python/python-lsp-black-1.0.0[${PYTHON_USEDEP}]
59 + >=dev-python/pyls-spyder-0.4.0[${PYTHON_USEDEP}]
60 >=dev-python/pyxdg-0.26[${PYTHON_USEDEP}]
61 >=dev-python/pyzmq-17.0.0[${PYTHON_USEDEP}]
62 >=dev-python/qdarkstyle-2.8[${PYTHON_USEDEP}]
63 @@ -142,6 +140,25 @@ python_prepare_all() {
64 # runs against things packaged in external-deps dir
65 rm conftest.py || die
66
67 + # Use the spyder fork of pyls (python-lsp-server instead of python-language-server)
68 + # The original hasn't been update in over 6 months, and spyder upstream is slow
69 + # in making the switch. Because we are running into issues with outdated deps
70 + # and a whole dependency mess as a result, we can no longer wait for upstream.
71 + find . -name "*.py" -exec sed -i \
72 + -e 's/python-language-server\[all\]>=0.36.2,<1.0.0/python-lsp-server\[all\]>=1.0.0/g' \
73 + -e 's/python-language-server/python-lsp-server/g' \
74 + -e 's/python_language_server/python_lsp_server/g' \
75 + -e 's/python-jsonrpc-server/python-lsp-jsonrpc/g' \
76 + -e 's/python_jsonrpc_server/python_lsp_jsonrpc/g' \
77 + -e 's/pyls/pylsp/g' \
78 + -e 's/pylsp-spyder/pyls-spyder/g' \
79 + -e 's/pylsp_spyder/pyls_spyder/g' \
80 + -e 's/pyls-spyder>=0.3.2,<0.4.0/pyls-spyder>=0.4.0/g' \
81 + -e 's/pylsp-black/python-lsp-black/g' \
82 + -e 's/>=0.3.2;<0.4.0/>=0.4.0/g' \
83 + -e 's/>=0.36.2;<1.0.0/>=1.0.0/g' \
84 + {} + || die
85 +
86 # do not depend on pyqt5<13
87 sed -i -e '/pyqt5/d' \
88 -e '/pyqtwebengine/d' \
89
90 diff --git a/dev-python/spyder/spyder-5.0.4.ebuild b/dev-python/spyder/spyder-5.0.4-r1.ebuild
91 similarity index 83%
92 rename from dev-python/spyder/spyder-5.0.4.ebuild
93 rename to dev-python/spyder/spyder-5.0.4-r1.ebuild
94 index 152f4768171..3343093b7df 100644
95 --- a/dev-python/spyder/spyder-5.0.4.ebuild
96 +++ b/dev-python/spyder/spyder-5.0.4-r1.ebuild
97 @@ -52,11 +52,9 @@ RDEPEND="
98 >=dev-python/psutil-5.3[${PYTHON_USEDEP}]
99 >=dev-python/pygments-2.0[${PYTHON_USEDEP}]
100 >=dev-python/pylint-1.0[${PYTHON_USEDEP}]
101 - >=dev-python/pyls-black-0.4.6[${PYTHON_USEDEP}]
102 - >=dev-python/pyls-spyder-0.3.2[${PYTHON_USEDEP}]
103 - <dev-python/pyls-spyder-0.4.0[${PYTHON_USEDEP}]
104 - >=dev-python/python-language-server-0.36.2[${PYTHON_USEDEP}]
105 - <dev-python/python-language-server-1.0.0[${PYTHON_USEDEP}]
106 + >=dev-python/python-lsp-black-1.0.0[${PYTHON_USEDEP}]
107 + >=dev-python/pyls-spyder-0.4.0[${PYTHON_USEDEP}]
108 + >=dev-python/python-lsp-server-1.0.1[${PYTHON_USEDEP}]
109 >=dev-python/pyxdg-0.26[${PYTHON_USEDEP}]
110 >=dev-python/pyzmq-17[${PYTHON_USEDEP}]
111 ~dev-python/qdarkstyle-3.0.2[${PYTHON_USEDEP}]
112 @@ -73,17 +71,16 @@ RDEPEND="
113 >=dev-python/watchdog-0.10.3[${PYTHON_USEDEP}]
114 "
115
116 -# python-language-server[all] deps
117 +# python-lsp-server[all] deps
118 RDEPEND+="
119 dev-python/autopep8[${PYTHON_USEDEP}]
120 >=dev-python/flake8-3.8.0[${PYTHON_USEDEP}]
121 >=dev-python/mccabe-0.6.0[${PYTHON_USEDEP}]
122 <dev-python/mccabe-0.7.0[${PYTHON_USEDEP}]
123 - >=dev-python/pycodestyle-2.6.0[${PYTHON_USEDEP}]
124 - <dev-python/pycodestyle-2.7.0[${PYTHON_USEDEP}]
125 + >=dev-python/pycodestyle-2.7.0[${PYTHON_USEDEP}]
126 >=dev-python/pydocstyle-2.0.0[${PYTHON_USEDEP}]
127 - >=dev-python/pyflakes-2.2.0[${PYTHON_USEDEP}]
128 - <dev-python/pyflakes-2.3.0[${PYTHON_USEDEP}]
129 + >=dev-python/pyflakes-2.3.0[${PYTHON_USEDEP}]
130 + <dev-python/pyflakes-2.4.0[${PYTHON_USEDEP}]
131 >=dev-python/pylint-2.5.0[${PYTHON_USEDEP}]
132 >=dev-python/rope-0.10.5[${PYTHON_USEDEP}]
133 dev-python/yapf[${PYTHON_USEDEP}]
134 @@ -144,6 +141,25 @@ python_prepare_all() {
135 # runs against things packaged in external-deps dir
136 rm conftest.py || die
137
138 + # Use the spyder fork of pyls (python-lsp-server instead of python-language-server)
139 + # The original hasn't been update in over 6 months, and spyder upstream is slow
140 + # in making the switch. Because we are running into issues with outdated deps
141 + # and a whole dependency mess as a result, we can no longer wait for upstream.
142 + find . -name "*.py" -exec sed -i \
143 + -e 's/python-language-server\[all\]>=0.36.2,<1.0.0/python-lsp-server\[all\]>=1.0.0/g' \
144 + -e 's/python-language-server/python-lsp-server/g' \
145 + -e 's/python_language_server/python_lsp_server/g' \
146 + -e 's/python-jsonrpc-server/python-lsp-jsonrpc/g' \
147 + -e 's/python_jsonrpc_server/python_lsp_jsonrpc/g' \
148 + -e 's/pyls/pylsp/g' \
149 + -e 's/pylsp-spyder/pyls-spyder/g' \
150 + -e 's/pylsp_spyder/pyls_spyder/g' \
151 + -e 's/pyls-spyder>=0.3.2,<0.4.0/pyls-spyder>=0.4.0/g' \
152 + -e 's/pylsp-black/python-lsp-black/g' \
153 + -e 's/>=0.3.2;<0.4.0/>=0.4.0/g' \
154 + -e 's/>=0.36.2;<1.0.0/>=1.0.0/g' \
155 + {} + || die
156 +
157 # do not depend on pyqt5<13
158 sed -i -e '/pyqt5/d' \
159 -e '/pyqtwebengine/d' \