rpm-software-management / spec-cleaner

spec-cleaner
BSD 3-Clause "New" or "Revised" License
28 stars 34 forks source link

incorrect placement of curly brackets #299

Closed arunpersaud closed 1 year ago

arunpersaud commented 2 years ago

Hi

when running spec-cleaner (v1.2.1) over a package on the opensuse build sever I ran into two problems. Here are the lines from the diff between the original and the cleaned spec-file:

-BuildRequires: %{python_module jupyter_server >= 1.8 with %python-jupyter_server < 2} +BuildRequires: %{python_module jupyter_server >= 1.8 with %{python}-jupyter_server < 2}

-%python_libalternatives_reset_alternative jupyter-nbclassic +%{python_libalternatives_reset_alternative} jupyter-nbclassic

both lead to build errors due to incorrect(?) placement of the curly brackets?

The spec file can be found here: https://build.opensuse.org/package/view_file/devel:languages:python:jupyter/python-nbclassic/python-nbclassic.spec?expand=1

kubat-david commented 1 year ago

Is the placement of the curly brackets in the second example really incorrect?

-%python_libalternatives_reset_alternative jupyter-nbclassic
+%{python_libalternatives_reset_alternative} jupyter-nbclassic
kubat-david commented 1 year ago

It is, as it leads to build failures.

https://build.opensuse.org/package/live_build_log/home:dkubat:branches:devel:languages:python:jupyter/python-nbclassic/openSUSE_Tumbleweed/x86_64

%python_libalternatives_reset_alternative should probably be added to data/excludes-bracketing.txt