Skip to content

Conversation

rjan90
Copy link
Contributor

@rjan90 rjan90 commented Sep 15, 2025

Add automated release workflow for version changes:

  • Detects version changes and creates draft releases with auto-generated changelog
  • Automatically publishes draft releases when PRs are merged to main

Workflow:

  • PR with version change → Creates draft release with changelog
  • Review/edit draft release as needed
  • Merge to main → Automatically publishes the release

feat: add automated release on version change
@FilOzzy FilOzzy added this to FS Sep 15, 2025
@github-project-automation github-project-automation bot moved this to 📌 Triage in FS Sep 15, 2025
@rjan90 rjan90 moved this from 📌 Triage to 🔎 Awaiting review in FS Sep 16, 2025
@rjan90 rjan90 moved this to 🔎 Awaiting review in PDP Sep 16, 2025
@rvagg
Copy link
Contributor

rvagg commented Sep 17, 2025

I wonder if https://github.com/googleapis/release-please might just be a better option here. I'm going with that in filecoin-pin at the moment and we'll be switching synapse-sdk to it and it's fairly flexible, not tied to npm/node stuff. Maybe we can extend it with some hooks to do some updates for us - like update the version string in the contract for us based on conventional commits guessing. Worth looking at at least?

@rjan90
Copy link
Contributor Author

rjan90 commented Sep 17, 2025

Yeah, I will take a look at that. And update accordingly.

@BigLep
Copy link
Contributor

BigLep commented Sep 18, 2025

Below are my thoughts @rjan90 around this subject. But maybe we should move this to a more general "FOC contract versioning and release management" design doc?

  • For building up the changelog: I agree we should just lean in hard to conventional commits and linear history. This would mean:

    • Maybe only support squash/merge
    • Actually having a CI check to ensure PR title follows conventional commit and ensure that an attempted merge has a commit message that follows conventional commit (i.e., catch the case when someone changes the squash/merge message to not be the PR title).
  • For creating the GitHub release with a release version number: release-please seems great here for this.

  • For deployments of library contracts: I see we have various scripts in our repos for deploying to calibration and mainnet. My hope is that we have the ability to say "deploy contract [email protected] to calibraiton|mainnet" and then after a deployment a release artifact is attached to the github release itself. So basically https://github.com/FilOzone/pdp/releases/tag/v2.1.0 would have a "mainnet-deployment.json" file attached that has a deployment receipt like:

{
   networkName : "mainnnet",
   contractNameDeployed : "pdp.sol",
   commitDeployed : "commit_that_corresponds_with_version_2.1.0",
   contractAddress : "address_of_contract_on_mainnet",
   deploymentTransaction : "transaction_hash",
}

General comments:

  1. Maybe just personal taste, but I would avoid big inline scripts in the github action workflows. Instead externalize them and reference them in the workflow.
  2. Also maybe personal taste, but I would vote for using something more human readable than large bash scripts (e.g., do a Node script) if there is much conditional / conditional structure or error handling required.

I won't claim expertise here and happy to support alternative approaches. This is where I landed with when trying to balance where we are with getting things more auditable and less error prone for the future.

@rjan90 rjan90 self-assigned this Sep 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🔎 Awaiting review
Status: 🔎 Awaiting review
Development

Successfully merging this pull request may close these issues.

3 participants