Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 8.23.0.0 + upgrade cardano-api to 8.45.2.0 #749

Merged
merged 5 commits into from
May 6, 2024

Conversation

smelc
Copy link
Contributor

@smelc smelc commented May 3, 2024

Changelog

- description: |
    Release 8.23.0.0
# uncomment types applicable to the change:
  type:
  # - feature        # introduces a new feature
  # - breaking       # the API has changed in a breaking way
  # - compatible     # the API has changed but is non-breaking
  # - optimisation   # measurable performance improvements
  # - improvement    # QoL changes e.g. refactoring
  # - bugfix         # fixes a defect
  # - test           # fixes/modifies tests
  # - maintenance    # not directly related to the code
  - release        # related to a new release preparation
  # - documentation  # change in code docs, haddocks...

Context

How to trust this PR (for the CI change)

⚠️ You need to review the two CI-changing commits separately, because the first one fixes indentation, so it shows a big diff, but really it isn't ⚠️

When the release pipeline ran on the tagged commit here:

image

It failed silently during the first steps, because the repo was not checked out yet:

image

If you go to a later run (albeit triggered manually, because the HEAD wasn't the tag anymore), you can see the same step not failing anymore:

image

@smelc smelc force-pushed the smelc/update-cardano-api-to-8.45.2.0 branch 2 times, most recently from d5aced1 to eb48ca8 Compare May 6, 2024 07:42
@smelc smelc marked this pull request as ready for review May 6, 2024 07:53
@smelc smelc force-pushed the smelc/update-cardano-api-to-8.45.2.0 branch from eb48ca8 to 18a5b9b Compare May 6, 2024 07:55
fi
done
echo "TARGET_TAG=${{ env.TARGET_TAG }}" >> "$GITHUB_OUTPUT"
Copy link
Contributor

Choose a reason for hiding this comment

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

I feel like the above three steps could have been one step.

Copy link
Contributor Author

@smelc smelc May 6, 2024

Choose a reason for hiding this comment

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

Yep, right; I'll do that 👍 See #749 (comment)

echo "Tag not yet defined, using current commit as reference."
echo "TARGET_TAG=${{ github.ref_name }}" >> "$GITHUB_ENV"
fi
if [[ $(git tag --points-at ${{ env.TARGET_TAG }} | wc -l) == "0" ]]
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the env.TARGET_TAG used above may not be the same as the one set on line 84, but instead is the same one as used on line 81. Is this intended?

If the code was defined instead such that it was all one step you could define in bash TARGET_TAG= and then use it immediately and then only ad the end do the

echo "TARGET_TAG=$TARGET_TAG" >> "$GITHUB_ENV"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah probably it would be simpler to merge the three steps into one, indeed. I will do that in a follow-up PR 👍

- name: Define FLAKE_REF
id: define_flake_ref
run: |
flake_ref="github:${{ github.repository }}/${{ env.TARGET_TAG }}"
Copy link
Contributor

Choose a reason for hiding this comment

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

Does using $TARGET_TAG not work? Why do we need to use ${{ env.TARGET_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.

For consistency, I've used env.TARGET_TAG everywhere. It's safer when moving steps around.

id: define_flake_ref
run: |
flake_ref="github:${{ github.repository }}/${{ env.TARGET_TAG }}"
echo "FLAKE_REF=$flake_ref" >> "$GITHUB_ENV"
Copy link
Contributor

Choose a reason for hiding this comment

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

We seem to never use env.FLAKE_REF. Why define it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good catch, I'll remove it in a follow-up PR 👍

# (see https://stackoverflow.com/questions/22101778/how-to-preserve-line-breaks-when-storing-command-output-to-a-variable)

# shellcheck disable=SC2126
nb_failure=$(echo "$conclusion" | grep "^failure" | wc -l)
Copy link
Contributor

@carbolymer carbolymer May 6, 2024

Choose a reason for hiding this comment

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

Where does nb abbreviation come from?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@carbolymer> it means number. I can expand it in a follow-up PR. I'm never a fan of abbreviation, even though I authored this one 😅

Copy link
Contributor

Choose a reason for hiding this comment

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

But it does not in english. 😄 Can we use english abbreviation or full word?

Copy link
Contributor

@Jimbo4350 Jimbo4350 left a comment

Choose a reason for hiding this comment

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

Nice 👍 . A couple of comments regarding the changelog. Only user facing changes should be there and it should be obvious what has changed. Refactorings that don't result in optimizations we can exclude.

cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
(improvement, test)
[PR 714](https://github.com/IntersectMBO/cardano-cli/pull/714)

- Provide a default value for `calculate-min-fee --reference-script-size`
Copy link
Contributor

Choose a reason for hiding this comment

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

Putting the default value here would be useful.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changed to Defaulted calculate-min-fee --reference-script-size's value to 0`

cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
Copy link
Contributor

@carbolymer carbolymer left a comment

Choose a reason for hiding this comment

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

There are some redundant entries in changelog. This would save us some work later, when preparing release notes.

cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
cardano-cli/CHANGELOG.md Outdated Show resolved Hide resolved
@smelc smelc force-pushed the smelc/update-cardano-api-to-8.45.2.0 branch from 62c3e71 to 109b79b Compare May 6, 2024 13:00
Copy link
Contributor

@Jimbo4350 Jimbo4350 left a comment

Choose a reason for hiding this comment

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

LGTM!

@smelc smelc added this pull request to the merge queue May 6, 2024
Merged via the queue into main with commit 4b3cd0e May 6, 2024
28 of 31 checks passed
@smelc smelc deleted the smelc/update-cardano-api-to-8.45.2.0 branch May 6, 2024 14:26
@smelc smelc restored the smelc/update-cardano-api-to-8.45.2.0 branch May 6, 2024 14:54
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.

None yet

4 participants