No matter how often/hard I read the guidelines about renaming/replacing existing packages [1], I am always puzzled by the guideline and the example. The first guideline says:
{{{ Provides: oldpackagename = $provEVR Obsoletes: oldpackagename < $obsEVR }}}
while the following example contains:
{{{ Obsoletes: foo <= 2:1.0-4 }}}
i.e. in the former, there is '<' sign, while in the latter there is '<=' sign. So which one is right? Why they are not aligned?
From my testing, it seems that the '<' is really the proper sign due to %{dist} tag, so could you please adjust the example to reflect this?
Also the "Take %{?dist} into account" could do better job explaining how the comparison works.
Alternatively, wouldn't be actually better to suggest to use obsoletes such as:
{{{ Obsoletes: foo <= $lastKnownEVRIncludingDistTag }}}
e.g.
{{{ Obsoletes: foo <= 2:1.0-4.fc24 }}}
and you could remove all the cruft about bumping release.
[1] https://fedoraproject.org/wiki/Packaging:Guidelines#Renaming.2FReplacing_Existing_Packages
Actually, in the context of current guidelines, the last "Obsoletes" line should be:
{{{ Obsoletes: foo <= 2:1.0-3.fc24 }}}
Say we have M-a.b-c replacing N-x.y-z
The two general cases are:
I am replacing something specific that I know existed, and I know provide that in the same way. Then M provides N=x.y-z and obsoletes N<=x.y-z.
I am replacing anything that happened before me with name X, I kind of provide the same thing. Then M provides N=a.b-c and obsoletes N<a.b-c ... where a.b-c don't increase as new versions of M are released.
...the confusion in the policy is that because fedora has N-x.y-z%{dist} then you either need to obsolete N<=x.y-z%{dist} OR be clever and obsolete N<=x.y-z+1 (which is what the example does). It mostly doesn't matter much though IMO, as long as there is a version.
The difference is that your example is nice and concise, capturing everything important. The guidelines is bloated and confusing. I would appreciate if it can be reworded.
And BTW, your "OR be clever and obsolete N<=x.y-z+1" should be in reality "N<x.y-z+1" and that is the part of the problem. There is sometimes used '<' where on other places '<=' and you made the mistake here again.
Replying to [comment:4 vondruch]:
As with all the policy we are open to rewording changes to make them clearer, but we often don't instigate those changes (we generally approved the old versions after all).