Skip to content

Conversation

bobleesj
Copy link
Contributor

@bobleesj bobleesj commented Jan 1, 2025

Closes #94

I think it is better to read this PR diffpy/diffpy.utils#312 first since it's related and I provide a bit more context on the problem.

Please see in-line comments:

uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetches branches and tags
ref: main # Fetch the main branch with CHANGELOG.rst modified during full release
Copy link
Contributor Author

@bobleesj bobleesj Jan 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Problem 2 - release notes never displayed the latest version

I found the source of the problem why changelog didn't show the latest version upon release.

When push a tag (commit) to upstream, the tag does not contain updated CHANGELOG.rst. The CHANGELOG.rst is modified during the CI which has an additional commit in main.

Hence, when we build a doc, we should checkout main instead of the tag!

@bobleesj bobleesj changed the title ci: Build docs as a part of the release workflow after github release ci: Build docs as a part of the release workflow after github release, while still allowing deploy doc by workflow dispatch if needed. Jan 1, 2025
@bobleesj
Copy link
Contributor Author

bobleesj commented Jan 1, 2025

@sbillinge ready for review

@sbillinge
Copy link
Contributor

please see my comments on the diffpy.utils PR. I wonder if this is the right approach actually.


github-release:
needs: [update-changelog]
needs: [delete-create-new-tag]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

must have delete-create-new-tag which depends on build-changelog

@bobleesj
Copy link
Contributor Author

bobleesj commented Jan 1, 2025

Delete the tag on upstream and then remake it after the CHANGELOG is merged instead?

@sbillinge ready for review - tested using a dummy repo/org.

https://bobleesj-test-org.github.io/bobleesj.release/release.html

@bobleesj bobleesj changed the title ci: Build docs as a part of the release workflow after github release, while still allowing deploy doc by workflow dispatch if needed. ci: Delete/remove release tag after CHANGELOG.rst modified in main, build docs as a part of the release workflow after github release Jan 1, 2025
@sbillinge
Copy link
Contributor

looks good, let's try it..... I will merge. Does diffpy.utils have to be updated, or this will just run if I merge it into v0?

@sbillinge sbillinge merged commit 627d789 into scikit-package:main Jan 1, 2025
1 check passed
@bobleesj bobleesj deleted the deploy-doc-within-release branch January 1, 2025 19:02
@bobleesj
Copy link
Contributor Author

bobleesj commented Jan 1, 2025

looks good, let's try it..... I will merge. Does diffpy.utils have to be updated, or this will just run if I merge it into v0?

No updates needed.. on diffpy.utils.

@sbillinge
Copy link
Contributor

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: Release Notes in published doc does not display the latest release version and news

2 participants