Skip to content

Commit

Permalink
Merge pull request #5852 from stacks-network/develop-into-clarity-was…
Browse files Browse the repository at this point in the history
…m-develop

Merge develop into feat/clarity-wasm-develop
  • Loading branch information
csgui authored Feb 25, 2025
2 parents 90ff09e + bc738d1 commit c78b57e
Show file tree
Hide file tree
Showing 395 changed files with 21,189 additions and 18,524 deletions.
1 change: 1 addition & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
[alias]
stacks-node = "run --package stacks-node --"
fmt-stacks = "fmt -- --config group_imports=StdExternalCrate,imports_granularity=Module"
clippy-stacks = "clippy -p libstackerdb -p stacks-signer -p pox-locking -p clarity -p libsigner -p stacks-common --no-deps --tests --all-features -- -D warnings"

# Uncomment to improve performance slightly, at the cost of portability
# * Note that native binaries may not run on CPUs that are different from the build machine
Expand Down
7 changes: 3 additions & 4 deletions .github/actions/dockerfiles/Dockerfile.alpine-binary
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@ ARG TARGETVARIANT
ARG REPO

RUN case ${TARGETPLATFORM} in \
linux/amd64/v2) BIN_ARCH=linux-glibc-x64-v2 ;; \
linux/amd64*) BIN_ARCH=linux-glibc-x64 ;; \
linux/arm64*) BIN_ARCH=linux-glibc-arm64 ;; \
linux/arm/v7) BIN_ARCH=linux-glibc-armv7 ;; \
linux/amd64*) BIN_ARCH=linux-musl-x64 ;; \
linux/arm64*) BIN_ARCH=linux-musl-arm64 ;; \
linux/arm/v7) BIN_ARCH=linux-musl-armv7 ;; \
*) exit 1 ;; \
esac \
&& echo "TARGETPLATFORM: $TARGETPLATFORM" \
Expand Down
1 change: 0 additions & 1 deletion .github/actions/dockerfiles/Dockerfile.debian-binary
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ ARG TARGETVARIANT
ARG REPO

RUN case ${TARGETPLATFORM} in \
linux/amd64/v2) BIN_ARCH=linux-glibc-x64-v2 ;; \
linux/amd64*) BIN_ARCH=linux-glibc-x64 ;; \
linux/arm64*) BIN_ARCH=linux-glibc-arm64 ;; \
linux/arm/v7) BIN_ARCH=linux-glibc-armv7 ;; \
Expand Down
230 changes: 94 additions & 136 deletions .github/workflows/bitcoin-tests.yml

Large diffs are not rendered by default.

183 changes: 79 additions & 104 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,47 +52,66 @@ jobs:

######################################################################################
## Check if the branch that this workflow is being run against is a release branch
##
## Outputs:
## - node_tag: Tag of the stacks-node if the branch is a release one (example: release/3.4.0.0.1), null otherwise
## - node_docker_tag: Version of the stacks-node if the branch is a release one (example: 3.4.0.0.1), null otherwise
## - signer_tag: Tag of the stacks-signer if the branch is a release one (example: release/3.4.0.0.1.0), null otherwise
## - signer_docker_tag: Version of the stacks-signer if the branch is a release one (example: 3.4.0.0.1.0), null otherwise
## - is_node_release: True if the branch represents a 'stacks-node' release, false otherwise.
## If this is true, 'is_signer_release' will also be true, since a 'stacks-signer' binary
## is always released alongside 'stacks-node'.
## - is_signer_release: True if the branch represents a 'stacks-signer' release, false otherwise.
check-release:
name: Check Release
needs:
- rustfmt
runs-on: ubuntu-latest
outputs:
tag: ${{ steps.check_release.outputs.tag }}
docker_tag: ${{ steps.check_release.outputs.docker_tag }}
is_release: ${{ steps.check_release.outputs.is_release }}
node_tag: ${{ steps.check_release.outputs.node_tag }}
node_docker_tag: ${{ steps.check_release.outputs.node_docker_tag }}
signer_tag: ${{ steps.check_release.outputs.signer_tag }}
signer_docker_tag: ${{ steps.check_release.outputs.signer_docker_tag }}
is_node_release: ${{ steps.check_release.outputs.is_node_release }}
is_signer_release: ${{ steps.check_release.outputs.is_signer_release }}
steps:
- name: Check Release
id: check_release
uses: stacks-network/actions/stacks-core/check-release@main
uses: stacks-network/actions/stacks-core/release/check-release@main
with:
tag: ${{ github.ref_name }}

######################################################################################
## Create a tagged github release
##
## Runs when:
## - it is a release run
## - it is either a node release or a signer release
create-release:
if: |
needs.check-release.outputs.is_release == 'true'
name: Create Release
needs.check-release.outputs.is_node_release == 'true' ||
needs.check-release.outputs.is_signer_release == 'true'
name: Create Release(s)
needs:
- rustfmt
- check-release
uses: ./.github/workflows/github-release.yml
with:
tag: ${{ needs.check-release.outputs.tag }}
docker_tag: ${{ needs.check-release.outputs.docker_tag }}
node_tag: ${{ needs.check-release.outputs.node_tag }}
node_docker_tag: ${{ needs.check-release.outputs.node_docker_tag }}
signer_tag: ${{ needs.check-release.outputs.signer_tag }}
signer_docker_tag: ${{ needs.check-release.outputs.signer_docker_tag }}
is_node_release: ${{ needs.check-release.outputs.is_node_release }}
is_signer_release: ${{ needs.check-release.outputs.is_signer_release }}
secrets: inherit

## Build and push Debian image built from source
##
## Runs when:
## - it is not a release run
## - it is not a node or signer-only release run
docker-image:
if: |
needs.check-release.outputs.is_release != 'true'
needs.check-release.outputs.is_node_release != 'true' ||
needs.check-release.outputs.is_signer_release != 'true'
name: Docker Image (Source)
uses: ./.github/workflows/image-build-source.yml
needs:
Expand All @@ -103,28 +122,17 @@ jobs:
## Create a reusable cache for tests
##
## Runs when:
## - it is a release run
## or:
## - it is not a release run
## and any of:
## - this workflow is called manually
## - PR is opened
## - commit to either (development, master) branch
## - it is a node release run
## or any of:
## - this workflow is called manually
## - PR is opened
## - PR added to merge queue
create-cache:
if: |
needs.check-release.outputs.is_release == 'true' || (
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group' ||
(
contains('
refs/heads/master
refs/heads/develop
refs/heads/next
', github.event.pull_request.head.ref) &&
github.event_name == 'push'
)
)
needs.check-release.outputs.is_node_release == 'true' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group'
name: Create Test Cache
needs:
- rustfmt
Expand All @@ -134,29 +142,18 @@ jobs:
## Tests to run regularly
##
## Runs when:
## - it is a release run
## or:
## - it is not a release run
## and any of:
## - this workflow is called manually
## - PR is opened
## - PR added to merge queue
## - commit to either (development, next, master) branch
## - it is a node or signer-only release run
## or any of:
## - this workflow is called manually
## - PR is opened
## - PR added to merge queue
stacks-core-tests:
if: |
needs.check-release.outputs.is_release == 'true' || (
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group' ||
(
contains('
refs/heads/master
refs/heads/develop
refs/heads/next
', github.event.pull_request.head.ref) &&
github.event_name == 'push'
)
)
needs.check-release.outputs.is_node_release == 'true' ||
needs.check-release.outputs.is_signer_release == 'true' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group'
name: Stacks Core Tests
needs:
- rustfmt
Expand All @@ -167,73 +164,51 @@ jobs:
## Checks to run on built binaries
##
## Runs when:
## - it is a release run
## or:
## - it is not a release run
## and any of:
## - this workflow is called manually
## - PR is opened
## - PR added to merge queue
## - commit to either (development, next, master) branch
## - it is a node or signer-only release run
## or any of:
## - this workflow is called manually
## - PR is opened
## - PR added to merge queue
stacks-core-build-tests:
if: |
needs.check-release.outputs.is_release == 'true' || (
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group' ||
(
contains('
refs/heads/master
refs/heads/develop
refs/heads/next
', github.event.pull_request.head.ref) &&
github.event_name == 'push'
)
)
needs.check-release.outputs.is_node_release == 'true' ||
needs.check-release.outputs.is_signer_release == 'true' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group'
name: Stacks Core Build Tests
needs:
- rustfmt
- check-release
uses: ./.github/workflows/core-build-tests.yml

## Checks to run on built binaries
##
## Runs when:
## - it is a node release run
## or any of:
## - this workflow is called manually
## - PR is opened
## - PR added to merge queue
bitcoin-tests:
if: |
needs.check-release.outputs.is_release == 'true' || (
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group' ||
(
contains('
refs/heads/master
refs/heads/develop
refs/heads/next
', github.event.pull_request.head.ref) &&
github.event_name == 'push'
)
)
needs.check-release.outputs.is_node_release == 'true' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group'
name: Bitcoin Tests
needs:
- rustfmt
- create-cache
- check-release
uses: ./.github/workflows/bitcoin-tests.yml


p2p-tests:
if: |
needs.check-release.outputs.is_release == 'true' || (
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group' ||
(
contains('
refs/heads/master
refs/heads/develop
refs/heads/next
', github.event.pull_request.head.ref) &&
github.event_name == 'push'
)
)
needs.check-release.outputs.is_node_release == 'true' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'pull_request' ||
github.event_name == 'merge_group'
name: P2P Tests
needs:
- rustfmt
Expand All @@ -244,9 +219,9 @@ jobs:
## Test to run on a tagged release
##
## Runs when:
## - it is a release run
## - it is a node release run
atlas-tests:
if: needs.check-release.outputs.is_release == 'true'
if: needs.check-release.outputs.is_node_release == 'true'
name: Atlas Tests
needs:
- rustfmt
Expand All @@ -255,7 +230,7 @@ jobs:
uses: ./.github/workflows/atlas-tests.yml

epoch-tests:
if: needs.check-release.outputs.is_release == 'true'
if: needs.check-release.outputs.is_node_release == 'true'
name: Epoch Tests
needs:
- rustfmt
Expand All @@ -264,7 +239,7 @@ jobs:
uses: ./.github/workflows/epoch-tests.yml

slow-tests:
if: needs.check-release.outputs.is_release == 'true'
if: needs.check-release.outputs.is_node_release == 'true'
name: Slow Tests
needs:
- rustfmt
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/clippy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,4 @@ jobs:
components: clippy
- name: Clippy
id: clippy
uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: -p libstackerdb -p stacks-signer -p pox-locking -p clarity -p libsigner -p stacks-common --no-deps --tests --all-features -- -D warnings
run: cargo clippy-stacks
60 changes: 0 additions & 60 deletions .github/workflows/create-source-binary.yml

This file was deleted.

Loading

0 comments on commit c78b57e

Please sign in to comment.