On 11/16/22 08:58, Zbigniew Jędrzejewski-Szmek wrote:
>
> Hello,
>
> The standard invocation of the Python dependency generator will be
> changed to always run with option like `--fail-if-version-zero`. (This
> is the subject of the current proposal.)
>
> Based on your concerns, an opt out mechanism would be added:
> If you wanted to bypass the option, you could define a macro in the
> specfile, eg.
> `%{!?__python_dist_allow_version_zero:--fail-if-version-zero}`
>
> This would allow to build RPMs without bothering with versions. Also, if
> it's upstream's decision to use version 0, that would be the way to go.
> In Fedora this would give us an insight into how often this is needed.
>
> What do you think of enhancing the proposal this way?
This would provide the opt-out that was requested.
But it's also very specific to a problem that is mostly theoretical.
Maybe instead add %__python_dist_extra_flags that would contain
'--fail-if-version-zero'
by default. That would also provide an opt-out, but allow other
currently unforeseen uses.
Zbyszek
Thank you for the alternative proposal. After discussion with Miro
Hrončok we decided for the initial idea of a macro which if defined,
will disable the flag from script invocation.
The main reason being that there's already another Python macro that
behaves this way
(
https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_python...),
so the new one will fit into the picture.
It'll be also easily greppable for usage statistics.
As we expect little to no need to actually use the opt-out, the trivial
(to implement and use) solution seems just enough.
Karolina