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

update blockscout latest master changes #17

Merged
merged 3 commits into from
May 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ updates:
directory: "/apps/block_scout_web/assets"
open-pull-requests-limit: 10
schedule:
interval: "weekly"
interval: "monthly"
ignore:
- dependency-name: "bootstrap"
- dependency-name: "web3"
Expand All @@ -20,4 +20,4 @@ updates:
directory: "/apps/explorer"
open-pull-requests-limit: 10
schedule:
interval: "weekly"
interval: "monthly"
10 changes: 5 additions & 5 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ name: "CodeQL"

on:
push:
branches: [ "master" ]
branches: [ "subspace-backend" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "master" ]
branches: [ "subspace-backend" ]
schedule:
- cron: '45 11 * * 5'

Expand Down Expand Up @@ -48,11 +48,11 @@ jobs:
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality


# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
Expand All @@ -61,7 +61,7 @@ jobs:
# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# If the Autobuild fails above, remove it and uncomment the following three lines.
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.

# - run: |
Expand Down
107 changes: 75 additions & 32 deletions .github/workflows/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,39 +3,21 @@ name: Blockscout
on:
push:
branches:
- master
- production-core
- production-eth-experimental
- production-eth-goerli
- production-eth-sepolia
- production-fuse
- production-optimism
- production-immutable
- production-iota
- production-lukso
- production-rsk
- production-sokol
- production-suave
- production-xdai
- production-zkevm
- production-zksync
- staging-l2
- subspace-backend
paths-ignore:
- 'CHANGELOG.md'
- '**/README.md'
- 'docker/*'
- 'docker-compose/*'
pull_request:
types: [opened, synchronize, reopened, labeled]
branches:
- master
- production-optimism
- production-zksync
- subspace-backend

env:
MIX_ENV: test
OTP_VERSION: ${{ vars.OTP_VERSION }}
ELIXIR_VERSION: ${{ vars.ELIXIR_VERSION }}
ACCOUNT_AUTH0_DOMAIN: "blockscoutcom.us.auth0.com"
OTP_VERSION: ${{ vars.OTP_VERSION || '25.3.2.8' }}
ELIXIR_VERSION: ${{ vars.ELIXIR_VERSION || '1.14.5' }}

jobs:
matrix-builder:
Expand All @@ -46,9 +28,30 @@ jobs:
steps:
- id: set-matrix
run: |
echo "matrix=$matrixStringifiedObject" >> $GITHUB_OUTPUT
env:
matrixStringifiedObject: '{"chain-type": ["ethereum", "polygon_edge", "polygon_zkevm", "rsk", "suave", "stability", "filecoin"]}'
echo "matrix=$(node -e '

// Add/remove CI matrix chain types here
const defaultChainTypes = ["default"];
const chainTypes = ["ethereum", "polygon_zkevm", "rsk", "stability", "filecoin", "optimism", "arbitrum"];
const extraChainTypes = ["suave", "polygon_edge"];

// Chain type matrix we use in master branch
const allChainTypes = [].concat(defaultChainTypes, chainTypes, extraChainTypes);

const labels = ${{ github.event_name == 'pull_request' && toJson(github.event.pull_request.labels.*.name) || '[]' }};
const ciLabels = labels.filter(label => label.startsWith("ci:"));
const labeledChainTypes = [].concat(
defaultChainTypes.filter(chainType => ciLabels.includes("ci:" + chainType)),
chainTypes.filter(chainType => ciLabels.includes("ci:all") || ciLabels.includes("ci:" + chainType)),
extraChainTypes.filter(chainType => ciLabels.includes("ci:" + chainType))
);

// Chain type matrix we use in PRs to master branch
const ciChainTypes = labeledChainTypes.length > 0 ? labeledChainTypes : defaultChainTypes;

const matrix = { "chain-type": ${{ github.event_name == 'pull_request' && 'ciChainTypes' || 'allChainTypes' }} };
console.log(JSON.stringify(matrix));
')" >> $GITHUB_OUTPUT

build-and-cache:
name: Build and Cache deps
Expand All @@ -59,6 +62,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: "ELIXIR_VERSION.lock"
run: echo "${ELIXIR_VERSION}" > ELIXIR_VERSION.lock
Expand Down Expand Up @@ -123,6 +129,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Restore Mix Deps Cache
uses: actions/cache/restore@v4
Expand All @@ -147,6 +156,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Restore Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -176,6 +188,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Restore Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -203,12 +218,12 @@ jobs:
mkdir -p priv/plts
mix dialyzer --plt
env:
CHAIN_TYPE: ${{ matrix.chain-type }}
CHAIN_TYPE: ${{ matrix.chain-type != 'default' && matrix.chain-type || '' }}

- name: Run Dialyzer
run: mix dialyzer --halt-exit-status
env:
CHAIN_TYPE: ${{ matrix.chain-type }}
CHAIN_TYPE: ${{ matrix.chain-type != 'default' && matrix.chain-type || '' }}

gettext:
name: Missing translation keys check
Expand All @@ -220,6 +235,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Restore Mix Deps Cache
uses: actions/cache/restore@v4
Expand All @@ -246,6 +264,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -275,6 +296,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -323,6 +347,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -369,6 +396,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -431,6 +461,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand All @@ -456,7 +489,7 @@ jobs:
PGUSER: postgres
ETHEREUM_JSONRPC_CASE: "EthereumJSONRPC.Case.Nethermind.Mox"
ETHEREUM_JSONRPC_WEB_SOCKET_CASE: "EthereumJSONRPC.WebSocket.Case.Mox"
CHAIN_TYPE: "${{ matrix.chain-type }}"
CHAIN_TYPE: ${{ matrix.chain-type != 'default' && matrix.chain-type || '' }}
test_nethermind_mox_explorer:
strategy:
fail-fast: false
Expand Down Expand Up @@ -491,6 +524,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -527,7 +563,7 @@ jobs:
PGUSER: postgres
ETHEREUM_JSONRPC_CASE: "EthereumJSONRPC.Case.Nethermind.Mox"
ETHEREUM_JSONRPC_WEB_SOCKET_CASE: "EthereumJSONRPC.WebSocket.Case.Mox"
CHAIN_TYPE: "${{ matrix.chain-type }}"
CHAIN_TYPE: ${{ matrix.chain-type != 'default' && matrix.chain-type || '' }}
test_nethermind_mox_indexer:
strategy:
fail-fast: false
Expand Down Expand Up @@ -562,6 +598,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -590,7 +629,7 @@ jobs:
PGUSER: postgres
ETHEREUM_JSONRPC_CASE: "EthereumJSONRPC.Case.Nethermind.Mox"
ETHEREUM_JSONRPC_WEB_SOCKET_CASE: "EthereumJSONRPC.WebSocket.Case.Mox"
CHAIN_TYPE: "${{ matrix.chain-type }}"
CHAIN_TYPE: ${{ matrix.chain-type != 'default' && matrix.chain-type || '' }}
test_nethermind_mox_block_scout_web:
strategy:
fail-fast: false
Expand Down Expand Up @@ -630,6 +669,9 @@ jobs:
with:
otp-version: ${{ env.OTP_VERSION }}
elixir-version: ${{ env.ELIXIR_VERSION }}
hexpm-mirrors: |
https://builds.hex.pm
https://cdn.jsdelivr.net/hex

- name: Mix Deps Cache
uses: actions/cache/restore@v4
Expand Down Expand Up @@ -682,8 +724,9 @@ jobs:
ETHEREUM_JSONRPC_WEB_SOCKET_CASE: "EthereumJSONRPC.WebSocket.Case.Mox"
CHAIN_ID: "10200"
API_RATE_LIMIT_DISABLED: "true"
API_GRAPHQL_RATE_LIMIT_DISABLED: "true"
ADMIN_PANEL_ENABLED: "true"
ACCOUNT_ENABLED: "true"
ACCOUNT_REDIS_URL: "redis://localhost:6379"
SOURCIFY_INTEGRATION_ENABLED: "true"
CHAIN_TYPE: "${{ matrix.chain-type }}"
CHAIN_TYPE: ${{ matrix.chain-type != 'default' && matrix.chain-type || '' }}
1 change: 0 additions & 1 deletion .github/workflows/deploy-subspace.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ jobs:
cache-to: type=gha,mode=max
tags: ghcr.io/${{ github.repository_owner }}/blockscout-backend:${{ env.TAG_NAME }}
platforms: |
linux/arm64
linux/amd64
build-args: |
CACHE_EXCHANGE_RATES_PERIOD=
Expand Down
77 changes: 0 additions & 77 deletions .github/workflows/prerelease.yml

This file was deleted.

Loading
Loading