OpenCS-ontology / OpenCS

Main OpenCS ontology repository
Creative Commons Attribution 4.0 International
5 stars 7 forks source link

Tagged release workflow broken (bad substitution) #39

Closed Ostrzyciel closed 8 months ago

Ostrzyciel commented 8 months ago

See workflow log: https://github.com/OpenCS-ontology/OpenCS/actions/runs/7573990821/job/20627371576

As as result this release was made, which is actually rather funny... https://github.com/OpenCS-ontology/OpenCS/releases/tag/%24%7BGITHUB_REF_NAME%23v%7D

Could you double-check the scripts?

@jakfol1217 @Bartosz7

Bartosz7 commented 8 months ago

So, looks good from my side. Tagged release workflow shouldn't be run with normal push to main unless tag was used, so i checked with git log --oneline --decorate --tags --no-walk --format="%h %d %an: %s":

49638b8f6  (HEAD -> main, tag: v0.4.0, tag: ${GITHUB_REF_NAME#v}, origin/main, origin/HEAD) Jakub Fołtyn: Change commit message to tag version (#38)
ed6676650  (tag: dev) Piotr Sowiński: Update README.md – bump
8bf15d21a  (tag: v0.3.1) Piotr Sowiński: Add missing inferred assertions to tagged releases (#25)
d31004361  (tag: v0.3.0) Piotr Sowiński: Fix inference ci (#24)
46d8abab2  (tag: v0.2.0) Piotr Sowiński: Add missing language tags (#8)
702a89be7  (tag: v0.1.1) Piotr Sowiński: Add missing container specification (#6)
a5c44bce5  (tag: v0.1.0) Piotr Sowiński: Add CI for tagged releases (#5)

As you can see the latest commit (49638b8f6) by @jakfol1217 was tagged (even double-tagged 😮).

Suggestion (in 3 steps):

  1. remove the unintentional releases (v0.4.0, ${GITHUB_REF_NAME#v}) manually from OpenCS repo
  2. Either delete the commit tags OR revert the changes and push a new commit with the change once again without any tags
  3. Maybe test the ci-script now by issuing a new release. But we should most likely firstly merge https://github.com/OpenCS-ontology/OpenCS-ontology.github.io/pull/3 to avoid any issues
jakfol1217 commented 8 months ago

Yes, my bad (again), sorry, I am not sure how the commit was double-tagged though; nevertheless I believe I have a solution but it may be indeed safer to first remove the tags/revert the changes.

Ostrzyciel commented 8 months ago

The double-tagging must have been done by the CI. The only thing I did was to tag the latest commit on the main branch with v0.4.0 and then pushed the tag. I will delete the tag and the release then.

Ostrzyciel commented 8 months ago

OK, release removed, tags removed, the PR merged. Your turn :)

jakfol1217 commented 8 months ago

I've opened a pull request #40.

Ostrzyciel commented 8 months ago

OK, merged, tagged again with v0.4.0 and it works :)

https://github.com/OpenCS-ontology/OpenCS/releases/tag/v0.4.0

https://opencs-ontology.github.io/browse/#C28117

Thank you both!