-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change management of unreleased section of CHANGELOG (#2723)
## Linked Issues/PRs #2658 ## Description This PR implements the new way of handling the unreleased section of the changelog in order to avoid conflicts on each PR merge. Details are available here : #2658. Main changes : ### Split of all unreleased changes in different files This PR introduces the `.changes/` folder that contains a sub-folder for each subsection of the changelog (added, breaking, ...). When you creates a PR you will need to create a file with the name : `[pr_number].md` and add the text related to your changes in this file. The job "check-changelog" has been adapted to check for this file. You can see 3 example of usage here : - OltaLabs/no-conflict-keep-a-changelog-action#7 - OltaLabs/no-conflict-keep-a-changelog-action#9 - OltaLabs/no-conflict-keep-a-changelog-action#10 The "no changelog" label is still working. Example : - OltaLabs/no-conflict-keep-a-changelog-action#8 ### New GitHub action to edit the changelog automatically on release When tagging a PR with a new label "pr release" it will trigger a job that will remove all changes in the `.changes` folder and create the section in the CHANGELOG.md file. Example : - OltaLabs/no-conflict-keep-a-changelog-action#11 ### New PR templates The GitHub action that creates the section in changelog require to know the version needed to create. In order to provide that information to the CI, a new PR template has been added that will be automatically completed by the Action with all the changelog of this version. Example:  GitHub doesn't have an UI to choose between PR template (such as they have for issues) and so the new default template PR contains two clickable links (under the "Preview" section) to create a selection menu between pull requests templates. ## Side modification I also edited the name and email of all of our Action that commit to the repository to be the correct github action bot and being unified ## Checklist - [x] Breaking changes are clearly marked as such in the PR description and changelog - [x] New behavior is reflected in tests - [x] [The specification](https://github.com/FuelLabs/fuel-specs/) matches the implemented behavior (link update PR if changes are needed) ### Before requesting review - [x] I have reviewed the code myself - [x] I have created follow-up issues caused by this PR and linked them here
- Loading branch information
1 parent
22d4173
commit f9431ef
Showing
25 changed files
with
167 additions
and
48 deletions.
There are no files selected for viewing
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Upgraded `libp2p` to `0.54.1` and introduced `ConnectionLimiter` to limit pending incoming/outgoing connections. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Storage read replays of historical blocks for execution tracing. Only available behind `--historical-execution` flag. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Added two new CLI arguments to control the GraphQL queries consistency: `--graphql-block-height-tolerance` (default: `10`) and `--graphql-block-height-min-timeout` (default: `30s`). If a request requires a specific block height and the node is slightly behind, it will wait instead of failing. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Service definition for state root service. |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Add feature-flagged field to block header `fault_proving_header` that contains a commitment to all transaction ids. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Removed public accessors for `BlockHeader` fields and replaced with methods instead, moved `tx_id_commitment` to the application header of `BlockHeaderV2`. |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Graphql requests and responses make use of a new `extensions` object to specify request/response metadata. A request `extensions` object can contain an integer-valued `required_fuel_block_height` field. When specified, the request will return an error unless the node's current fuel block height is at least the value specified in the `required_fuel_block_height` field. All graphql responses now contain an integer-valued `current_fuel_block_height` field in the `extensions` object, which contains the block height of the last block processed by the node. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Added cleaner error for wasm-executor upon failed deserialization. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Update the default value for `--max-block-size` and `--max-transmit-size` to 50 MB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Change the way we are building the changelog to avoids conflicts. |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Improved performance of fetching block height by caching it when the view is created. |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
## Version [X.X.X (example: 2.3.8)] | ||
|
||
[ADD LABEL PR RELEASE AND DO NOT EDIT THE REST CI WILL GENERATE IT] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
## Linked Issues/PRs | ||
<!-- List of related issues/PRs --> | ||
|
||
## Description | ||
<!-- List of detailed changes --> | ||
|
||
## Checklist | ||
- [ ] Breaking changes are clearly marked as such in the PR description and changelog | ||
- [ ] New behavior is reflected in tests | ||
- [ ] [The specification](https://github.com/FuelLabs/fuel-specs/) matches the implemented behavior (link update PR if changes are needed) | ||
|
||
### Before requesting review | ||
- [ ] I have reviewed the code myself | ||
- [ ] I have created follow-up issues caused by this PR and linked them here | ||
|
||
### After merging, notify other teams | ||
|
||
[Add or remove entries as needed] | ||
|
||
- [ ] [Rust SDK](https://github.com/FuelLabs/fuels-rs/) | ||
- [ ] [Sway compiler](https://github.com/FuelLabs/sway/) | ||
- [ ] [Platform documentation](https://github.com/FuelLabs/devrel-requests/issues/new?assignees=&labels=new+request&projects=&template=NEW-REQUEST.yml&title=%5BRequest%5D%3A+) (for out-of-organization contributors, the person merging the PR will do this) | ||
- [ ] Someone else? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,4 @@ | ||
## Linked Issues/PRs | ||
<!-- List of related issues/PRs --> | ||
Please go to the `Preview` tab and select the appropriate sub-template: | ||
|
||
## Description | ||
<!-- List of detailed changes --> | ||
|
||
## Checklist | ||
- [ ] Breaking changes are clearly marked as such in the PR description and changelog | ||
- [ ] New behavior is reflected in tests | ||
- [ ] [The specification](https://github.com/FuelLabs/fuel-specs/) matches the implemented behavior (link update PR if changes are needed) | ||
|
||
### Before requesting review | ||
- [ ] I have reviewed the code myself | ||
- [ ] I have created follow-up issues caused by this PR and linked them here | ||
|
||
### After merging, notify other teams | ||
|
||
[Add or remove entries as needed] | ||
|
||
- [ ] [Rust SDK](https://github.com/FuelLabs/fuels-rs/) | ||
- [ ] [Sway compiler](https://github.com/FuelLabs/sway/) | ||
- [ ] [Platform documentation](https://github.com/FuelLabs/devrel-requests/issues/new?assignees=&labels=new+request&projects=&template=NEW-REQUEST.yml&title=%5BRequest%5D%3A+) (for out-of-organization contributors, the person merging the PR will do this) | ||
- [ ] Someone else? | ||
* [Classic PR](?expand=1&template=default.md) | ||
* [Bump version](?expand=1&template=bump_version.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
name: Create version | ||
|
||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
types: [opened, synchronize, reopened, labeled, unlabeled] | ||
|
||
jobs: | ||
create_version: | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
runs-on: ubuntu-latest | ||
if: ${{ github.event.label.name == 'pr release' }} | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.pull_request.head.ref }} | ||
|
||
- name: Get the version number in the PR description | ||
id: get_version | ||
run: | | ||
# Extract the version number from the PR description | ||
version=$(echo "${{ github.event.pull_request.body }}" | grep -oP '## Version \K[0-9]+\.[0-9]+\.[0-9]+') | ||
echo "NEW_VERSION=${version}" >> $GITHUB_OUTPUT | ||
- name: Gather all changes | ||
id: gather_changes | ||
run: | | ||
# Define the order of sections | ||
sections_order=("breaking" "added" "changed" "fixed" "removed") | ||
# Process each section in the specified order | ||
for section in "${sections_order[@]}"; do | ||
dir_path=".changes/${section}" | ||
if [ -d "$dir_path" ]; then | ||
# Collect .md files sorted numerically using version sort | ||
files=() | ||
while IFS= read -r -d $'\0' file; do | ||
files+=("$file") | ||
done < <(find "$dir_path" -maxdepth 1 -type f -name '*.md' -print0 | sort -V -z) | ||
if [ ${#files[@]} -gt 0 ]; then | ||
# Capitalize the first letter of the section name | ||
section_name="$(tr '[:lower:]' '[:upper:]' <<< "${section:0:1}")${section:1}" | ||
VERSION_TEXT+="\n### $section_name\n" | ||
for file in "${files[@]}"; do | ||
filename=$(basename "$file" .md) | ||
content=$(cat "$file") | ||
VERSION_TEXT+="- [${filename}](https://github.com/FuelLabs/fuel-core/pull/${filename}): ${content}\n" | ||
done | ||
fi | ||
fi | ||
done | ||
{ | ||
echo 'VERSION_TEXT<<EOF' | ||
echo -e ${VERSION_TEXT} | ||
echo EOF | ||
} >> "$GITHUB_OUTPUT" | ||
- name: Update PR description with the version and changes | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
# Update the PR description with the version and changes | ||
gh pr edit ${{ github.event.pull_request.number }} --body "## Version ${{ steps.get_version.outputs.NEW_VERSION }} | ||
${{ steps.gather_changes.outputs.VERSION_TEXT }}" | ||
- name: Update the CHANGELOG.md file | ||
run: | | ||
while IFS= read -r line; do | ||
if [[ "$line" == "## [Unreleased (see .changes folder)]" ]]; then | ||
echo -e "## [Unreleased (see .changes folder)]\n" | ||
echo -e "## [Version ${{ steps.get_version.outputs.NEW_VERSION }}]" | ||
VERSION_TEXT="${{ steps.gather_changes.outputs.VERSION_TEXT }}" | ||
VERSION_TEXT=${VERSION_TEXT::-1} | ||
echo -e "$VERSION_TEXT" | ||
else | ||
printf "%s\n" "$line" | ||
fi | ||
done < CHANGELOG.md > CHANGELOG.md.tmp && mv CHANGELOG.md.tmp CHANGELOG.md | ||
cat CHANGELOG.md | ||
- name: Delete all the .md files in the .changes directory | ||
run: | | ||
find .changes -type f -name '*.md' -delete | ||
- name: Commit & push the changes | ||
run: | | ||
git config user.name 'github-actions[bot]' | ||
git config user.email 'github-actions[bot]@users.noreply.github.com' | ||
git add CHANGELOG.md | ||
git add .changes | ||
git commit -m "Generate changelog for v.${{ steps.get_version.outputs.NEW_VERSION }}" | ||
git push |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters