HEPCloud / decisionengine

HEPCloud Decision Engine framework
Apache License 2.0
6 stars 26 forks source link

Fix the python and RPM release and version strings #508

Open mambelli opened 3 years ago

mambelli commented 3 years ago

We need a tagging and versioning scheme that works well for Git, Python and the RPMs. Currently I've been tagging the RC and dev releases for x.y.(z+1) as x.y.z.postN, but this is causing problems w/ the automatic versions for the tests: x.y.z.postN.postM+VVVV is not a valid pep440 schema. Then it is not ideal. I'd like something that gives me good python versions and good RPM versions (with a tag that Git is not complaining about). ~ would be a separator ignored by Python and useful in RPMs but cannot be used in Git tags. I think setup tools allow functions to convert the version/release strings. I need something like (git/python -> RPM): 1.2.3 -> 1.2.3-1 , 1.3.0a2 -> 1.3.0~a.2-1, 1.4.2c4 -> 1.4.3-0.4.rc4-1 (1.4.3~c.4-1 acceptable)

jcpunk commented 3 years ago

I've whipped up https://github.com/pypa/setuptools/pull/2778 as a possible way to work around this issue. Currently the %version macro is hard coded to match the version string of the metadata. With this PR merged, I can split out the items from setuptools_scm to get pretty close to what you're after.

jcpunk commented 3 years ago

For now, if you tag as X.Y.ZrcQ that should fix up the actions workflow as X.Y.ZrcQ.postN should be a valid version. That doesn't fix up RPM thinking it is a "bigger" package than the official release, but it would get the workflows passing again.

StevenCTimm commented 2 years ago

Note that in the dev repo 1.7.99.post1 is somehow considered <= 1.7.0.post1 please investigate

mambelli commented 2 years ago

Hi @StevenCTimm, that's strange. For me, it seems to come after. How did it happen to you?

$ rpmdev-vercmp  1.7.99.post1 1.7.0.post1
1.7.99.post1 > 1.7.0.post1
$ yum --enablerepo=ssi-hepcloud-dev list --showduplicates decisionengine\*
...
decisionengine.noarch                                                                1.7.0-1                                                                     ssi-hepcloud-dev
decisionengine.noarch                                                                1.7.0.post1-1                                                               ssi-hepcloud-dev
decisionengine.noarch                                                                1.7.1-1                                                                     ssi-hepcloud
decisionengine.noarch                                                                1.7.99.post1-1                                                              ssi-hepcloud-dev
...
StevenCTimm commented 2 years ago

It seems to be just fermicloud467 that is messed up somehow. fermicloud435 sees the 1.7.99.post1 rpm correctly.

Now that I already installed the new rpm by hand on fermicloud467 I can't show what was happening before.


From: Marco Mambelli @.> Sent: Thursday, February 3, 2022 2:10 PM To: HEPCloud/decisionengine @.> Cc: Steven C Timm @.>; Comment @.> Subject: Re: [HEPCloud/decisionengine] Fix the python and RPM release and version strings (#508)

Hi Steve, that's strange. For me, it seems to come after. How did it happen to you?

$ rpmdev-vercmp 1.7.99.post1 1.7.0.post1 1.7.99.post1 > 1.7.0.post1 $ yum --enablerepo=ssi-hepcloud-dev list --showduplicates decisionengine* ... decisionengine.noarch 1.7.0-1 ssi-hepcloud-dev decisionengine.noarch 1.7.0.post1-1 ssi-hepcloud-dev decisionengine.noarch 1.7.1-1 ssi-hepcloud decisionengine.noarch 1.7.99.post1-1 ssi-hepcloud-dev ...

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_HEPCloud_decisionengine_issues_508-23issuecomment-2D1029358873&d=DwMCaQ&c=gRgGjJ3BkIsb5y6s49QqsA&r=10BCTK25QMgkMYibLRbpYg&m=JRnBRB_EAhPbCioqbn_gRbbvn9spL9aojiU7dQrCOQgoyKBrutYt5pco2DO0yKU_&s=gSwXk952c_z1-9xeMZMsdz8JF8bkAZNSMVXER2qpyVQ&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AGG4SOCZ27TTN7DACBF6YB3UZLOMJANCNFSM5DVQ33FA&d=DwMCaQ&c=gRgGjJ3BkIsb5y6s49QqsA&r=10BCTK25QMgkMYibLRbpYg&m=JRnBRB_EAhPbCioqbn_gRbbvn9spL9aojiU7dQrCOQgoyKBrutYt5pco2DO0yKU_&s=gJbs1mcJV9o01wClvc43FwuuaMb1n9xcFwKqsFeqkzc&e=. Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.proofpoint.com/v2/url?u=https-3A__apps.apple.com_app_apple-2Dstore_id1477376905-3Fct-3Dnotification-2Demail-26mt-3D8-26pt-3D524675&d=DwMCaQ&c=gRgGjJ3BkIsb5y6s49QqsA&r=10BCTK25QMgkMYibLRbpYg&m=JRnBRB_EAhPbCioqbn_gRbbvn9spL9aojiU7dQrCOQgoyKBrutYt5pco2DO0yKU_&s=T-FYZWOoAnEHVcWCkXcwi5oqt-8kohtRe1pfgPYWRT0&e= or Androidhttps://urldefense.proofpoint.com/v2/url?u=https-3A__play.google.com_store_apps_details-3Fid-3Dcom.github.android-26referrer-3Dutm-5Fcampaign-253Dnotification-2Demail-2526utm-5Fmedium-253Demail-2526utm-5Fsource-253Dgithub&d=DwMCaQ&c=gRgGjJ3BkIsb5y6s49QqsA&r=10BCTK25QMgkMYibLRbpYg&m=JRnBRB_EAhPbCioqbn_gRbbvn9spL9aojiU7dQrCOQgoyKBrutYt5pco2DO0yKU_&s=3tsL1PpEYUvLePkfiV9kbP8wKz59m_emmyAf-3dHFP8&e=. You are receiving this because you commented.Message ID: @.***>