feat: add v3 balance changes endpoints #3526
Workflow file for this run
This file contains hidden or 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
| name: CI | |
| on: | |
| push: | |
| branches: | |
| - master | |
| - develop | |
| - beta | |
| - next | |
| tags-ignore: | |
| - "**" | |
| paths-ignore: | |
| - "**/CHANGELOG.md" | |
| - "**/package.json" | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Use Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: ".nvmrc" | |
| # https://github.com/actions/cache/blob/main/examples.md#node---npm | |
| - name: Get npm cache directory | |
| id: npm-cache-dir | |
| shell: bash | |
| run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT} | |
| - name: Cache node modules | |
| uses: actions/cache@v5 | |
| id: npm-cache # use this to check for `cache-hit` ==> if: steps.npm-cache.outputs.cache-hit != 'true' | |
| with: | |
| path: ${{ steps.npm-cache-dir.outputs.dir }} | |
| key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
| restore-keys: | | |
| ${{ runner.os }}-node- | |
| - name: Install deps | |
| run: npm ci --audit=false | |
| - name: Lint ESLint | |
| run: npm run lint:eslint | |
| - name: Lint Prettier | |
| run: npm run lint:prettier | |
| test: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| suite: | |
| [ | |
| api:blocks, | |
| api:bns, | |
| api:cache, | |
| api:datastore, | |
| api:event-replay, | |
| api:event-server, | |
| api:mempool, | |
| api:microblocks, | |
| api:principal, | |
| api:redis, | |
| api:smart-contracts, | |
| api:sockets, | |
| api:synthetic-txs, | |
| api:transactions, | |
| api:v2-proxy, | |
| api:v3, | |
| krypton:bns-e2e, | |
| krypton:faucet-btc, | |
| krypton:faucet-stx, | |
| krypton:pox-4-btc-address-formats, | |
| krypton:pox-4-burnchain-delegate-stx, | |
| krypton:pox-4-burnchain-stack-stx, | |
| krypton:pox-4-delegate-aggregation, | |
| krypton:pox-4-delegate-revoked-stacking, | |
| krypton:pox-4-delegate-stacking, | |
| krypton:pox-4-stack-extend-increase, | |
| krypton:rpc, | |
| snp, | |
| ] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Use Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: ".nvmrc" | |
| # https://github.com/actions/cache/blob/main/examples.md#node---npm | |
| - name: Get npm cache directory | |
| id: npm-cache-dir | |
| shell: bash | |
| run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT} | |
| - name: Cache node modules | |
| uses: actions/cache@v5 | |
| id: npm-cache # use this to check for `cache-hit` ==> if: steps.npm-cache.outputs.cache-hit != 'true' | |
| with: | |
| path: ${{ steps.npm-cache-dir.outputs.dir }} | |
| key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
| restore-keys: | | |
| ${{ runner.os }}-node- | |
| - name: Install deps | |
| run: npm ci --audit=false | |
| - name: Install client deps | |
| working-directory: client | |
| run: npm ci --audit=false | |
| - name: Setup replay directory permissions | |
| if: matrix.suite == 'api:event-replay' | |
| run: | | |
| mkdir -p tests/api/event-replay/.tmp/local/ | |
| sudo chown 999:999 tests/api/event-replay/.tmp/local/ | |
| sudo chmod -R 777 tests/api/event-replay/.tmp/local/ | |
| - name: Run tests | |
| run: npx c8 --reporter=lcov npm run test:${{ matrix.suite }} | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| if: always() | |
| build-publish: | |
| runs-on: ubuntu-latest | |
| needs: [lint, test] | |
| permissions: | |
| packages: write | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up QEMU | |
| uses: docker/setup-qemu-action@v4 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v4 | |
| - name: Docker Meta | |
| id: docker_meta | |
| uses: docker/metadata-action@v6 | |
| with: | |
| # TODO: Add ghcr after migrating to stx-labs | |
| images: | | |
| hirosystems/${{ github.event.repository.name }} | |
| tags: | | |
| type=ref,event=branch | |
| type=ref,event=pr | |
| - name: Login to DockerHub | |
| uses: docker/login-action@v4 | |
| with: | |
| username: ${{ secrets.DOCKERHUB_USERNAME }} | |
| password: ${{ secrets.DOCKERHUB_PASSWORD }} | |
| - name: Build/Tag/Push Image | |
| uses: docker/build-push-action@v7 | |
| with: | |
| context: . | |
| platforms: ${{ github.ref == 'refs/heads/master' && 'linux/amd64,linux/arm64' || 'linux/amd64' }} | |
| tags: ${{ steps.docker_meta.outputs.tags }} | |
| labels: ${{ steps.docker_meta.outputs.labels }} | |
| # Only push on non-PR events, or PRs that aren't from forks | |
| push: ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }} |