From 0b0b5d9d933b72da81df511140a871187ecd3a53 Mon Sep 17 00:00:00 2001 From: ericlee Date: Wed, 14 Dec 2022 14:45:55 +0800 Subject: [PATCH 01/29] ignore receipt fileds for metis --- apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex index 3ecad95d68..62181ef23f 100644 --- a/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex +++ b/apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/receipt.ex @@ -304,6 +304,11 @@ defmodule EthereumJSONRPC.Receipt do :ignore end + # Metis fields + defp entry_to_elixir({key, _}) when key in ~w(l1GasUsed l1GasPrice l1FeeScalar l1Fee) do + :ignore + end + # GoQuorum specific transaction receipt fields defp entry_to_elixir({key, _}) when key in ~w(isPrivacyMarkerTransaction) do :ignore From 3fd79156bc0fbb4493af1fdfd723d3b0789679ec Mon Sep 17 00:00:00 2001 From: Yuliya Sharafitdinova Date: Wed, 14 Dec 2022 11:56:58 +0300 Subject: [PATCH 02/29] Add latest image for frontend-main --- .../publish-docker-image-every-push.yml | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.github/workflows/publish-docker-image-every-push.yml b/.github/workflows/publish-docker-image-every-push.yml index ec503dd9d1..fbe8745970 100644 --- a/.github/workflows/publish-docker-image-every-push.yml +++ b/.github/workflows/publish-docker-image-every-push.yml @@ -70,6 +70,31 @@ jobs: DISABLE_BRIDGE_MARKET_CAP_UPDATER=false CACHE_BRIDGE_MARKET_CAP_UPDATE_INTERVAL= SOCKET_ROOT= + + - name: Build and push Docker image for frontend + uses: docker/build-push-action@v3 + with: + context: . + file: ./docker/Dockerfile + push: true + cache-from: type=registry,ref=blockscout/blockscout:buildcache + cache-to: type=registry,ref=blockscout/blockscout:buildcache,mode=max + tags: blockscout/blockscout:frontend-main + build-args: | + CACHE_EXCHANGE_RATES_PERIOD= + DISABLE_READ_API=false + API_PATH= + NETWORK_PATH= + DISABLE_WEBAPP=false + DISABLE_WRITE_API=false + CACHE_ENABLE_TOTAL_GAS_USAGE_COUNTER= + WOBSERVER_ENABLED=false + ADMIN_PANEL_ENABLED=false + CACHE_ADDRESS_WITH_BALANCES_UPDATE_INTERVAL= + DISABLE_BRIDGE_MARKET_CAP_UPDATER=false + CACHE_BRIDGE_MARKET_CAP_UPDATE_INTERVAL= + SOCKET_ROOT= + SESSION_COOKIE_DOMAIN=blockscout.com tests: needs: push_to_registry uses: blockscout/blockscout-ci-cd/.github/workflows/e2e_new.yaml@master From 87d7544aee9c7533e3ec1a1792a13372e835dfca Mon Sep 17 00:00:00 2001 From: Yuliya Sharafitdinova Date: Wed, 14 Dec 2022 12:01:29 +0300 Subject: [PATCH 03/29] Add latest image for frontend-main --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 029847ccb7..0a06118021 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -64,6 +64,7 @@ ### Chore +- [#6588](https://github.com/blockscout/blockscout/pull/6588) - Add latest image build for frontend-main with specific build-args - [#6584](https://github.com/blockscout/blockscout/pull/6584) - Vacuum package-lock.json - [#6581](https://github.com/blockscout/blockscout/pull/6581) - Dark mode switcher localStorage to cookie in order to support new UI - [#6572](https://github.com/blockscout/blockscout/pull/6572) - pending_block_operations table: remove fetch_internal_transactions column From cc0973fe40fcdd33b8581e4fa7e1ad660bac0175 Mon Sep 17 00:00:00 2001 From: Yuliya Sharafitdinova Date: Wed, 14 Dec 2022 12:23:50 +0300 Subject: [PATCH 04/29] fix build job --- .github/workflows/publish-docker-image-every-push.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/publish-docker-image-every-push.yml b/.github/workflows/publish-docker-image-every-push.yml index fbe8745970..c08b133069 100644 --- a/.github/workflows/publish-docker-image-every-push.yml +++ b/.github/workflows/publish-docker-image-every-push.yml @@ -78,7 +78,6 @@ jobs: file: ./docker/Dockerfile push: true cache-from: type=registry,ref=blockscout/blockscout:buildcache - cache-to: type=registry,ref=blockscout/blockscout:buildcache,mode=max tags: blockscout/blockscout:frontend-main build-args: | CACHE_EXCHANGE_RATES_PERIOD= From 3442d427711ca616c43c2181dfadaadfa49ad706 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=A7=C3=BE?= <12281088+helderjnpinto@users.noreply.github.com> Date: Thu, 15 Dec 2022 15:41:40 +0000 Subject: [PATCH 05/29] Fix wrong h1 closing tag --- .../lib/block_scout_web/templates/api_docs/eth_rpc.html.eex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/block_scout_web/lib/block_scout_web/templates/api_docs/eth_rpc.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/api_docs/eth_rpc.html.eex index ac80b13597..24f78423fc 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/api_docs/eth_rpc.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/api_docs/eth_rpc.html.eex @@ -1,7 +1,7 @@
-

<%= gettext("ETH RPC API Documentation") %>

+

<%= gettext("ETH RPC API Documentation") %>

[ <%= gettext "Base URL:" %> <%= eth_rpc_api_url()%> ]

<%= gettext "This API is provided to support some rpc methods in the exact format specified for ethereum nodes, which can be found " %> From d18c346ffc3eb8d27237a9a14adb6b0364d6b981 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=A7=C3=BE?= <12281088+helderjnpinto@users.noreply.github.com> Date: Thu, 15 Dec 2022 16:16:50 +0000 Subject: [PATCH 06/29] Unhandled division by 0 Fix the division if is 0 --- apps/indexer/lib/indexer/block/fetcher.ex | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/indexer/lib/indexer/block/fetcher.ex b/apps/indexer/lib/indexer/block/fetcher.ex index 929d769550..e92720b7b4 100644 --- a/apps/indexer/lib/indexer/block/fetcher.ex +++ b/apps/indexer/lib/indexer/block/fetcher.ex @@ -238,7 +238,8 @@ defmodule Indexer.Block.Fetcher do {import_time, result} = :timer.tc(fn -> callback_module.import(state, options_with_broadcast) end) no_blocks_to_import = length(options_with_broadcast.blocks.params) - Prometheus.Instrumenter.block_import(import_time / no_blocks_to_import, callback_module) + no_blocks_to_import_div = if Decimal.compare(no_blocks_to_import, 0) == :eq, do: 1, else: no_blocks_to_import + Prometheus.Instrumenter.block_import(import_time / no_blocks_to_import_div, callback_module) result end From 6db747903d1ba61d5af18dd6548aea4f57ccee79 Mon Sep 17 00:00:00 2001 From: Viktor Baranov Date: Thu, 15 Dec 2022 22:40:15 +0400 Subject: [PATCH 07/29] Token icon default URL --- CHANGELOG.md | 1 + apps/block_scout_web/assets/js/lib/token_icon.js | 2 +- apps/block_scout_web/assets/package-lock.json | 5 +++-- .../assets/static/images/icons/token_icon_default.svg | 1 + .../block_scout_web/templates/tokens/_token_icon.html.eex | 2 +- .../templates/tokens/_token_icon_default.html.eex | 1 + 6 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 apps/block_scout_web/assets/static/images/icons/token_icon_default.svg create mode 100644 apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon_default.html.eex diff --git a/CHANGELOG.md b/CHANGELOG.md index 0a06118021..8da0f0196e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -64,6 +64,7 @@ ### Chore +- [#6600](https://github.com/blockscout/blockscout/pull/6600) - Token stub icon - [#6588](https://github.com/blockscout/blockscout/pull/6588) - Add latest image build for frontend-main with specific build-args - [#6584](https://github.com/blockscout/blockscout/pull/6584) - Vacuum package-lock.json - [#6581](https://github.com/blockscout/blockscout/pull/6581) - Dark mode switcher localStorage to cookie in order to support new UI diff --git a/apps/block_scout_web/assets/js/lib/token_icon.js b/apps/block_scout_web/assets/js/lib/token_icon.js index 6f283cb3c2..fde9f117e5 100644 --- a/apps/block_scout_web/assets/js/lib/token_icon.js +++ b/apps/block_scout_web/assets/js/lib/token_icon.js @@ -17,7 +17,7 @@ function getTokenIconUrl (chainID, addressHash) { if (chainName) { return `https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/${chainName}/assets/${addressHash}/logo.png` } else { - return null + return '/images/icons/token_icon_default.svg' } } diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index b75bed5004..cd91dd1e6d 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -98,10 +98,11 @@ } }, "../../../deps/phoenix": { - "version": "0.0.1" + "version": "1.5.13", + "license": "MIT" }, "../../../deps/phoenix_html": { - "version": "0.0.1" + "version": "3.0.4" }, "node_modules/@ampproject/remapping": { "version": "2.2.0", diff --git a/apps/block_scout_web/assets/static/images/icons/token_icon_default.svg b/apps/block_scout_web/assets/static/images/icons/token_icon_default.svg new file mode 100644 index 0000000000..5c0579c828 --- /dev/null +++ b/apps/block_scout_web/assets/static/images/icons/token_icon_default.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon.html.eex index b4db9e4079..5ccb004cd2 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon.html.eex @@ -1,2 +1,2 @@ <% token_icon_url = Explorer.Chain.get_token_icon_url_by(@chain_id, @address) %> -" alt="" onerror="this.style.visibility='hidden'"/> \ No newline at end of file +" alt="" onerror="if (this.src != '/images/icons/token_icon_default.svg') this.src = '/images/icons/token_icon_default.svg';"/> \ No newline at end of file diff --git a/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon_default.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon_default.html.eex new file mode 100644 index 0000000000..dd944ad546 --- /dev/null +++ b/apps/block_scout_web/lib/block_scout_web/templates/tokens/_token_icon_default.html.eex @@ -0,0 +1 @@ +" alt=""/> \ No newline at end of file From 536f7aad01c43568501dfccc1af1d5332ad576e0 Mon Sep 17 00:00:00 2001 From: Viktor Baranov Date: Thu, 15 Dec 2022 23:58:52 +0400 Subject: [PATCH 08/29] Add to MM button explorer URL fix --- CHANGELOG.md | 1 + apps/block_scout_web/assets/js/lib/add_chain_to_mm.js | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8da0f0196e..e20ffe71f6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -33,6 +33,7 @@ ### Fixes +- [#6603](https://github.com/blockscout/blockscout/pull/6603) - Add to MM button explorer URL fix - [#6512](https://github.com/blockscout/blockscout/pull/6512) - Allow gasUsed in failed internal txs; Leave error field for staticcall - [#6532](https://github.com/blockscout/blockscout/pull/6532) - Fix index creation migration - [#6473](https://github.com/blockscout/blockscout/pull/6473) - Fix state changes for contract creation transactions diff --git a/apps/block_scout_web/assets/js/lib/add_chain_to_mm.js b/apps/block_scout_web/assets/js/lib/add_chain_to_mm.js index d10820f1da..4ed32dd635 100644 --- a/apps/block_scout_web/assets/js/lib/add_chain_to_mm.js +++ b/apps/block_scout_web/assets/js/lib/add_chain_to_mm.js @@ -8,8 +8,9 @@ export async function addChainToMM ({ btn }) { const coinName = document.getElementById('js-coin-name').value const subNetwork = document.getElementById('js-subnetwork').value const jsonRPC = document.getElementById('js-json-rpc').value + const path = process.env.NETWORK_PATH || '/' - const blockscoutURL = location.protocol + '//' + location.host + process.env.NETWORK_PATH + const blockscoutURL = location.protocol + '//' + location.host + path if (chainIDFromWallet !== chainIDFromInstance) { await window.ethereum.request({ method: 'wallet_addEthereumChain', From ac97a9bba06221740d7806d49e0355a686dde9ac Mon Sep 17 00:00:00 2001 From: hp Date: Fri, 16 Dec 2022 09:52:19 +0000 Subject: [PATCH 09/29] if 0 blocks do not apply prometheus instrumenter --- apps/indexer/lib/indexer/block/fetcher.ex | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/apps/indexer/lib/indexer/block/fetcher.ex b/apps/indexer/lib/indexer/block/fetcher.ex index e92720b7b4..6f2c9f00c4 100644 --- a/apps/indexer/lib/indexer/block/fetcher.ex +++ b/apps/indexer/lib/indexer/block/fetcher.ex @@ -238,8 +238,11 @@ defmodule Indexer.Block.Fetcher do {import_time, result} = :timer.tc(fn -> callback_module.import(state, options_with_broadcast) end) no_blocks_to_import = length(options_with_broadcast.blocks.params) - no_blocks_to_import_div = if Decimal.compare(no_blocks_to_import, 0) == :eq, do: 1, else: no_blocks_to_import - Prometheus.Instrumenter.block_import(import_time / no_blocks_to_import_div, callback_module) + + if no_blocks_to_import != 0 do + Prometheus.Instrumenter.block_import(import_time / no_blocks_to_import, callback_module) + end + result end From ae218f67f493ff2d5fc0f86ad2286ccfebde604c Mon Sep 17 00:00:00 2001 From: Sharafitdinova Date: Fri, 16 Dec 2022 14:18:19 +0300 Subject: [PATCH 10/29] Fix frontend image (#6606) * test latest image for frontend-main * test latest image for frontend-main * add ARG to Dockerfile * update Changelog --- .github/workflows/publish-docker-image-every-push.yml | 2 +- CHANGELOG.md | 1 + docker/Dockerfile | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish-docker-image-every-push.yml b/.github/workflows/publish-docker-image-every-push.yml index c08b133069..e10338a158 100644 --- a/.github/workflows/publish-docker-image-every-push.yml +++ b/.github/workflows/publish-docker-image-every-push.yml @@ -93,7 +93,7 @@ jobs: DISABLE_BRIDGE_MARKET_CAP_UPDATER=false CACHE_BRIDGE_MARKET_CAP_UPDATE_INTERVAL= SOCKET_ROOT= - SESSION_COOKIE_DOMAIN=blockscout.com + SESSION_COOKIE_DOMAIN=${{ secrets.FRONTEND_MAIN }} tests: needs: push_to_registry uses: blockscout/blockscout-ci-cd/.github/workflows/e2e_new.yaml@master diff --git a/CHANGELOG.md b/CHANGELOG.md index e20ffe71f6..4d5ee78755 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -65,6 +65,7 @@ ### Chore +- [#6606](https://github.com/blockscout/blockscout/pull/6600) - Add ARG SESSION_COOKIE_DOMAIN to Dockerfile - [#6600](https://github.com/blockscout/blockscout/pull/6600) - Token stub icon - [#6588](https://github.com/blockscout/blockscout/pull/6588) - Add latest image build for frontend-main with specific build-args - [#6584](https://github.com/blockscout/blockscout/pull/6584) - Vacuum package-lock.json diff --git a/docker/Dockerfile b/docker/Dockerfile index 085430f3b4..00eea0e2cf 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -34,6 +34,7 @@ ARG WOBSERVER_ENABLED ARG ADMIN_PANEL_ENABLED ARG CACHE_ADDRESS_WITH_BALANCES_UPDATE_INTERVAL ARG SOCKET_ROOT +ARG SESSION_COOKIE_DOMAIN # Cache elixir deps ADD mix.exs mix.lock ./ From 6c0d16568e64f4d76c94f9760846bf2a35cc44b6 Mon Sep 17 00:00:00 2001 From: Sharafitdinova Date: Fri, 16 Dec 2022 15:04:06 +0300 Subject: [PATCH 11/29] Run e2e tests after approve (#6607) * Run e2e tests after approve * update Changelog --- .github/workflows/e2e-tests.yml | 6 ++++-- CHANGELOG.md | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index 987f911fe0..9e1d91efdf 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -1,8 +1,8 @@ name: Run E2E tests k8s on: - # push: - pull_request: + pull_request_review: + types: [submitted] workflow_dispatch: env: @@ -15,6 +15,7 @@ env: jobs: push_to_registry: + if: github.event.review.state == 'approved' name: Push Docker image to Docker Hub runs-on: ubuntu-latest outputs: @@ -76,6 +77,7 @@ jobs: deploy_and_tests: needs: push_to_registry + if: github.event.review.state == 'approved' uses: blockscout/blockscout-ci-cd/.github/workflows/e2e_new.yaml@master with: blockscoutImage: blockscout/blockscout:pr-${{ needs.push_to_registry.outputs.short-sha }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 4d5ee78755..78b2ac920c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -65,7 +65,8 @@ ### Chore -- [#6606](https://github.com/blockscout/blockscout/pull/6600) - Add ARG SESSION_COOKIE_DOMAIN to Dockerfile +- [#6607](https://github.com/blockscout/blockscout/pull/6607) - Run e2e tests after PR review +- [#6606](https://github.com/blockscout/blockscout/pull/6606) - Add ARG SESSION_COOKIE_DOMAIN to Dockerfile - [#6600](https://github.com/blockscout/blockscout/pull/6600) - Token stub icon - [#6588](https://github.com/blockscout/blockscout/pull/6588) - Add latest image build for frontend-main with specific build-args - [#6584](https://github.com/blockscout/blockscout/pull/6584) - Vacuum package-lock.json From 44c67d922cc46845f69a9999089f455fd1aea49e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Dec 2022 18:15:26 +0000 Subject: [PATCH 12/29] Bump tesla from 1.4.4 to 1.5.0 Bumps [tesla](https://github.com/teamon/tesla) from 1.4.4 to 1.5.0. - [Release notes](https://github.com/teamon/tesla/releases) - [Commits](https://github.com/teamon/tesla/compare/v1.4.4...v1.5.0) --- updated-dependencies: - dependency-name: tesla dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- apps/explorer/mix.exs | 2 +- mix.exs | 2 +- mix.lock | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/explorer/mix.exs b/apps/explorer/mix.exs index bc10d9856b..fd1e307f66 100644 --- a/apps/explorer/mix.exs +++ b/apps/explorer/mix.exs @@ -113,7 +113,7 @@ defmodule Explorer.Mixfile do # `Timex.Duration` for `Explorer.Counters.AverageBlockTime.average_block_time/0` {:timex, "~> 3.7.1"}, {:con_cache, "~> 1.0"}, - {:tesla, "~> 1.4.4"}, + {:tesla, "~> 1.5.0"}, {:cbor, "~> 1.0"}, {:cloak_ecto, "~> 1.2.0"}, {:redix, "~> 1.1"} diff --git a/mix.exs b/mix.exs index 90bd3dcd3c..e7f17cd096 100644 --- a/mix.exs +++ b/mix.exs @@ -94,7 +94,7 @@ defmodule BlockScout.Mixfile do [ {:prometheus_ex, git: "https://github.com/lanodan/prometheus.ex", branch: "fix/elixir-1.14", override: true}, {:absinthe_plug, git: "https://github.com/blockscout/absinthe_plug.git", tag: "1.5.3", override: true}, - {:tesla, "~> 1.4.4"}, + {:tesla, "~> 1.5.0"}, # Documentation {:ex_doc, "~> 0.29.0", only: :dev, runtime: false}, {:number, "~> 1.0.3"} diff --git a/mix.lock b/mix.lock index 46186a271b..06eafd5161 100644 --- a/mix.lock +++ b/mix.lock @@ -127,7 +127,7 @@ "ssl_verify_fun": {:hex, :ssl_verify_fun, "1.1.6", "cf344f5692c82d2cd7554f5ec8fd961548d4fd09e7d22f5b62482e5aeaebd4b0", [:make, :mix, :rebar3], [], "hexpm", "bdb0d2471f453c88ff3908e7686f86f9be327d065cc1ec16fa4540197ea04680"}, "statistex": {:hex, :statistex, "1.0.0", "f3dc93f3c0c6c92e5f291704cf62b99b553253d7969e9a5fa713e5481cd858a5", [:mix], [], "hexpm", "ff9d8bee7035028ab4742ff52fc80a2aa35cece833cf5319009b52f1b5a86c27"}, "telemetry": {:hex, :telemetry, "0.4.3", "a06428a514bdbc63293cd9a6263aad00ddeb66f608163bdec7c8995784080818", [:rebar3], [], "hexpm", "eb72b8365ffda5bed68a620d1da88525e326cb82a75ee61354fc24b844768041"}, - "tesla": {:hex, :tesla, "1.4.4", "bb89aa0c9745190930366f6a2ac612cdf2d0e4d7fff449861baa7875afd797b2", [:mix], [{:castore, "~> 0.1", [hex: :castore, repo: "hexpm", optional: true]}, {:exjsx, ">= 3.0.0", [hex: :exjsx, repo: "hexpm", optional: true]}, {:finch, "~> 0.3", [hex: :finch, repo: "hexpm", optional: true]}, {:fuse, "~> 2.4", [hex: :fuse, repo: "hexpm", optional: true]}, {:gun, "~> 1.3", [hex: :gun, repo: "hexpm", optional: true]}, {:hackney, "~> 1.6", [hex: :hackney, repo: "hexpm", optional: true]}, {:ibrowse, "4.4.0", [hex: :ibrowse, repo: "hexpm", optional: true]}, {:jason, ">= 1.0.0", [hex: :jason, repo: "hexpm", optional: true]}, {:mime, "~> 1.0 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:mint, "~> 1.0", [hex: :mint, repo: "hexpm", optional: true]}, {:poison, ">= 1.0.0", [hex: :poison, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: true]}], "hexpm", "d5503a49f9dec1b287567ea8712d085947e247cb11b06bc54adb05bfde466457"}, + "tesla": {:hex, :tesla, "1.5.0", "7ee3616be87024a2b7231ae14474310c9b999c3abb1f4f8dbc70f86bd9678eef", [:mix], [{:castore, "~> 0.1", [hex: :castore, repo: "hexpm", optional: true]}, {:exjsx, ">= 3.0.0", [hex: :exjsx, repo: "hexpm", optional: true]}, {:finch, "~> 0.13", [hex: :finch, repo: "hexpm", optional: true]}, {:fuse, "~> 2.4", [hex: :fuse, repo: "hexpm", optional: true]}, {:gun, "~> 1.3", [hex: :gun, repo: "hexpm", optional: true]}, {:hackney, "~> 1.6", [hex: :hackney, repo: "hexpm", optional: true]}, {:ibrowse, "4.4.0", [hex: :ibrowse, repo: "hexpm", optional: true]}, {:jason, ">= 1.0.0", [hex: :jason, repo: "hexpm", optional: true]}, {:mime, "~> 1.0 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:mint, "~> 1.0", [hex: :mint, repo: "hexpm", optional: true]}, {:msgpax, "~> 2.3", [hex: :msgpax, repo: "hexpm", optional: true]}, {:poison, ">= 1.0.0", [hex: :poison, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: true]}], "hexpm", "1d0385e41fbd76af3961809088aef15dec4c2fdaab97b1c93c6484cb3695a122"}, "timex": {:hex, :timex, "3.7.9", "790cdfc4acfce434e442f98c02ea6d84d0239073bfd668968f82ac63e9a6788d", [:mix], [{:combine, "~> 0.10", [hex: :combine, repo: "hexpm", optional: false]}, {:gettext, "~> 0.10", [hex: :gettext, repo: "hexpm", optional: false]}, {:tzdata, "~> 1.1", [hex: :tzdata, repo: "hexpm", optional: false]}], "hexpm", "64691582e5bb87130f721fc709acfb70f24405833998fabf35be968984860ce1"}, "toml": {:hex, :toml, "0.6.2", "38f445df384a17e5d382befe30e3489112a48d3ba4c459e543f748c2f25dd4d1", [:mix], [], "hexpm", "d013e45126d74c0c26a38d31f5e8e9b83ea19fc752470feb9a86071ca5a672fa"}, "tzdata": {:hex, :tzdata, "1.1.1", "20c8043476dfda8504952d00adac41c6eda23912278add38edc140ae0c5bcc46", [:mix], [{:hackney, "~> 1.17", [hex: :hackney, repo: "hexpm", optional: false]}], "hexpm", "a69cec8352eafcd2e198dea28a34113b60fdc6cb57eb5ad65c10292a6ba89787"}, From 09a70e8f8ac18a8a63f3d4b1afdb6a3a47ee4cf8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Dec 2022 18:15:53 +0000 Subject: [PATCH 13/29] Bump chart.js from 4.0.1 to 4.1.0 in /apps/block_scout_web/assets Bumps [chart.js](https://github.com/chartjs/Chart.js) from 4.0.1 to 4.1.0. - [Release notes](https://github.com/chartjs/Chart.js/releases) - [Commits](https://github.com/chartjs/Chart.js/compare/v4.0.1...v4.1.0) --- updated-dependencies: - dependency-name: chart.js dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 35 +++++++++++++------ apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 26 insertions(+), 11 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index cd91dd1e6d..1a98c9e3b0 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -13,7 +13,7 @@ "assert": "^2.0.0", "bignumber.js": "^9.1.1", "bootstrap": "^4.6.0", - "chart.js": "^4.0.1", + "chart.js": "^4.1.0", "chartjs-adapter-luxon": "^1.3.0", "clipboard": "^2.0.11", "core-js": "^3.26.1", @@ -98,11 +98,10 @@ } }, "../../../deps/phoenix": { - "version": "1.5.13", - "license": "MIT" + "version": "0.0.1" }, "../../../deps/phoenix_html": { - "version": "3.0.4" + "version": "0.0.1" }, "node_modules/@ampproject/remapping": { "version": "2.2.0", @@ -3133,6 +3132,11 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "node_modules/@kurkle/color": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@kurkle/color/-/color-0.3.1.tgz", + "integrity": "sha512-hW0GwZj06z/ZFUW2Espl7toVDjghJN+EKqyXzPSV8NV89d5BYp5rRMBJoc+aUN0x5OXDMeRQHazejr2Xmqj2tw==" + }, "node_modules/@metamask/safe-event-emitter": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/@metamask/safe-event-emitter/-/safe-event-emitter-2.0.0.tgz", @@ -5165,9 +5169,12 @@ } }, "node_modules/chart.js": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.0.1.tgz", - "integrity": "sha512-5/8/9eBivwBZK81mKvmIwTb2Pmw4D/5h1RK9fBWZLLZ8mCJ+kfYNmV9rMrGoa5Hgy2/wVDBMLSUDudul2/9ihA==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.1.0.tgz", + "integrity": "sha512-Xta4vonV3e1pwFGLTyUMqXk2aH03D6253DSt52pdS7247u2SpIpQb6kCewxNgx1JfeLBUnjaxHYbHpOv6w78Og==", + "dependencies": { + "@kurkle/color": "^0.3.0" + }, "engines": { "pnpm": "^7.0.0" } @@ -19080,6 +19087,11 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "@kurkle/color": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@kurkle/color/-/color-0.3.1.tgz", + "integrity": "sha512-hW0GwZj06z/ZFUW2Espl7toVDjghJN+EKqyXzPSV8NV89d5BYp5rRMBJoc+aUN0x5OXDMeRQHazejr2Xmqj2tw==" + }, "@metamask/safe-event-emitter": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/@metamask/safe-event-emitter/-/safe-event-emitter-2.0.0.tgz", @@ -20738,9 +20750,12 @@ "dev": true }, "chart.js": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.0.1.tgz", - "integrity": "sha512-5/8/9eBivwBZK81mKvmIwTb2Pmw4D/5h1RK9fBWZLLZ8mCJ+kfYNmV9rMrGoa5Hgy2/wVDBMLSUDudul2/9ihA==" + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.1.0.tgz", + "integrity": "sha512-Xta4vonV3e1pwFGLTyUMqXk2aH03D6253DSt52pdS7247u2SpIpQb6kCewxNgx1JfeLBUnjaxHYbHpOv6w78Og==", + "requires": { + "@kurkle/color": "^0.3.0" + } }, "chartjs-adapter-luxon": { "version": "1.3.0", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index 114b617fb6..59580d619d 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -25,7 +25,7 @@ "assert": "^2.0.0", "bignumber.js": "^9.1.1", "bootstrap": "^4.6.0", - "chart.js": "^4.0.1", + "chart.js": "^4.1.0", "chartjs-adapter-luxon": "^1.3.0", "clipboard": "^2.0.11", "core-js": "^3.26.1", From 7cf3bc291938d89412eeaff76d386586faf7e5c1 Mon Sep 17 00:00:00 2001 From: Victor Baranov Date: Fri, 16 Dec 2022 22:40:01 +0400 Subject: [PATCH 14/29] Expand ETHEREUM_JSONRPC_HTTP_INSECURE env variable usage to than Geth clients (#6601) --- CHANGELOG.md | 1 + apps/explorer/config/dev/arbitrum.exs | 11 ++++++++++- apps/explorer/config/dev/besu.exs | 11 ++++++++++- apps/explorer/config/dev/erigon.exs | 11 ++++++++++- apps/explorer/config/dev/ganache.exs | 11 ++++++++++- apps/explorer/config/dev/nethermind.exs | 11 ++++++++++- apps/explorer/config/dev/rsk.exs | 11 ++++++++++- apps/explorer/config/prod/arbitrum.exs | 11 ++++++++++- apps/explorer/config/prod/besu.exs | 11 ++++++++++- apps/explorer/config/prod/erigon.exs | 11 ++++++++++- apps/explorer/config/prod/ganache.exs | 11 ++++++++++- apps/explorer/config/prod/nethermind.exs | 11 ++++++++++- apps/explorer/config/prod/rsk.exs | 11 ++++++++++- 13 files changed, 121 insertions(+), 12 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 78b2ac920c..a15f20e30d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ### Features +- [#6574](https://github.com/blockscout/blockscout/pull/6574), [#6601](https://github.com/blockscout/blockscout/pull/6601) - Allow and manage insecure HTTP connection to the archive node - [#6433](https://github.com/blockscout/blockscout/pull/6433) - Update error pagess - [#6544](https://github.com/blockscout/blockscout/pull/6544) - API improvements - [#5561](https://github.com/blockscout/blockscout/pull/5561), [#6523](https://github.com/blockscout/blockscout/pull/6523), [#6549](https://github.com/blockscout/blockscout/pull/6549) - Improve working with contracts implementations diff --git a/apps/explorer/config/dev/arbitrum.exs b/apps/explorer/config/dev/arbitrum.exs index e3996f056d..fa25c557bd 100644 --- a/apps/explorer/config/dev/arbitrum.exs +++ b/apps/explorer/config/dev/arbitrum.exs @@ -1,12 +1,21 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, transport_options: [ http: EthereumJSONRPC.HTTP.HTTPoison, url: System.get_env("ETHEREUM_JSONRPC_HTTP_URL") || "http://localhost:8545", - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Arbitrum ], diff --git a/apps/explorer/config/dev/besu.exs b/apps/explorer/config/dev/besu.exs index a277e2c68e..002a3270da 100644 --- a/apps/explorer/config/dev/besu.exs +++ b/apps/explorer/config/dev/besu.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545", trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545" ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Besu ], diff --git a/apps/explorer/config/dev/erigon.exs b/apps/explorer/config/dev/erigon.exs index 6deadfa21f..58b2eca2be 100644 --- a/apps/explorer/config/dev/erigon.exs +++ b/apps/explorer/config/dev/erigon.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545", trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545" ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Erigon ], diff --git a/apps/explorer/config/dev/ganache.exs b/apps/explorer/config/dev/ganache.exs index dcea3bb049..37373cafc9 100644 --- a/apps/explorer/config/dev/ganache.exs +++ b/apps/explorer/config/dev/ganache.exs @@ -1,12 +1,21 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, transport_options: [ http: EthereumJSONRPC.HTTP.HTTPoison, url: System.get_env("ETHEREUM_JSONRPC_HTTP_URL") || "http://localhost:7545", - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Ganache ], diff --git a/apps/explorer/config/dev/nethermind.exs b/apps/explorer/config/dev/nethermind.exs index 3a898aba46..f032361dd0 100644 --- a/apps/explorer/config/dev/nethermind.exs +++ b/apps/explorer/config/dev/nethermind.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545", trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545" ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Nethermind ], diff --git a/apps/explorer/config/dev/rsk.exs b/apps/explorer/config/dev/rsk.exs index 2e4a9da460..008544092a 100644 --- a/apps/explorer/config/dev/rsk.exs +++ b/apps/explorer/config/dev/rsk.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545", trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") || "http://localhost:8545" ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.RSK ], diff --git a/apps/explorer/config/prod/arbitrum.exs b/apps/explorer/config/prod/arbitrum.exs index 3663189d3d..e267ce4d5f 100644 --- a/apps/explorer/config/prod/arbitrum.exs +++ b/apps/explorer/config/prod/arbitrum.exs @@ -1,12 +1,21 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, transport_options: [ http: EthereumJSONRPC.HTTP.HTTPoison, url: System.get_env("ETHEREUM_JSONRPC_HTTP_URL"), - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Arbitrum ], diff --git a/apps/explorer/config/prod/besu.exs b/apps/explorer/config/prod/besu.exs index 8eaada3971..d8ea15edc7 100644 --- a/apps/explorer/config/prod/besu.exs +++ b/apps/explorer/config/prod/besu.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL"), trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Besu ], diff --git a/apps/explorer/config/prod/erigon.exs b/apps/explorer/config/prod/erigon.exs index b5d95a95d0..386f6b08bd 100644 --- a/apps/explorer/config/prod/erigon.exs +++ b/apps/explorer/config/prod/erigon.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL"), trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Erigon ], diff --git a/apps/explorer/config/prod/ganache.exs b/apps/explorer/config/prod/ganache.exs index 694d1ea4d9..679af12fdc 100644 --- a/apps/explorer/config/prod/ganache.exs +++ b/apps/explorer/config/prod/ganache.exs @@ -1,12 +1,21 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, transport_options: [ http: EthereumJSONRPC.HTTP.HTTPoison, url: System.get_env("ETHEREUM_JSONRPC_HTTP_URL"), - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Ganache ], diff --git a/apps/explorer/config/prod/nethermind.exs b/apps/explorer/config/prod/nethermind.exs index 283bf3d908..5a30263f1a 100644 --- a/apps/explorer/config/prod/nethermind.exs +++ b/apps/explorer/config/prod/nethermind.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL"), trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.Nethermind ], diff --git a/apps/explorer/config/prod/rsk.exs b/apps/explorer/config/prod/rsk.exs index 316be82dbf..bcbf91863c 100644 --- a/apps/explorer/config/prod/rsk.exs +++ b/apps/explorer/config/prod/rsk.exs @@ -1,5 +1,14 @@ import Config +hackney_opts_base = [pool: :ethereum_jsonrpc] + +hackney_opts = + if System.get_env("ETHEREUM_JSONRPC_HTTP_INSECURE", "") == "true" do + [:insecure] ++ hackney_opts_base + else + hackney_opts_base + end + config :explorer, json_rpc_named_arguments: [ transport: EthereumJSONRPC.HTTP, @@ -11,7 +20,7 @@ config :explorer, eth_getBalance: System.get_env("ETHEREUM_JSONRPC_TRACE_URL"), trace_replayTransaction: System.get_env("ETHEREUM_JSONRPC_TRACE_URL") ], - http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: [pool: :ethereum_jsonrpc]] + http_options: [recv_timeout: :timer.minutes(1), timeout: :timer.minutes(1), hackney: hackney_opts] ], variant: EthereumJSONRPC.RSK ], From 07fe749112d0646d5ca6422947d06920803be0e8 Mon Sep 17 00:00:00 2001 From: sl1depengwyn Date: Tue, 29 Nov 2022 09:22:47 +0300 Subject: [PATCH 15/29] Add account analytics --- .../block_scout_web/assets/js/pages/layout.js | 190 ++++++++++++++++++ apps/block_scout_web/assets/package-lock.json | 161 +++++++++++++++ apps/block_scout_web/assets/package.json | 2 + apps/block_scout_web/assets/webpack.config.js | 6 +- apps/block_scout_web/config/config.exs | 4 + .../lib/block_scout_web/csp_header.ex | 4 +- .../templates/account/api_key/form.html.eex | 2 +- .../templates/account/api_key/index.html.eex | 4 +- .../templates/account/common/_nav.html.eex | 14 +- .../account/custom_abi/form.html.eex | 2 +- .../account/custom_abi/index.html.eex | 4 +- .../account/public_tags_request/form.html.eex | 4 +- .../public_tags_request/index.html.eex | 4 +- .../account/tag_address/form.html.eex | 2 +- .../account/tag_address/index.html.eex | 2 +- .../account/tag_transaction/form.html.eex | 2 +- .../account/tag_transaction/index.html.eex | 2 +- .../templates/account/watchlist/show.html.eex | 2 +- .../account/watchlist_address/form.html.eex | 2 +- .../layout/_account_menu_item.html.eex | 24 +-- 20 files changed, 400 insertions(+), 37 deletions(-) diff --git a/apps/block_scout_web/assets/js/pages/layout.js b/apps/block_scout_web/assets/js/pages/layout.js index 43fb5a2178..ab170e873c 100644 --- a/apps/block_scout_web/assets/js/pages/layout.js +++ b/apps/block_scout_web/assets/js/pages/layout.js @@ -1,5 +1,195 @@ import $ from 'jquery' import { addChainToMM } from '../lib/add_chain_to_mm' +import mixpanel from 'mixpanel-browser' +import { init as amplitudeInit, track as amplitudeTrack } from '@amplitude/analytics-browser' + +const mixpanelToken = process.env.MIXPANEL_TOKEN +const amplitudeApiKey = process.env.AMPLITUDE_API_KEY +const mixpanelUrl = process.env.MIXPANEL_URL +const amplitudeUrl = process.env.AMPLITUDE_URL + +if (mixpanelToken) { + if (mixpanelUrl) { + mixpanel.init(mixpanelToken, { api_host: mixpanelUrl }) + } else { + mixpanel.init(mixpanelToken) + } +} + +if (amplitudeApiKey) { + if (amplitudeUrl) { + amplitudeInit(amplitudeApiKey, { serverUrl: amplitudeUrl }) + } else { + amplitudeInit(amplitudeApiKey) + } +} + +const simpleEvents = { + '.profile-button': 'Profile click', + '.watchlist-button': 'Watch list click', + '.address-tags-button': 'Address tags click', + '.transaction-tags-button': 'Transaction tags click', + '.api-keys-button': 'API keys click', + '.custom-abi-button': 'Custom ABI click', + '.public-tags-button': 'Public tags click', + '.sign-out-button': 'Sign out click', + '.sign-in-button': 'Sign in click', + '.add-address-button': 'Add address to watch list click', + '.add-address-tag-button': 'Add address tag click', + '.add-transaction-tag-button': 'Add transaction tag click', + '.add-api-key-button': 'Add API key click', + '.add-custom-abi-button': 'Add custom ABI click', + '.add-public-tag-button': 'Request to add public tag click' +} + +if (mixpanelToken || amplitudeApiKey) { + for (const elementClass in simpleEvents) { + $(elementClass).click((_event) => { + if (mixpanelToken) { + mixpanel.track(simpleEvents[elementClass]) + } + + if (amplitudeApiKey) { + amplitudeTrack(simpleEvents[elementClass]) + } + }) + } +} + +$('.save-address-button').click((_event) => { + const eventProperties = { + address_hash: $('#watchlist_address_address_hash').val(), + private_tag: $('#watchlist_address_name').val(), + eth_incoming: $('#watchlist_address_watch_coin_input').prop('checked'), + eth_outgoing: $('#watchlist_address_watch_coin_output').prop('checked'), + erc_20_incoming: $('#watchlist_address_watch_erc_20_input').prop('checked'), + erc_20_outgoing: $('#watchlist_address_watch_erc_20_output').prop('checked'), + erc_721_1155_incoming: $('#watchlist_address_watch_erc_721_input').prop('checked'), + erc_721_1155_outgoing: $('#watchlist_address_watch_erc_721_output').prop('checked'), + email_notifications: $('#watchlist_address_notify_email').prop('checked') + } + const eventName = 'New address to watchlist completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) + +$('.save-address-tag-button').click((_event) => { + const eventProperties = { + address_hash: $('#tag_address_address_hash').val(), + private_tag: $('#tag_address_name').val() + } + const eventName = 'Add address tag completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) + +$('.save-transaction-tag-button').click((_event) => { + const eventProperties = { + address_hash: $('#tag_transaction_tx_hash').val(), + private_tag: $('#tag_transaction_name').val() + } + const eventName = 'Add transaction tag completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) + +$('.save-api-key-button').click((_event) => { + const eventProperties = { + application_name: $('#key_name').val() + } + const eventName = 'Generate API key completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) + +$('.save-custom-abi-button').click((_event) => { + const eventProperties = { + smart_contract_address: $('#custom_abi_address_hash').val(), + project_name: $('#custom_abi_name').val(), + custom_abi: $('#custom_abi_abi').val() + } + const eventName = 'Custom ABI completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) + +$('.send-public-tag-request-button').click((_event) => { + const eventProperties = { + name: $('#public_tags_request_full_name').val(), + email: $('#public_tags_request_email').val(), + company_name: $('#public_tags_request_company').val(), + company_website: $('#public_tags_request_website').val(), + goal: $('#public_tags_request_is_owner_true').prop('checked') ? 'Add tags' : 'Incorrect public tag', + public_tag: $('#public_tags_request_tags').val(), + smart_contracts: $('*[id=public_tags_request_addresses]').map((_i, el) => { + return el.value + }).get(), + reason: $('#public_tags_request_additional_comment').val() + } + const eventName = 'Request a public tag completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) + +$('#public_tags_request_additional_comment').click((_event) => { + const eventProperties = { + name: $('#public_tags_request_full_name').val(), + email: $('#public_tags_request_email').val(), + company_name: $('#public_tags_request_company').val(), + company_website: $('#public_tags_request_website').val(), + goal: $('#public_tags_request_is_owner_true').prop('checked') ? 'Add tags' : 'Incorrect public tag', + public_tag: $('#public_tags_request_tags').val(), + smart_contracts: $('*[id=public_tags_request_addresses]').map((_i, el) => { + return el.value + }).get(), + reason: $('#public_tags_request_additional_comment').val() + } + const eventName = 'Request a public tag completed' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } +}) $(document).click(function (event) { const clickover = $(event.target) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 1a98c9e3b0..15e7da4cb6 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -7,6 +7,7 @@ "name": "blockscout", "license": "GPL-3.0", "dependencies": { + "@amplitude/analytics-browser": "^1.6.1", "@fortawesome/fontawesome-free": "^6.2.1", "@tarekraafat/autocomplete.js": "^10.2.7", "@walletconnect/web3-provider": "^1.8.0", @@ -44,6 +45,7 @@ "lodash.rangeright": "^4.2.0", "lodash.reduce": "^4.6.0", "luxon": "^3.1.1", + "mixpanel-browser": "^2.45.0", "moment": "^2.29.4", "nanomorph": "^5.4.0", "numeral": "^2.0.6", @@ -103,6 +105,84 @@ "../../../deps/phoenix_html": { "version": "0.0.1" }, + "node_modules/@amplitude/analytics-browser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.1.tgz", + "integrity": "sha512-i9Mt3p6ikZm7zu6QRMIziSzNwWW3F2zEIKoOoBbMxy97hSliM93/VoLBLOzwMhusHK3Xy5OwcIgYVUHdXbmigw==", + "dependencies": { + "@amplitude/analytics-client-common": "^0.4.0", + "@amplitude/analytics-core": "^0.10.0", + "@amplitude/analytics-types": "^0.12.0", + "@amplitude/ua-parser-js": "^0.7.31", + "tslib": "^2.3.1" + } + }, + "node_modules/@amplitude/analytics-browser/node_modules/tslib": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", + "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" + }, + "node_modules/@amplitude/analytics-client-common": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.4.0.tgz", + "integrity": "sha512-I3cy6AYCiVUqXAD6yU+tm3qBZdEyrdruDaUS/vVPoi+MvHIkZIXw7xaQjmkBRURWCgdcxu5LioU8r1ld1widtA==", + "dependencies": { + "@amplitude/analytics-connector": "^1.4.5", + "@amplitude/analytics-core": "^0.10.0", + "@amplitude/analytics-types": "^0.12.0", + "tslib": "^2.3.1" + } + }, + "node_modules/@amplitude/analytics-client-common/node_modules/tslib": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", + "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" + }, + "node_modules/@amplitude/analytics-connector": { + "version": "1.4.6", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-connector/-/analytics-connector-1.4.6.tgz", + "integrity": "sha512-6jD2pOosRD4y8DT8StUCz7yTd5ZDkdOU9/AWnlWKM5qk90Mz7sdZrdZ9H7sA/L3yOJEpQOYZgQplQdWWUzyWug==", + "dependencies": { + "@amplitude/ua-parser-js": "0.7.31" + } + }, + "node_modules/@amplitude/analytics-core": { + "version": "0.10.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.10.0.tgz", + "integrity": "sha512-D/6U9SzyDmcNWnT/lFnBKfYl4ASicLlwD1tqu4RZoYS3SwHd/PNST+LbnL3yBTEIJIY//qjth9lLBh/RRzePfg==", + "dependencies": { + "@amplitude/analytics-types": "^0.12.0", + "tslib": "^2.3.1" + } + }, + "node_modules/@amplitude/analytics-core/node_modules/tslib": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", + "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" + }, + "node_modules/@amplitude/analytics-types": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-types/-/analytics-types-0.12.0.tgz", + "integrity": "sha512-XwySEhnCdU8fNWUNaB38JS7bwOt4GOUG8OqgzuXtR8HvGnpCvuT7C6H+BIGA7MfctNQBAzR+6IBgDD+8r1/OEQ==" + }, + "node_modules/@amplitude/ua-parser-js": { + "version": "0.7.31", + "resolved": "https://registry.npmjs.org/@amplitude/ua-parser-js/-/ua-parser-js-0.7.31.tgz", + "integrity": "sha512-+z8UGRaj13Pt5NDzOnkTBy49HE2CX64jeL0ArB86HAtilpnfkPB7oqkigN7Lf2LxscMg4QhFD7mmCfedh3rqTg==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/ua-parser-js" + }, + { + "type": "paypal", + "url": "https://paypal.me/faisalman" + } + ], + "engines": { + "node": "*" + } + }, "node_modules/@ampproject/remapping": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz", @@ -12292,6 +12372,11 @@ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==" }, + "node_modules/mixpanel-browser": { + "version": "2.45.0", + "resolved": "https://registry.npmjs.org/mixpanel-browser/-/mixpanel-browser-2.45.0.tgz", + "integrity": "sha512-PQ1DaTk68yyYtLA0iejmzPA9iNDhT4uIZpqZjRTw7HWpYfl123fydHb2laKanaKjm8YDmrGGz3+xZ4Q6joogyg==" + }, "node_modules/mkdirp": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", @@ -16985,6 +17070,77 @@ } }, "dependencies": { + "@amplitude/analytics-browser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.1.tgz", + "integrity": "sha512-i9Mt3p6ikZm7zu6QRMIziSzNwWW3F2zEIKoOoBbMxy97hSliM93/VoLBLOzwMhusHK3Xy5OwcIgYVUHdXbmigw==", + "requires": { + "@amplitude/analytics-client-common": "^0.4.0", + "@amplitude/analytics-core": "^0.10.0", + "@amplitude/analytics-types": "^0.12.0", + "@amplitude/ua-parser-js": "^0.7.31", + "tslib": "^2.3.1" + }, + "dependencies": { + "tslib": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", + "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" + } + } + }, + "@amplitude/analytics-client-common": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.4.0.tgz", + "integrity": "sha512-I3cy6AYCiVUqXAD6yU+tm3qBZdEyrdruDaUS/vVPoi+MvHIkZIXw7xaQjmkBRURWCgdcxu5LioU8r1ld1widtA==", + "requires": { + "@amplitude/analytics-connector": "^1.4.5", + "@amplitude/analytics-core": "^0.10.0", + "@amplitude/analytics-types": "^0.12.0", + "tslib": "^2.3.1" + }, + "dependencies": { + "tslib": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", + "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" + } + } + }, + "@amplitude/analytics-connector": { + "version": "1.4.6", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-connector/-/analytics-connector-1.4.6.tgz", + "integrity": "sha512-6jD2pOosRD4y8DT8StUCz7yTd5ZDkdOU9/AWnlWKM5qk90Mz7sdZrdZ9H7sA/L3yOJEpQOYZgQplQdWWUzyWug==", + "requires": { + "@amplitude/ua-parser-js": "0.7.31" + } + }, + "@amplitude/analytics-core": { + "version": "0.10.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.10.0.tgz", + "integrity": "sha512-D/6U9SzyDmcNWnT/lFnBKfYl4ASicLlwD1tqu4RZoYS3SwHd/PNST+LbnL3yBTEIJIY//qjth9lLBh/RRzePfg==", + "requires": { + "@amplitude/analytics-types": "^0.12.0", + "tslib": "^2.3.1" + }, + "dependencies": { + "tslib": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz", + "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" + } + } + }, + "@amplitude/analytics-types": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-types/-/analytics-types-0.12.0.tgz", + "integrity": "sha512-XwySEhnCdU8fNWUNaB38JS7bwOt4GOUG8OqgzuXtR8HvGnpCvuT7C6H+BIGA7MfctNQBAzR+6IBgDD+8r1/OEQ==" + }, + "@amplitude/ua-parser-js": { + "version": "0.7.31", + "resolved": "https://registry.npmjs.org/@amplitude/ua-parser-js/-/ua-parser-js-0.7.31.tgz", + "integrity": "sha512-+z8UGRaj13Pt5NDzOnkTBy49HE2CX64jeL0ArB86HAtilpnfkPB7oqkigN7Lf2LxscMg4QhFD7mmCfedh3rqTg==" + }, "@ampproject/remapping": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz", @@ -26264,6 +26420,11 @@ "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==" }, + "mixpanel-browser": { + "version": "2.45.0", + "resolved": "https://registry.npmjs.org/mixpanel-browser/-/mixpanel-browser-2.45.0.tgz", + "integrity": "sha512-PQ1DaTk68yyYtLA0iejmzPA9iNDhT4uIZpqZjRTw7HWpYfl123fydHb2laKanaKjm8YDmrGGz3+xZ4Q6joogyg==" + }, "mkdirp": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index 59580d619d..10f3ecc0f3 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -20,6 +20,7 @@ }, "dependencies": { "@fortawesome/fontawesome-free": "^6.2.1", + "@amplitude/analytics-browser": "^1.6.1", "@tarekraafat/autocomplete.js": "^10.2.7", "@walletconnect/web3-provider": "^1.8.0", "assert": "^2.0.0", @@ -56,6 +57,7 @@ "lodash.rangeright": "^4.2.0", "lodash.reduce": "^4.6.0", "luxon": "^3.1.1", + "mixpanel-browser": "^2.45.0", "moment": "^2.29.4", "nanomorph": "^5.4.0", "numeral": "^2.0.6", diff --git a/apps/block_scout_web/assets/webpack.config.js b/apps/block_scout_web/assets/webpack.config.js index d4f59631be..62d0fe3022 100644 --- a/apps/block_scout_web/assets/webpack.config.js +++ b/apps/block_scout_web/assets/webpack.config.js @@ -164,7 +164,11 @@ const appJs = new ContextReplacementPlugin(/moment[\/\\]locale$/, /en/), new webpack.DefinePlugin({ 'process.env.SOCKET_ROOT': JSON.stringify(process.env.SOCKET_ROOT), - 'process.env.NETWORK_PATH': JSON.stringify(process.env.NETWORK_PATH) + 'process.env.NETWORK_PATH': JSON.stringify(process.env.NETWORK_PATH), + 'process.env.MIXPANEL_TOKEN': JSON.stringify(process.env.MIXPANEL_TOKEN), + 'process.env.MIXPANEL_URL': JSON.stringify(process.env.MIXPANEL_URL), + 'process.env.AMPLITUDE_API_KEY': JSON.stringify(process.env.AMPLITUDE_API_KEY), + 'process.env.AMPLITUDE_URL': JSON.stringify(process.env.AMPLITUDE_URL) }), new webpack.ProvidePlugin({ process: 'process/browser', diff --git a/apps/block_scout_web/config/config.exs b/apps/block_scout_web/config/config.exs index 815116d275..b9546f57fe 100644 --- a/apps/block_scout_web/config/config.exs +++ b/apps/block_scout_web/config/config.exs @@ -99,6 +99,10 @@ config :block_scout_web, BlockScoutWeb.ApiRouter, config :block_scout_web, BlockScoutWeb.WebRouter, enabled: System.get_env("DISABLE_WEBAPP") != "true" +config :block_scout_web, BlockScoutWeb.CSPHeader, + mixpanel_url: System.get_env("MIXPANEL_URL", "https://api-js.mixpanel.com"), + amplitude_url: System.get_env("AMPLITUDE_URL", "https://api2.amplitude.com/2/httpapi") + # Configures Ueberauth local settings config :ueberauth, Ueberauth, providers: [ diff --git a/apps/block_scout_web/lib/block_scout_web/csp_header.ex b/apps/block_scout_web/lib/block_scout_web/csp_header.ex index cb81c9b224..b75aaa4c19 100644 --- a/apps/block_scout_web/lib/block_scout_web/csp_header.ex +++ b/apps/block_scout_web/lib/block_scout_web/csp_header.ex @@ -9,9 +9,11 @@ defmodule BlockScoutWeb.CSPHeader do def init(opts), do: opts def call(conn, _opts) do + config = Application.get_env(:block_scout_web, __MODULE__) + Controller.put_secure_browser_headers(conn, %{ "content-security-policy" => "\ - connect-src 'self' #{websocket_endpoints(conn)} wss://*.bridge.walletconnect.org/ https://request-global.czilladx.com/ https://raw.githubusercontent.com/trustwallet/assets/ https://registry.walletconnect.org/data/wallets.json https://*.poa.network;\ + connect-src 'self' #{config[:mixpanel_url]} #{config[:amplitude_url]} #{websocket_endpoints(conn)} wss://*.bridge.walletconnect.org/ https://request-global.czilladx.com/ https://raw.githubusercontent.com/trustwallet/assets/ https://registry.walletconnect.org/data/wallets.json https://*.poa.network;\ default-src 'self';\ script-src 'self' 'unsafe-inline' 'unsafe-eval' https://coinzillatag.com https://www.google.com https://www.gstatic.com;\ style-src 'self' 'unsafe-inline' 'unsafe-eval' https://fonts.googleapis.com;\ diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/form.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/form.html.eex index a425a078b5..66b7c73175 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/form.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/form.html.eex @@ -23,7 +23,7 @@

<%= gettext "Back to API keys (Cancel)"%> - <%= submit gettext("Save"), class: "button button-primary button-sm ml-3" %> + <%= submit gettext("Save"), class: "save-api-key-button button button-primary button-sm ml-3" %>
<% end %>
diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/index.html.eex index 72ebbe8782..156fe24147 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/api_key/index.html.eex @@ -41,11 +41,11 @@
<%= if Enum.count(@api_keys) < Key.get_max_api_keys_count() do %> - <%= gettext "Add API key" %> + <%= gettext "Add API key" %> <% end %> -
\ No newline at end of file + diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/common/_nav.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/common/_nav.html.eex index cf28ad5d85..81667180d7 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/common/_nav.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/common/_nav.html.eex @@ -1,25 +1,25 @@ diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/form.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/form.html.eex index c54477c824..312e020677 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/form.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/form.html.eex @@ -28,7 +28,7 @@
<%= gettext "Back to Custom ABI (Cancel)"%> - <%= submit gettext("Save"), class: "button button-primary button-sm ml-3" %> + <%= submit gettext("Save"), class: "save-custom-abi-button button button-primary button-sm ml-3" %>
<% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/index.html.eex index 409a4ffaa0..84467652b1 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/custom_abi/index.html.eex @@ -41,11 +41,11 @@ <%= if Enum.count(@custom_abis) < CustomABI.get_max_custom_abis_count() do %> - <%= gettext "Add Custom ABI" %> + <%= gettext "Add Custom ABI" %> <% end %> - \ No newline at end of file + diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/form.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/form.html.eex index 86cfd1df22..9a2cec1220 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/form.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/form.html.eex @@ -60,7 +60,7 @@
<%= gettext "Cancel"%> - <%= submit gettext("Send request"), class: "button button-primary button-sm ml-3" %> + <%= submit gettext("Send request"), class: "send-public-tag-request-button button button-primary button-sm ml-3" %>
<% end %> @@ -69,4 +69,4 @@ - \ No newline at end of file + diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/index.html.eex index bd94519473..b3a5155868 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/public_tags_request/index.html.eex @@ -34,11 +34,11 @@ <%= if Enum.count(@public_tags_requests) < PublicTagsRequest.get_max_public_tags_request_count() do %> - <%= gettext "Request to add public tag" %> + <%= gettext "Request to add public tag" %> <% end %> - \ No newline at end of file + diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/form.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/form.html.eex index ec4d930cf1..6e41a7c3f3 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/form.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/form.html.eex @@ -22,7 +22,7 @@
<%= gettext "Back to Address Tags (Cancel)"%> - <%= submit gettext("Save"), class: "button button-primary button-sm ml-3" %> + <%= submit gettext("Save"), class: "save-address-tag-button button button-primary button-sm ml-3" %>
<% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/index.html.eex index 511405cdda..bcc3d2d31b 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_address/index.html.eex @@ -34,7 +34,7 @@ <%= if Enum.count(@address_tags) < TagAddress.get_max_tags_count() do %> - <%= gettext "Add address tag" %> + <%= gettext "Add address tag" %> <% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/form.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/form.html.eex index 40d9c03f83..1426bdd90a 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/form.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/form.html.eex @@ -22,7 +22,7 @@
<%= gettext "Back to Transaction Tags (Cancel)"%> - <%= submit gettext("Save"), class: "button button-primary button-sm ml-3" %> + <%= submit gettext("Save"), class: "save-transaction-tag-button button button-primary button-sm ml-3" %>
<% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/index.html.eex index c1cca8adec..508d8126ba 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/tag_transaction/index.html.eex @@ -34,7 +34,7 @@ <%= if Enum.count(@tx_tags) < TagTransaction.get_max_tags_count() do %> - <%= gettext "Add transaction tag" %> + <%= gettext "Add transaction tag" %> <% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist/show.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist/show.html.eex index 592532f625..6270bc7667 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist/show.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist/show.html.eex @@ -35,7 +35,7 @@ <%= if Enum.count(@watchlist.watchlist_addresses) < WatchlistAddress.get_max_watchlist_addresses_count() do %> - <%= gettext "Add address" %> + <%= gettext "Add address" %> <% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist_address/form.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist_address/form.html.eex index c2a6dce569..410b19615d 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist_address/form.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/account/watchlist_address/form.html.eex @@ -80,7 +80,7 @@ <%= gettext "Back to Watch list (Cancel)" %> - <%= submit gettext("Save"), class: "button button-primary button-sm ml-3" %> + <%= submit gettext("Save"), class: "#{if @method == :create, do: "save-address-button "}button button-primary button-sm ml-3" %> <% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/layout/_account_menu_item.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/layout/_account_menu_item.html.eex index e8f8e58f62..541dcecb45 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/layout/_account_menu_item.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/layout/_account_menu_item.html.eex @@ -8,26 +8,26 @@ <% else %>
  • - +
  • <% end %> -<% end %> \ No newline at end of file +<% end %> From 306a617dd0f8503a3330eb94fe48ddb843c42c3f Mon Sep 17 00:00:00 2001 From: sl1depengwyn Date: Thu, 1 Dec 2022 17:50:03 +0300 Subject: [PATCH 16/29] Add navbar search analytics --- .../block_scout_web/assets/js/pages/layout.js | 89 ++++++++++++++++++- 1 file changed, 85 insertions(+), 4 deletions(-) diff --git a/apps/block_scout_web/assets/js/pages/layout.js b/apps/block_scout_web/assets/js/pages/layout.js index ab170e873c..ee53f7f64f 100644 --- a/apps/block_scout_web/assets/js/pages/layout.js +++ b/apps/block_scout_web/assets/js/pages/layout.js @@ -152,8 +152,8 @@ $('.send-public-tag-request-button').click((_event) => { goal: $('#public_tags_request_is_owner_true').prop('checked') ? 'Add tags' : 'Incorrect public tag', public_tag: $('#public_tags_request_tags').val(), smart_contracts: $('*[id=public_tags_request_addresses]').map((_i, el) => { - return el.value - }).get(), + return el.value + }).get(), reason: $('#public_tags_request_additional_comment').val() } const eventName = 'Request a public tag completed' @@ -176,8 +176,8 @@ $('#public_tags_request_additional_comment').click((_event) => { goal: $('#public_tags_request_is_owner_true').prop('checked') ? 'Add tags' : 'Incorrect public tag', public_tag: $('#public_tags_request_tags').val(), smart_contracts: $('*[id=public_tags_request_addresses]').map((_i, el) => { - return el.value - }).get(), + return el.value + }).get(), reason: $('#public_tags_request_additional_comment').val() } const eventName = 'Request a public tag completed' @@ -191,6 +191,74 @@ $('#public_tags_request_additional_comment').click((_event) => { } }) +$(document).ready(() => { + let timer + const waitTime = 500 + var observer = new MutationObserver((mutations) => { + clearTimeout(timer) + + if (mutations[0].target.hidden) { + return + } + + const $results = $('li[id^="autoComplete_result_"]') + + timer = setTimeout(() => { + let eventProperties = { + search: $('.main-search-autocomplete').val() || $('.main-search-autocomplete-mobile').val() + } + let eventName = 'Occurs searching according to substring at the nav bar' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } + + eventProperties = { + resultsNumber: $results.length, + results: $results.map((_i, el) => { + return el.children[1].innerText + }) + } + eventName = 'Search list displays at the nav bar' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } + }, waitTime) + + $results.click((event) => { + const eventProperties = { + item: event.currentTarget.innerText + } + const eventName = 'Search item click at the nav bar' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } + }) + + }) + observer.observe($('#autoComplete_list_1')[0], { + attributeFilter: ['hidden'], + childList: true + }) + observer.observe($('#autoComplete_list_2')[0], { + attributeFilter: ['hidden'] + }) +}) + $(document).click(function (event) { const clickover = $(event.target) const _opened = $('.navbar-collapse').hasClass('show') @@ -200,6 +268,19 @@ $(document).click(function (event) { }) const search = (value) => { + const eventProperties = { + search: value + } + const eventName = 'Occurs searching according to substring at the nav bar' + + if (mixpanelToken) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeApiKey) { + amplitudeTrack(eventName, eventProperties) + } + if (value) { window.location.href = `/search?q=${value}` } From 5d1ebb2fb62b18731a47fd53b60f49606cecd436 Mon Sep 17 00:00:00 2001 From: sl1depengwyn Date: Fri, 2 Dec 2022 20:00:36 +0300 Subject: [PATCH 17/29] Add search page analytics --- CHANGELOG.md | 1 + .../assets/js/lib/analytics.js | 46 +++++ .../block_scout_web/assets/js/pages/layout.js | 160 +++--------------- .../assets/js/pages/search-results/search.js | 41 ++++- .../templates/search/results.html.eex | 4 +- apps/block_scout_web/priv/gettext/default.pot | 20 ++- .../priv/gettext/en/LC_MESSAGES/default.po | 20 ++- 7 files changed, 143 insertions(+), 149 deletions(-) create mode 100644 apps/block_scout_web/assets/js/lib/analytics.js diff --git a/CHANGELOG.md b/CHANGELOG.md index a15f20e30d..ef4c8e39e5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ### Features +- [#6542](https://github.com/blockscout/blockscout/pull/6542) - Init mixpanel and amplitude analytics - [#6574](https://github.com/blockscout/blockscout/pull/6574), [#6601](https://github.com/blockscout/blockscout/pull/6601) - Allow and manage insecure HTTP connection to the archive node - [#6433](https://github.com/blockscout/blockscout/pull/6433) - Update error pagess - [#6544](https://github.com/blockscout/blockscout/pull/6544) - API improvements diff --git a/apps/block_scout_web/assets/js/lib/analytics.js b/apps/block_scout_web/assets/js/lib/analytics.js new file mode 100644 index 0000000000..7f19a16d2f --- /dev/null +++ b/apps/block_scout_web/assets/js/lib/analytics.js @@ -0,0 +1,46 @@ +import mixpanel from 'mixpanel-browser' +import { init as amplitudeInit, track as amplitudeTrack } from '@amplitude/analytics-browser' + +const mixpanelToken = process.env.MIXPANEL_TOKEN +const amplitudeApiKey = process.env.AMPLITUDE_API_KEY +let initialized = false +export let mixpanelInitialized = false +export let amplitudeInitialized = false + +export function init () { + const mixpanelUrl = process.env.MIXPANEL_URL + const amplitudeUrl = process.env.AMPLITUDE_URL + + if (mixpanelToken) { + if (mixpanelUrl) { + mixpanel.init(mixpanelToken, { api_host: mixpanelUrl }) + } else { + mixpanel.init(mixpanelToken) + } + mixpanelInitialized = true + } + + if (amplitudeApiKey) { + if (amplitudeUrl) { + amplitudeInit(amplitudeApiKey, { serverUrl: amplitudeUrl }) + } else { + amplitudeInit(amplitudeApiKey) + } + amplitudeInitialized = true + } + initialized = true +} + +export function trackEvent (eventName, eventProperties = {}) { + if (!initialized) { + init() + } + + if (mixpanelInitialized) { + mixpanel.track(eventName, eventProperties) + } + + if (amplitudeInitialized) { + amplitudeTrack(eventName, eventProperties) + } +} diff --git a/apps/block_scout_web/assets/js/pages/layout.js b/apps/block_scout_web/assets/js/pages/layout.js index ee53f7f64f..a7d63f4e6f 100644 --- a/apps/block_scout_web/assets/js/pages/layout.js +++ b/apps/block_scout_web/assets/js/pages/layout.js @@ -1,28 +1,8 @@ import $ from 'jquery' import { addChainToMM } from '../lib/add_chain_to_mm' -import mixpanel from 'mixpanel-browser' -import { init as amplitudeInit, track as amplitudeTrack } from '@amplitude/analytics-browser' - -const mixpanelToken = process.env.MIXPANEL_TOKEN -const amplitudeApiKey = process.env.AMPLITUDE_API_KEY -const mixpanelUrl = process.env.MIXPANEL_URL -const amplitudeUrl = process.env.AMPLITUDE_URL - -if (mixpanelToken) { - if (mixpanelUrl) { - mixpanel.init(mixpanelToken, { api_host: mixpanelUrl }) - } else { - mixpanel.init(mixpanelToken) - } -} +import * as analytics from '../lib/analytics' -if (amplitudeApiKey) { - if (amplitudeUrl) { - amplitudeInit(amplitudeApiKey, { serverUrl: amplitudeUrl }) - } else { - amplitudeInit(amplitudeApiKey) - } -} +analytics.init() const simpleEvents = { '.profile-button': 'Profile click', @@ -42,16 +22,10 @@ const simpleEvents = { '.add-public-tag-button': 'Request to add public tag click' } -if (mixpanelToken || amplitudeApiKey) { +if (analytics.mixpanelInitialized || analytics.amplitudeInitialized) { for (const elementClass in simpleEvents) { $(elementClass).click((_event) => { - if (mixpanelToken) { - mixpanel.track(simpleEvents[elementClass]) - } - - if (amplitudeApiKey) { - amplitudeTrack(simpleEvents[elementClass]) - } + analytics.trackEvent(simpleEvents[elementClass]) }) } } @@ -70,104 +44,51 @@ $('.save-address-button').click((_event) => { } const eventName = 'New address to watchlist completed' - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) $('.save-address-tag-button').click((_event) => { + const eventName = 'Add address tag completed' const eventProperties = { address_hash: $('#tag_address_address_hash').val(), private_tag: $('#tag_address_name').val() } - const eventName = 'Add address tag completed' - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) $('.save-transaction-tag-button').click((_event) => { + const eventName = 'Add transaction tag completed' const eventProperties = { address_hash: $('#tag_transaction_tx_hash').val(), private_tag: $('#tag_transaction_name').val() } - const eventName = 'Add transaction tag completed' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) $('.save-api-key-button').click((_event) => { + const eventName = 'Generate API key completed' const eventProperties = { application_name: $('#key_name').val() } - const eventName = 'Generate API key completed' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) $('.save-custom-abi-button').click((_event) => { + const eventName = 'Custom ABI completed' const eventProperties = { smart_contract_address: $('#custom_abi_address_hash').val(), project_name: $('#custom_abi_name').val(), custom_abi: $('#custom_abi_abi').val() } - const eventName = 'Custom ABI completed' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) $('.send-public-tag-request-button').click((_event) => { - const eventProperties = { - name: $('#public_tags_request_full_name').val(), - email: $('#public_tags_request_email').val(), - company_name: $('#public_tags_request_company').val(), - company_website: $('#public_tags_request_website').val(), - goal: $('#public_tags_request_is_owner_true').prop('checked') ? 'Add tags' : 'Incorrect public tag', - public_tag: $('#public_tags_request_tags').val(), - smart_contracts: $('*[id=public_tags_request_addresses]').map((_i, el) => { - return el.value - }).get(), - reason: $('#public_tags_request_additional_comment').val() - } const eventName = 'Request a public tag completed' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } -}) - -$('#public_tags_request_additional_comment').click((_event) => { const eventProperties = { name: $('#public_tags_request_full_name').val(), email: $('#public_tags_request_email').val(), @@ -180,75 +101,48 @@ $('#public_tags_request_additional_comment').click((_event) => { }).get(), reason: $('#public_tags_request_additional_comment').val() } - const eventName = 'Request a public tag completed' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) $(document).ready(() => { let timer const waitTime = 500 - var observer = new MutationObserver((mutations) => { - clearTimeout(timer) - + const observer = new MutationObserver((mutations) => { if (mutations[0].target.hidden) { return } const $results = $('li[id^="autoComplete_result_"]') + clearTimeout(timer) timer = setTimeout(() => { + let eventName = 'Occurs searching according to substring at the nav bar' let eventProperties = { search: $('.main-search-autocomplete').val() || $('.main-search-autocomplete-mobile').val() } - let eventName = 'Occurs searching according to substring at the nav bar' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) + eventName = 'Search list displays at the nav bar' eventProperties = { resultsNumber: $results.length, results: $results.map((_i, el) => { return el.children[1].innerText }) } - eventName = 'Search list displays at the nav bar' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }, waitTime) $results.click((event) => { + const eventName = 'Search item click at the nav bar' const eventProperties = { item: event.currentTarget.innerText } - const eventName = 'Search item click at the nav bar' - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) }) - }) observer.observe($('#autoComplete_list_1')[0], { attributeFilter: ['hidden'], @@ -268,18 +162,12 @@ $(document).click(function (event) { }) const search = (value) => { + const eventName = 'Occurs searching according to substring at the nav bar' const eventProperties = { search: value } - const eventName = 'Occurs searching according to substring at the nav bar' - - if (mixpanelToken) { - mixpanel.track(eventName, eventProperties) - } - if (amplitudeApiKey) { - amplitudeTrack(eventName, eventProperties) - } + analytics.trackEvent(eventName, eventProperties) if (value) { window.location.href = `/search?q=${value}` diff --git a/apps/block_scout_web/assets/js/pages/search-results/search.js b/apps/block_scout_web/assets/js/pages/search-results/search.js index 6f7ff44340..fa3951b31b 100644 --- a/apps/block_scout_web/assets/js/pages/search-results/search.js +++ b/apps/block_scout_web/assets/js/pages/search-results/search.js @@ -2,6 +2,7 @@ import $ from 'jquery' import omit from 'lodash.omit' import humps from 'humps' import { createAsyncLoadStore } from '../../lib/async_listing_load' +import * as analytics from '../../lib/analytics' const $searchInput = $('.search-input') @@ -24,6 +25,10 @@ export function reducer (state, action) { } if ($('[data-page="search-results"]').length) { + let searchTimer + let resultsTimer + const waitTime = 500 + const store = createAsyncLoadStore(reducer, initialState, 'dataset.identifierHash') store.dispatch({ @@ -33,6 +38,15 @@ if ($('[data-page="search-results"]').length) { $searchInput.on('input', (event) => { const value = $(event.target).val() + clearTimeout(searchTimer) + searchTimer = setTimeout(() => { + const eventName = 'Occurs searching according to substring at the search page' + const eventProperties = { + search: value + } + analytics.trackEvent(eventName, eventProperties) + }, waitTime) + $('.js-search-results-query-display').text(value) const loc = window.location.pathname @@ -47,7 +61,32 @@ if ($('[data-page="search-results"]').length) { contentType: 'application/json; charset=utf-8' }).done(response => store.dispatch(Object.assign({ type: 'ITEMS_FETCHED' }, humps.camelizeKeys(response)))) .fail(() => store.dispatch({ type: 'REQUEST_ERROR' })) - .always(() => store.dispatch({ type: 'FINISH_REQUEST' })) + .always(() => { + const $results = $('#search_results_table_body tr') + $results.click((event) => { + console.log(event) + const eventName = 'Search item click at the search page' + const eventProperties = { + item: event.currentTarget.innerText + } + analytics.trackEvent(eventName, eventProperties) + event.stopImmediatePropagation() + }) + + clearTimeout(resultsTimer) + resultsTimer = setTimeout(() => { + const eventName = 'Search list displays at the search page' + const eventProperties = { + resultsNumber: $results.length, + results: $results.map((_i, el) => { + return el.innerText + }) + } + analytics.trackEvent(eventName, eventProperties) + }, waitTime) + + store.dispatch({ type: 'FINISH_REQUEST' }) + }) } }) } diff --git a/apps/block_scout_web/lib/block_scout_web/templates/search/results.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/search/results.html.eex index c973f6cccb..40b294ebb4 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/search/results.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/search/results.html.eex @@ -38,7 +38,7 @@ - + <%= render BlockScoutWeb.CommonComponentsView, "_table-loader.html", columns_num: 5 %> @@ -48,4 +48,4 @@ - \ No newline at end of file + diff --git a/apps/block_scout_web/priv/gettext/default.pot b/apps/block_scout_web/priv/gettext/default.pot index ed940eaba3..246bd35255 100644 --- a/apps/block_scout_web/priv/gettext/default.pot +++ b/apps/block_scout_web/priv/gettext/default.pot @@ -3443,6 +3443,16 @@ msgstr "" msgid "truffle flattener" msgstr "" +#: lib/block_scout_web/templates/layout/_account_menu_item.html.eex:29 +#, elixir-autogen, elixir-format +msgid "Sign in" +msgstr "" + +#: lib/block_scout_web/templates/layout/_account_menu_item.html.eex:11 +#, elixir-autogen, elixir-format +msgid "Signed in as " +msgstr "" + #: lib/block_scout_web/templates/transaction/not_found.html.eex:8 #, elixir-autogen, elixir-format msgid "1. If you have just submitted this transaction please wait for at least 30 seconds before refreshing this page." @@ -3453,6 +3463,11 @@ msgstr "" msgid "2. It could still be in the TX Pool of a different node, waiting to be broadcasted." msgstr "" +#: lib/block_scout_web/templates/transaction/not_found.html.eex:10 +#, elixir-autogen, elixir-format +msgid "3. During times when the network is busy (i.e during ICOs) it can take a while for your transaction to propagate through the network and for us to index it." +msgstr "" + #: lib/block_scout_web/templates/transaction/not_found.html.eex:11 #, elixir-autogen, elixir-format msgid "4. If it still does not show up after 1 hour, please check with your sender/exchange/wallet/transaction provider for additional information." @@ -3495,8 +3510,3 @@ msgstr "" #, elixir-autogen, elixir-format msgid "Your request contained an error, perhaps a mistyped tx/block/address hash. Try again, and check the developer tools console for more info." msgstr "" - -#: lib/block_scout_web/templates/transaction/not_found.html.eex:10 -#, elixir-autogen, elixir-format -msgid "3. During times when the network is busy (i.e during ICOs) it can take a while for your transaction to propagate through the network and for us to index it." -msgstr "" diff --git a/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po b/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po index 4f6910e788..1374d3da55 100644 --- a/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po +++ b/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po @@ -3443,6 +3443,16 @@ msgstr "" msgid "truffle flattener" msgstr "" +#: lib/block_scout_web/templates/layout/_account_menu_item.html.eex:29 +#, elixir-autogen, elixir-format +msgid "Sign in" +msgstr "" + +#: lib/block_scout_web/templates/layout/_account_menu_item.html.eex:11 +#, elixir-autogen, elixir-format +msgid "Signed in as " +msgstr "" + #: lib/block_scout_web/templates/transaction/not_found.html.eex:8 #, elixir-autogen, elixir-format, fuzzy msgid "1. If you have just submitted this transaction please wait for at least 30 seconds before refreshing this page." @@ -3453,6 +3463,11 @@ msgstr "" msgid "2. It could still be in the TX Pool of a different node, waiting to be broadcasted." msgstr "" +#: lib/block_scout_web/templates/transaction/not_found.html.eex:10 +#, elixir-autogen, elixir-format, fuzzy +msgid "3. During times when the network is busy (i.e during ICOs) it can take a while for your transaction to propagate through the network and for us to index it." +msgstr "" + #: lib/block_scout_web/templates/transaction/not_found.html.eex:11 #, elixir-autogen, elixir-format, fuzzy msgid "4. If it still does not show up after 1 hour, please check with your sender/exchange/wallet/transaction provider for additional information." @@ -3495,8 +3510,3 @@ msgstr "" #, elixir-autogen, elixir-format msgid "Your request contained an error, perhaps a mistyped tx/block/address hash. Try again, and check the developer tools console for more info." msgstr "" - -#: lib/block_scout_web/templates/transaction/not_found.html.eex:10 -#, elixir-autogen, elixir-format, fuzzy -msgid "3. During times when the network is busy (i.e during ICOs) it can take a while for your transaction to propagate through the network and for us to index it." -msgstr "" From 061cb7da7880cd4a6dffee91a24baca809961e83 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Dec 2022 18:11:58 +0000 Subject: [PATCH 18/29] Bump chart.js from 4.1.0 to 4.1.1 in /apps/block_scout_web/assets Bumps [chart.js](https://github.com/chartjs/Chart.js) from 4.1.0 to 4.1.1. - [Release notes](https://github.com/chartjs/Chart.js/releases) - [Commits](https://github.com/chartjs/Chart.js/compare/v4.1.0...v4.1.1) --- updated-dependencies: - dependency-name: chart.js dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 14 +++++++------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 1a98c9e3b0..ed58875d14 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -13,7 +13,7 @@ "assert": "^2.0.0", "bignumber.js": "^9.1.1", "bootstrap": "^4.6.0", - "chart.js": "^4.1.0", + "chart.js": "^4.1.1", "chartjs-adapter-luxon": "^1.3.0", "clipboard": "^2.0.11", "core-js": "^3.26.1", @@ -5169,9 +5169,9 @@ } }, "node_modules/chart.js": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.1.0.tgz", - "integrity": "sha512-Xta4vonV3e1pwFGLTyUMqXk2aH03D6253DSt52pdS7247u2SpIpQb6kCewxNgx1JfeLBUnjaxHYbHpOv6w78Og==", + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.1.1.tgz", + "integrity": "sha512-P0pCosNXp+LR8zO/QTkZKT6Hb7p0DPFtypEeVOf+6x06hX13NIb75R0DXUA4Ksx/+48chDQKtCCmRCviQRTqsA==", "dependencies": { "@kurkle/color": "^0.3.0" }, @@ -20750,9 +20750,9 @@ "dev": true }, "chart.js": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.1.0.tgz", - "integrity": "sha512-Xta4vonV3e1pwFGLTyUMqXk2aH03D6253DSt52pdS7247u2SpIpQb6kCewxNgx1JfeLBUnjaxHYbHpOv6w78Og==", + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/chart.js/-/chart.js-4.1.1.tgz", + "integrity": "sha512-P0pCosNXp+LR8zO/QTkZKT6Hb7p0DPFtypEeVOf+6x06hX13NIb75R0DXUA4Ksx/+48chDQKtCCmRCviQRTqsA==", "requires": { "@kurkle/color": "^0.3.0" } diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index 59580d619d..4dc46eb9ef 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -25,7 +25,7 @@ "assert": "^2.0.0", "bignumber.js": "^9.1.1", "bootstrap": "^4.6.0", - "chart.js": "^4.1.0", + "chart.js": "^4.1.1", "chartjs-adapter-luxon": "^1.3.0", "clipboard": "^2.0.11", "core-js": "^3.26.1", From 8484a978768e299f094fbc92d3cc2545e0731b94 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Dec 2022 18:12:33 +0000 Subject: [PATCH 19/29] Bump eslint from 8.29.0 to 8.30.0 in /apps/block_scout_web/assets Bumps [eslint](https://github.com/eslint/eslint) from 8.29.0 to 8.30.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v8.29.0...v8.30.0) --- updated-dependencies: - dependency-name: eslint dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 192 +++++------------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 54 insertions(+), 140 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 1a98c9e3b0..04143e4e77 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -75,7 +75,7 @@ "copy-webpack-plugin": "^11.0.0", "css-loader": "^5.2.7", "css-minimizer-webpack-plugin": "^4.2.2", - "eslint": "^8.29.0", + "eslint": "^8.30.0", "eslint-config-standard": "^17.0.0", "eslint-plugin-import": "^2.26.0", "eslint-plugin-node": "^11.1.0", @@ -1807,15 +1807,15 @@ "integrity": "sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg==" }, "node_modules/@eslint/eslintrc": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.3.tgz", - "integrity": "sha512-uj3pT6Mg+3t39fvLrj8iuCIJ38zKO9FpGtJ4BBJebJhEwjoT+KLVNCcHT5QC9NGRIEi7fZ0ZR8YRb884auB4Lg==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.4.0.tgz", + "integrity": "sha512-7yfvXy6MWLgWSFsLhz5yH3iQ52St8cdUY6FoGieKkRDVxuxmrNuUetIuu6cmjNWwniUHiWXjxCr5tTXDrbYS5A==", "dev": true, "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", "espree": "^9.4.0", - "globals": "^13.15.0", + "globals": "^13.19.0", "ignore": "^5.2.0", "import-fresh": "^3.2.1", "js-yaml": "^4.1.0", @@ -1836,9 +1836,9 @@ "dev": true }, "node_modules/@eslint/eslintrc/node_modules/globals": { - "version": "13.17.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.17.0.tgz", - "integrity": "sha512-1C+6nQRb1GwGMKm2dH/E7enFAMxGTmGI7/dEdhy/DNelv85w9B72t3uc5frtMNXIbzrarJJ/lTCjcaZwbLJmyw==", + "version": "13.19.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.19.0.tgz", + "integrity": "sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ==", "dev": true, "dependencies": { "type-fest": "^0.20.2" @@ -1862,18 +1862,6 @@ "js-yaml": "bin/js-yaml.js" } }, - "node_modules/@eslint/eslintrc/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, "node_modules/@eslint/eslintrc/node_modules/type-fest": { "version": "0.20.2", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", @@ -2288,14 +2276,14 @@ } }, "node_modules/@humanwhocodes/config-array": { - "version": "0.11.6", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.6.tgz", - "integrity": "sha512-jJr+hPTJYKyDILJfhNSHsjiwXYf26Flsz8DvNndOsHs5pwSnpGUEy8yzF0JYhCEvTDdV2vuOK5tt8BVhwO5/hg==", + "version": "0.11.8", + "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz", + "integrity": "sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==", "dev": true, "dependencies": { "@humanwhocodes/object-schema": "^1.2.1", "debug": "^4.1.1", - "minimatch": "^3.0.4" + "minimatch": "^3.0.5" }, "engines": { "node": ">=10.10.0" @@ -6722,13 +6710,13 @@ } }, "node_modules/eslint": { - "version": "8.29.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.29.0.tgz", - "integrity": "sha512-isQ4EEiyUjZFbEKvEGJKKGBwXtvXX+zJbkVKCgTuB9t/+jUBcy8avhkEwWJecI15BkRkOYmvIM5ynbhRjEkoeg==", + "version": "8.30.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.30.0.tgz", + "integrity": "sha512-MGADB39QqYuzEGov+F/qb18r4i7DohCDOfatHaxI2iGlPuC65bwG2gxgO+7DkyL38dRFaRH7RaRAgU6JKL9rMQ==", "dev": true, "dependencies": { - "@eslint/eslintrc": "^1.3.3", - "@humanwhocodes/config-array": "^0.11.6", + "@eslint/eslintrc": "^1.4.0", + "@humanwhocodes/config-array": "^0.11.8", "@humanwhocodes/module-importer": "^1.0.1", "@nodelib/fs.walk": "^1.2.8", "ajv": "^6.10.0", @@ -6747,7 +6735,7 @@ "file-entry-cache": "^6.0.1", "find-up": "^5.0.0", "glob-parent": "^6.0.2", - "globals": "^13.15.0", + "globals": "^13.19.0", "grapheme-splitter": "^1.0.4", "ignore": "^5.2.0", "import-fresh": "^3.0.0", @@ -6912,18 +6900,6 @@ "node": ">=0.10.0" } }, - "node_modules/eslint-plugin-import/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, "node_modules/eslint-plugin-import/node_modules/ms": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", @@ -6985,19 +6961,6 @@ "node": ">=10" } }, - "node_modules/eslint-plugin-n/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "peer": true, - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, "node_modules/eslint-plugin-n/node_modules/semver": { "version": "7.3.7", "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", @@ -7244,9 +7207,9 @@ } }, "node_modules/eslint/node_modules/globals": { - "version": "13.15.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.15.0.tgz", - "integrity": "sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog==", + "version": "13.19.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.19.0.tgz", + "integrity": "sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ==", "dev": true, "dependencies": { "type-fest": "^0.20.2" @@ -7294,18 +7257,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, "node_modules/eslint/node_modules/p-locate": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", @@ -7355,9 +7306,9 @@ } }, "node_modules/espree": { - "version": "9.4.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.4.0.tgz", - "integrity": "sha512-DQmnRpLj7f6TgN/NYb0MTzJXL+vJF9h3pHy4JhCIs3zwcgez8xmGg3sXHcEO97BrmO2OSvCwMdfdlyl+E9KjOw==", + "version": "9.4.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.4.1.tgz", + "integrity": "sha512-XwctdmTO6SIvCzd9810yyNzIrOrqNYV9Koizx4C/mRhf9uq0o4yHoCEU/670pOxOL/MSraektvSAji79kX90Vg==", "dev": true, "dependencies": { "acorn": "^8.8.0", @@ -12276,9 +12227,9 @@ "integrity": "sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo=" }, "node_modules/minimatch": { - "version": "3.0.8", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.8.tgz", - "integrity": "sha512-6FsRAQsxQ61mw+qP1ZzbL9Bc78x2p5OqNgNpnoAFLTrX8n5Kxph0CsnhmKKNXTWjXqU5L0pGPR7hYk+XWZr60Q==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, "dependencies": { "brace-expansion": "^1.1.7" @@ -18172,15 +18123,15 @@ "integrity": "sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg==" }, "@eslint/eslintrc": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.3.tgz", - "integrity": "sha512-uj3pT6Mg+3t39fvLrj8iuCIJ38zKO9FpGtJ4BBJebJhEwjoT+KLVNCcHT5QC9NGRIEi7fZ0ZR8YRb884auB4Lg==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.4.0.tgz", + "integrity": "sha512-7yfvXy6MWLgWSFsLhz5yH3iQ52St8cdUY6FoGieKkRDVxuxmrNuUetIuu6cmjNWwniUHiWXjxCr5tTXDrbYS5A==", "dev": true, "requires": { "ajv": "^6.12.4", "debug": "^4.3.2", "espree": "^9.4.0", - "globals": "^13.15.0", + "globals": "^13.19.0", "ignore": "^5.2.0", "import-fresh": "^3.2.1", "js-yaml": "^4.1.0", @@ -18195,9 +18146,9 @@ "dev": true }, "globals": { - "version": "13.17.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.17.0.tgz", - "integrity": "sha512-1C+6nQRb1GwGMKm2dH/E7enFAMxGTmGI7/dEdhy/DNelv85w9B72t3uc5frtMNXIbzrarJJ/lTCjcaZwbLJmyw==", + "version": "13.19.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.19.0.tgz", + "integrity": "sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ==", "dev": true, "requires": { "type-fest": "^0.20.2" @@ -18212,15 +18163,6 @@ "argparse": "^2.0.1" } }, - "minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, "type-fest": { "version": "0.20.2", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", @@ -18447,14 +18389,14 @@ "integrity": "sha512-viouXhegu/TjkvYQoiRZK3aax69dGXxgEjpvZW81wIJdxm5Fnvp3VVIP4VHKqX4SvFw6qpmkILkD4RJWAdrt7A==" }, "@humanwhocodes/config-array": { - "version": "0.11.6", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.6.tgz", - "integrity": "sha512-jJr+hPTJYKyDILJfhNSHsjiwXYf26Flsz8DvNndOsHs5pwSnpGUEy8yzF0JYhCEvTDdV2vuOK5tt8BVhwO5/hg==", + "version": "0.11.8", + "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz", + "integrity": "sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==", "dev": true, "requires": { "@humanwhocodes/object-schema": "^1.2.1", "debug": "^4.1.1", - "minimatch": "^3.0.4" + "minimatch": "^3.0.5" } }, "@humanwhocodes/module-importer": { @@ -21938,13 +21880,13 @@ } }, "eslint": { - "version": "8.29.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.29.0.tgz", - "integrity": "sha512-isQ4EEiyUjZFbEKvEGJKKGBwXtvXX+zJbkVKCgTuB9t/+jUBcy8avhkEwWJecI15BkRkOYmvIM5ynbhRjEkoeg==", + "version": "8.30.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.30.0.tgz", + "integrity": "sha512-MGADB39QqYuzEGov+F/qb18r4i7DohCDOfatHaxI2iGlPuC65bwG2gxgO+7DkyL38dRFaRH7RaRAgU6JKL9rMQ==", "dev": true, "requires": { - "@eslint/eslintrc": "^1.3.3", - "@humanwhocodes/config-array": "^0.11.6", + "@eslint/eslintrc": "^1.4.0", + "@humanwhocodes/config-array": "^0.11.8", "@humanwhocodes/module-importer": "^1.0.1", "@nodelib/fs.walk": "^1.2.8", "ajv": "^6.10.0", @@ -21963,7 +21905,7 @@ "file-entry-cache": "^6.0.1", "find-up": "^5.0.0", "glob-parent": "^6.0.2", - "globals": "^13.15.0", + "globals": "^13.19.0", "grapheme-splitter": "^1.0.4", "ignore": "^5.2.0", "import-fresh": "^3.0.0", @@ -22074,9 +22016,9 @@ } }, "globals": { - "version": "13.15.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.15.0.tgz", - "integrity": "sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog==", + "version": "13.19.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.19.0.tgz", + "integrity": "sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ==", "dev": true, "requires": { "type-fest": "^0.20.2" @@ -22106,15 +22048,6 @@ "p-locate": "^5.0.0" } }, - "minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, "p-locate": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", @@ -22246,15 +22179,6 @@ "esutils": "^2.0.2" } }, - "minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, "ms": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", @@ -22297,16 +22221,6 @@ "dev": true, "peer": true }, - "minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "dev": true, - "peer": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, "semver": { "version": "7.3.7", "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", @@ -22386,9 +22300,9 @@ "dev": true }, "espree": { - "version": "9.4.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.4.0.tgz", - "integrity": "sha512-DQmnRpLj7f6TgN/NYb0MTzJXL+vJF9h3pHy4JhCIs3zwcgez8xmGg3sXHcEO97BrmO2OSvCwMdfdlyl+E9KjOw==", + "version": "9.4.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.4.1.tgz", + "integrity": "sha512-XwctdmTO6SIvCzd9810yyNzIrOrqNYV9Koizx4C/mRhf9uq0o4yHoCEU/670pOxOL/MSraektvSAji79kX90Vg==", "dev": true, "requires": { "acorn": "^8.8.0", @@ -26251,9 +26165,9 @@ "integrity": "sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo=" }, "minimatch": { - "version": "3.0.8", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.8.tgz", - "integrity": "sha512-6FsRAQsxQ61mw+qP1ZzbL9Bc78x2p5OqNgNpnoAFLTrX8n5Kxph0CsnhmKKNXTWjXqU5L0pGPR7hYk+XWZr60Q==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dev": true, "requires": { "brace-expansion": "^1.1.7" diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index 59580d619d..3af02564dd 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -87,7 +87,7 @@ "copy-webpack-plugin": "^11.0.0", "css-loader": "^5.2.7", "css-minimizer-webpack-plugin": "^4.2.2", - "eslint": "^8.29.0", + "eslint": "^8.30.0", "eslint-config-standard": "^17.0.0", "eslint-plugin-import": "^2.26.0", "eslint-plugin-node": "^11.1.0", From 151f649d3263884edf87dd73b2c07a8ed1f1e460 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Dec 2022 18:13:15 +0000 Subject: [PATCH 20/29] Bump sass from 1.56.2 to 1.57.0 in /apps/block_scout_web/assets Bumps [sass](https://github.com/sass/dart-sass) from 1.56.2 to 1.57.0. - [Release notes](https://github.com/sass/dart-sass/releases) - [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md) - [Commits](https://github.com/sass/dart-sass/compare/1.56.2...1.57.0) --- updated-dependencies: - dependency-name: sass dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 14 +++++++------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 1a98c9e3b0..343bd96c20 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -86,7 +86,7 @@ "mini-css-extract-plugin": "^2.7.2", "postcss": "^8.4.20", "postcss-loader": "^7.0.2", - "sass": "^1.56.2", + "sass": "^1.57.0", "sass-loader": "^13.2.0", "style-loader": "^3.3.1", "webpack": "^5.75.0", @@ -14400,9 +14400,9 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "node_modules/sass": { - "version": "1.56.2", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.56.2.tgz", - "integrity": "sha512-ciEJhnyCRwzlBCB+h5cCPM6ie/6f8HrhZMQOf5vlU60Y1bI1rx5Zb0vlDZvaycHsg/MqFfF1Eq2eokAa32iw8w==", + "version": "1.57.0", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.0.tgz", + "integrity": "sha512-IZNEJDTK1cF5B1cGA593TPAV/1S0ysUDxq9XHjX/+SMy0QfUny+nfUsq5ZP7wWSl4eEf7wDJcEZ8ABYFmh3m/w==", "dev": true, "dependencies": { "chokidar": ">=3.0.0 <4.0.0", @@ -27797,9 +27797,9 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "sass": { - "version": "1.56.2", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.56.2.tgz", - "integrity": "sha512-ciEJhnyCRwzlBCB+h5cCPM6ie/6f8HrhZMQOf5vlU60Y1bI1rx5Zb0vlDZvaycHsg/MqFfF1Eq2eokAa32iw8w==", + "version": "1.57.0", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.0.tgz", + "integrity": "sha512-IZNEJDTK1cF5B1cGA593TPAV/1S0ysUDxq9XHjX/+SMy0QfUny+nfUsq5ZP7wWSl4eEf7wDJcEZ8ABYFmh3m/w==", "dev": true, "requires": { "chokidar": ">=3.0.0 <4.0.0", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index 59580d619d..56ba8fe788 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -98,7 +98,7 @@ "mini-css-extract-plugin": "^2.7.2", "postcss": "^8.4.20", "postcss-loader": "^7.0.2", - "sass": "^1.56.2", + "sass": "^1.57.0", "sass-loader": "^13.2.0", "style-loader": "^3.3.1", "webpack": "^5.75.0", From 2e204e6a6b934d4d70795fcc5ad64743ab7082e5 Mon Sep 17 00:00:00 2001 From: sl1depengwyn Date: Tue, 20 Dec 2022 11:05:37 +0300 Subject: [PATCH 21/29] Add env vars for analytics --- docker-compose/envs/common-blockscout.env | 6 +++++- docker/Dockerfile | 4 ++++ docker/Makefile | 12 ++++++++++++ 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/docker-compose/envs/common-blockscout.env b/docker-compose/envs/common-blockscout.env index 73c936dbfa..d152c17bb7 100644 --- a/docker-compose/envs/common-blockscout.env +++ b/docker-compose/envs/common-blockscout.env @@ -154,4 +154,8 @@ VISUALIZE_SOL2UML_SERVICE_URL=http://host.docker.internal:8050/ # ACCOUNT_SENDGRID_TEMPLATE= ACCOUNT_CLOAK_KEY= ACCOUNT_ENABLED=false -ACCOUNT_REDIS_URL=redis://redis_db:6379 \ No newline at end of file +ACCOUNT_REDIS_URL=redis://redis_db:6379 +# MIXPANEL_TOKEN= +# MIXPANEL_URL= +# AMPLITUDE_API_KEY= +# AMPLITUDE_URL= \ No newline at end of file diff --git a/docker/Dockerfile b/docker/Dockerfile index 00eea0e2cf..10d7e97b8b 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -35,6 +35,10 @@ ARG ADMIN_PANEL_ENABLED ARG CACHE_ADDRESS_WITH_BALANCES_UPDATE_INTERVAL ARG SOCKET_ROOT ARG SESSION_COOKIE_DOMAIN +ARG MIXPANEL_TOKEN +ARG MIXPANEL_URL +ARG AMPLITUDE_API_KEY +ARG AMPLITUDE_URL # Cache elixir deps ADD mix.exs mix.lock ./ diff --git a/docker/Makefile b/docker/Makefile index 7c420a7710..d4d3123f63 100644 --- a/docker/Makefile +++ b/docker/Makefile @@ -556,6 +556,18 @@ endif ifdef VISUALIZE_SOL2UML_SERVICE_URL BLOCKSCOUT_CONTAINER_PARAMS += -e 'VISUALIZE_SOL2UML_SERVICE_URL=$(VISUALIZE_SOL2UML_SERVICE_URL)' endif +ifdef MIXPANEL_TOKEN + BLOCKSCOUT_CONTAINER_PARAMS += -e 'MIXPANEL_TOKEN=$(MIXPANEL_TOKEN)' +endif +ifdef MIXPANEL_URL + BLOCKSCOUT_CONTAINER_PARAMS += -e 'MIXPANEL_URL=$(MIXPANEL_URL)' +endif +ifdef AMPLITUDE_API_KEY + BLOCKSCOUT_CONTAINER_PARAMS += -e 'AMPLITUDE_API_KEY=$(AMPLITUDE_API_KEY)' +endif +ifdef AMPLITUDE_URL + BLOCKSCOUT_CONTAINER_PARAMS += -e 'AMPLITUDE_URL=$(AMPLITUDE_URL)' +endif HAS_BLOCKSCOUT_IMAGE := $(shell docker images | grep -sw "${BS_CONTAINER_IMAGE} ") From c24776179bf22424896b921e41075751118db9fc Mon Sep 17 00:00:00 2001 From: hp Date: Tue, 20 Dec 2022 10:21:45 +0000 Subject: [PATCH 22/29] handling stale error when try delete notification --- .../lib/explorer/chain/events/listener.ex | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/apps/explorer/lib/explorer/chain/events/listener.ex b/apps/explorer/lib/explorer/chain/events/listener.ex index c03e1746ef..ac59d95812 100644 --- a/apps/explorer/lib/explorer/chain/events/listener.ex +++ b/apps/explorer/lib/explorer/chain/events/listener.ex @@ -25,10 +25,13 @@ defmodule Explorer.Chain.Events.Listener do end def handle_info({:notification, _pid, _ref, _topic, payload}, state) do - payload - |> expand_payload() - |> decode_payload!() - |> broadcast() + expanded_payload = expand_payload(payload) + + if expanded_payload != nil do + expanded_payload + |> decode_payload!() + |> broadcast() + end {:noreply, state} end @@ -69,7 +72,12 @@ defmodule Explorer.Chain.Events.Listener do nil %{data: data} = notification -> - Repo.delete(notification) + try do + Repo.delete(notification) + rescue + Ecto.StaleEntryError -> nil + end + data end end From 1a7808c60104537466385c4b2a591d95b071214e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 Dec 2022 18:09:39 +0000 Subject: [PATCH 23/29] Bump @amplitude/analytics-browser in /apps/block_scout_web/assets Bumps [@amplitude/analytics-browser](https://github.com/amplitude/Amplitude-TypeScript) from 1.6.1 to 1.6.6. - [Release notes](https://github.com/amplitude/Amplitude-TypeScript/releases) - [Commits](https://github.com/amplitude/Amplitude-TypeScript/compare/@amplitude/analytics-browser@1.6.1...@amplitude/analytics-browser@1.6.6) --- updated-dependencies: - dependency-name: "@amplitude/analytics-browser" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 74 +++++++++---------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 38 insertions(+), 38 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 30d0809cc0..162c6ff2f7 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -7,7 +7,7 @@ "name": "blockscout", "license": "GPL-3.0", "dependencies": { - "@amplitude/analytics-browser": "^1.6.1", + "@amplitude/analytics-browser": "^1.6.6", "@fortawesome/fontawesome-free": "^6.2.1", "@tarekraafat/autocomplete.js": "^10.2.7", "@walletconnect/web3-provider": "^1.8.0", @@ -106,13 +106,13 @@ "version": "0.0.1" }, "node_modules/@amplitude/analytics-browser": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.1.tgz", - "integrity": "sha512-i9Mt3p6ikZm7zu6QRMIziSzNwWW3F2zEIKoOoBbMxy97hSliM93/VoLBLOzwMhusHK3Xy5OwcIgYVUHdXbmigw==", + "version": "1.6.6", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.6.tgz", + "integrity": "sha512-tR7JH5TPNt9h1PMOhnMP+aJdmty81ZaFg9UhIXHf86Crdac2GoYLXnzq3vMNK2Ad809jcGKssXJnVFkfXGxgIg==", "dependencies": { - "@amplitude/analytics-client-common": "^0.4.0", - "@amplitude/analytics-core": "^0.10.0", - "@amplitude/analytics-types": "^0.12.0", + "@amplitude/analytics-client-common": "^0.5.0", + "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-types": "^0.14.0", "@amplitude/ua-parser-js": "^0.7.31", "tslib": "^2.3.1" } @@ -123,13 +123,13 @@ "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" }, "node_modules/@amplitude/analytics-client-common": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.4.0.tgz", - "integrity": "sha512-I3cy6AYCiVUqXAD6yU+tm3qBZdEyrdruDaUS/vVPoi+MvHIkZIXw7xaQjmkBRURWCgdcxu5LioU8r1ld1widtA==", + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.5.0.tgz", + "integrity": "sha512-kqtv26b1bZoeGpQLaLqxW4E88S042++0mjpjCe/ekKbmk8pNlmq7nF3dfZZMDmtcAia7Z0YOxvZNgWoNPgiAUw==", "dependencies": { "@amplitude/analytics-connector": "^1.4.5", - "@amplitude/analytics-core": "^0.10.0", - "@amplitude/analytics-types": "^0.12.0", + "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-types": "^0.14.0", "tslib": "^2.3.1" } }, @@ -147,11 +147,11 @@ } }, "node_modules/@amplitude/analytics-core": { - "version": "0.10.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.10.0.tgz", - "integrity": "sha512-D/6U9SzyDmcNWnT/lFnBKfYl4ASicLlwD1tqu4RZoYS3SwHd/PNST+LbnL3yBTEIJIY//qjth9lLBh/RRzePfg==", + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.11.0.tgz", + "integrity": "sha512-0X/3xMR/Ljl6JVgsIVALhKn9pBHxgyRgDqWIeRlwdingWIeWttQP8+TSpGI2S9xIeUdAdo0Urul/NMJGHFs07Q==", "dependencies": { - "@amplitude/analytics-types": "^0.12.0", + "@amplitude/analytics-types": "^0.14.0", "tslib": "^2.3.1" } }, @@ -161,9 +161,9 @@ "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" }, "node_modules/@amplitude/analytics-types": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-types/-/analytics-types-0.12.0.tgz", - "integrity": "sha512-XwySEhnCdU8fNWUNaB38JS7bwOt4GOUG8OqgzuXtR8HvGnpCvuT7C6H+BIGA7MfctNQBAzR+6IBgDD+8r1/OEQ==" + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-types/-/analytics-types-0.14.0.tgz", + "integrity": "sha512-O3E/KHyWCb4HAlYevqgCzqQdS+0LhbJV2IeVGox2eyCge+/lGwtGdJV2rJNWcoGf3p+BhnbqJBlhkPMs12iniA==" }, "node_modules/@amplitude/ua-parser-js": { "version": "0.7.31", @@ -17022,13 +17022,13 @@ }, "dependencies": { "@amplitude/analytics-browser": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.1.tgz", - "integrity": "sha512-i9Mt3p6ikZm7zu6QRMIziSzNwWW3F2zEIKoOoBbMxy97hSliM93/VoLBLOzwMhusHK3Xy5OwcIgYVUHdXbmigw==", + "version": "1.6.6", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.6.tgz", + "integrity": "sha512-tR7JH5TPNt9h1PMOhnMP+aJdmty81ZaFg9UhIXHf86Crdac2GoYLXnzq3vMNK2Ad809jcGKssXJnVFkfXGxgIg==", "requires": { - "@amplitude/analytics-client-common": "^0.4.0", - "@amplitude/analytics-core": "^0.10.0", - "@amplitude/analytics-types": "^0.12.0", + "@amplitude/analytics-client-common": "^0.5.0", + "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-types": "^0.14.0", "@amplitude/ua-parser-js": "^0.7.31", "tslib": "^2.3.1" }, @@ -17041,13 +17041,13 @@ } }, "@amplitude/analytics-client-common": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.4.0.tgz", - "integrity": "sha512-I3cy6AYCiVUqXAD6yU+tm3qBZdEyrdruDaUS/vVPoi+MvHIkZIXw7xaQjmkBRURWCgdcxu5LioU8r1ld1widtA==", + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.5.0.tgz", + "integrity": "sha512-kqtv26b1bZoeGpQLaLqxW4E88S042++0mjpjCe/ekKbmk8pNlmq7nF3dfZZMDmtcAia7Z0YOxvZNgWoNPgiAUw==", "requires": { "@amplitude/analytics-connector": "^1.4.5", - "@amplitude/analytics-core": "^0.10.0", - "@amplitude/analytics-types": "^0.12.0", + "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-types": "^0.14.0", "tslib": "^2.3.1" }, "dependencies": { @@ -17067,11 +17067,11 @@ } }, "@amplitude/analytics-core": { - "version": "0.10.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.10.0.tgz", - "integrity": "sha512-D/6U9SzyDmcNWnT/lFnBKfYl4ASicLlwD1tqu4RZoYS3SwHd/PNST+LbnL3yBTEIJIY//qjth9lLBh/RRzePfg==", + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.11.0.tgz", + "integrity": "sha512-0X/3xMR/Ljl6JVgsIVALhKn9pBHxgyRgDqWIeRlwdingWIeWttQP8+TSpGI2S9xIeUdAdo0Urul/NMJGHFs07Q==", "requires": { - "@amplitude/analytics-types": "^0.12.0", + "@amplitude/analytics-types": "^0.14.0", "tslib": "^2.3.1" }, "dependencies": { @@ -17083,9 +17083,9 @@ } }, "@amplitude/analytics-types": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-types/-/analytics-types-0.12.0.tgz", - "integrity": "sha512-XwySEhnCdU8fNWUNaB38JS7bwOt4GOUG8OqgzuXtR8HvGnpCvuT7C6H+BIGA7MfctNQBAzR+6IBgDD+8r1/OEQ==" + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-types/-/analytics-types-0.14.0.tgz", + "integrity": "sha512-O3E/KHyWCb4HAlYevqgCzqQdS+0LhbJV2IeVGox2eyCge+/lGwtGdJV2rJNWcoGf3p+BhnbqJBlhkPMs12iniA==" }, "@amplitude/ua-parser-js": { "version": "0.7.31", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index bf2a4c4766..1a42bca2f8 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -20,7 +20,7 @@ }, "dependencies": { "@fortawesome/fontawesome-free": "^6.2.1", - "@amplitude/analytics-browser": "^1.6.1", + "@amplitude/analytics-browser": "^1.6.6", "@tarekraafat/autocomplete.js": "^10.2.7", "@walletconnect/web3-provider": "^1.8.0", "assert": "^2.0.0", From b281c25ce31b846a1812ee6c6aafe6295fa75674 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 Dec 2022 18:10:27 +0000 Subject: [PATCH 24/29] Bump sass from 1.57.0 to 1.57.1 in /apps/block_scout_web/assets Bumps [sass](https://github.com/sass/dart-sass) from 1.57.0 to 1.57.1. - [Release notes](https://github.com/sass/dart-sass/releases) - [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md) - [Commits](https://github.com/sass/dart-sass/compare/1.57.0...1.57.1) --- updated-dependencies: - dependency-name: sass dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 14 +++++++------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 30d0809cc0..b18527d16f 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -88,7 +88,7 @@ "mini-css-extract-plugin": "^2.7.2", "postcss": "^8.4.20", "postcss-loader": "^7.0.2", - "sass": "^1.57.0", + "sass": "^1.57.1", "sass-loader": "^13.2.0", "style-loader": "^3.3.1", "webpack": "^5.75.0", @@ -14436,9 +14436,9 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "node_modules/sass": { - "version": "1.57.0", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.0.tgz", - "integrity": "sha512-IZNEJDTK1cF5B1cGA593TPAV/1S0ysUDxq9XHjX/+SMy0QfUny+nfUsq5ZP7wWSl4eEf7wDJcEZ8ABYFmh3m/w==", + "version": "1.57.1", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", + "integrity": "sha512-O2+LwLS79op7GI0xZ8fqzF7X2m/m8WFfI02dHOdsK5R2ECeS5F62zrwg/relM1rjSLy7Vd/DiMNIvPrQGsA0jw==", "dev": true, "dependencies": { "chokidar": ">=3.0.0 <4.0.0", @@ -27872,9 +27872,9 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "sass": { - "version": "1.57.0", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.0.tgz", - "integrity": "sha512-IZNEJDTK1cF5B1cGA593TPAV/1S0ysUDxq9XHjX/+SMy0QfUny+nfUsq5ZP7wWSl4eEf7wDJcEZ8ABYFmh3m/w==", + "version": "1.57.1", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", + "integrity": "sha512-O2+LwLS79op7GI0xZ8fqzF7X2m/m8WFfI02dHOdsK5R2ECeS5F62zrwg/relM1rjSLy7Vd/DiMNIvPrQGsA0jw==", "dev": true, "requires": { "chokidar": ">=3.0.0 <4.0.0", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index bf2a4c4766..d6a127d1f1 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -100,7 +100,7 @@ "mini-css-extract-plugin": "^2.7.2", "postcss": "^8.4.20", "postcss-loader": "^7.0.2", - "sass": "^1.57.0", + "sass": "^1.57.1", "sass-loader": "^13.2.0", "style-loader": "^3.3.1", "webpack": "^5.75.0", From 2b691d6aaf607f6b3ee3fda102951ce12b936f90 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 Dec 2022 18:11:40 +0000 Subject: [PATCH 25/29] Bump sweetalert2 from 11.6.15 to 11.6.16 in /apps/block_scout_web/assets Bumps [sweetalert2](https://github.com/sweetalert2/sweetalert2) from 11.6.15 to 11.6.16. - [Release notes](https://github.com/sweetalert2/sweetalert2/releases) - [Changelog](https://github.com/sweetalert2/sweetalert2/blob/main/CHANGELOG.md) - [Commits](https://github.com/sweetalert2/sweetalert2/compare/v11.6.15...v11.6.16) --- updated-dependencies: - dependency-name: sweetalert2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 14 +++++++------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 30d0809cc0..69ae182ce6 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -60,7 +60,7 @@ "redux": "^4.2.0", "stream-browserify": "^3.0.0", "stream-http": "^3.1.1", - "sweetalert2": "^11.6.15", + "sweetalert2": "^11.6.16", "urijs": "^1.19.11", "url": "^0.11.0", "util": "^0.12.5", @@ -15392,9 +15392,9 @@ "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==" }, "node_modules/sweetalert2": { - "version": "11.6.15", - "resolved": "https://registry.npmjs.org/sweetalert2/-/sweetalert2-11.6.15.tgz", - "integrity": "sha512-FqMy1gRGHEI5G145NE5XSP059TziCJu9Xf9/mkki/aKu5pLNcYzjggOzKO5Ex10EBgAGDXQ99jyGfYYzGCYXRQ==", + "version": "11.6.16", + "resolved": "https://registry.npmjs.org/sweetalert2/-/sweetalert2-11.6.16.tgz", + "integrity": "sha512-T2FO8LptErsjE4r0WMfiSk4YbeUvPadNaUZ/cADMEOnws000znrf8zFX9S5e/spvzJDyRI5En73WQyDZhGypxQ==", "funding": { "type": "individual", "url": "https://github.com/sponsors/limonte" @@ -28567,9 +28567,9 @@ } }, "sweetalert2": { - "version": "11.6.15", - "resolved": "https://registry.npmjs.org/sweetalert2/-/sweetalert2-11.6.15.tgz", - "integrity": "sha512-FqMy1gRGHEI5G145NE5XSP059TziCJu9Xf9/mkki/aKu5pLNcYzjggOzKO5Ex10EBgAGDXQ99jyGfYYzGCYXRQ==" + "version": "11.6.16", + "resolved": "https://registry.npmjs.org/sweetalert2/-/sweetalert2-11.6.16.tgz", + "integrity": "sha512-T2FO8LptErsjE4r0WMfiSk4YbeUvPadNaUZ/cADMEOnws000znrf8zFX9S5e/spvzJDyRI5En73WQyDZhGypxQ==" }, "symbol-tree": { "version": "3.2.4", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index bf2a4c4766..414a3e9d40 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -72,7 +72,7 @@ "redux": "^4.2.0", "stream-browserify": "^3.0.0", "stream-http": "^3.1.1", - "sweetalert2": "^11.6.15", + "sweetalert2": "^11.6.16", "urijs": "^1.19.11", "url": "^0.11.0", "util": "^0.12.5", From 14b3f21edd849282090193c54f8f384bdcfd82e0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 21 Dec 2022 18:08:15 +0000 Subject: [PATCH 26/29] Bump jquery from 3.6.2 to 3.6.3 in /apps/block_scout_web/assets Bumps [jquery](https://github.com/jquery/jquery) from 3.6.2 to 3.6.3. - [Release notes](https://github.com/jquery/jquery/releases) - [Commits](https://github.com/jquery/jquery/compare/3.6.2...3.6.3) --- updated-dependencies: - dependency-name: jquery dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 14 +++++++------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index dcc61a2d43..5b4abb383e 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -24,7 +24,7 @@ "highlight.js": "^11.7.0", "https-browserify": "^1.0.0", "humps": "^2.0.1", - "jquery": "^3.6.2", + "jquery": "^3.6.3", "js-cookie": "^3.0.1", "lodash.debounce": "^4.0.8", "lodash.differenceby": "^4.8.0", @@ -11394,9 +11394,9 @@ } }, "node_modules/jquery": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.2.tgz", - "integrity": "sha512-/e7ulNIEEYk1Z/l4X0vpxGt+B/dNsV8ghOPAWZaJs8pkGvsSC0tm33aMGylXcj/U7y4IcvwtMXPMyBFZn/gK9A==" + "version": "3.6.3", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.3.tgz", + "integrity": "sha512-bZ5Sy3YzKo9Fyc8wH2iIQK4JImJ6R0GWI9kL1/k7Z91ZBNgkRXE6U0JfHIizZbort8ZunhSI3jw9I6253ahKfg==" }, "node_modules/js-cookie": { "version": "3.0.1", @@ -25540,9 +25540,9 @@ } }, "jquery": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.2.tgz", - "integrity": "sha512-/e7ulNIEEYk1Z/l4X0vpxGt+B/dNsV8ghOPAWZaJs8pkGvsSC0tm33aMGylXcj/U7y4IcvwtMXPMyBFZn/gK9A==" + "version": "3.6.3", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.3.tgz", + "integrity": "sha512-bZ5Sy3YzKo9Fyc8wH2iIQK4JImJ6R0GWI9kL1/k7Z91ZBNgkRXE6U0JfHIizZbort8ZunhSI3jw9I6253ahKfg==" }, "js-cookie": { "version": "3.0.1", diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index 7fa4d56547..bbdf9a40b9 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -36,7 +36,7 @@ "highlight.js": "^11.7.0", "https-browserify": "^1.0.0", "humps": "^2.0.1", - "jquery": "^3.6.2", + "jquery": "^3.6.3", "js-cookie": "^3.0.1", "lodash.debounce": "^4.0.8", "lodash.differenceby": "^4.8.0", From 120be8f38e22e7f8b55c6c064f257b1b1ea2f085 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 21 Dec 2022 18:09:29 +0000 Subject: [PATCH 27/29] Bump ecto_sql from 3.9.1 to 3.9.2 Bumps [ecto_sql](https://github.com/elixir-ecto/ecto_sql) from 3.9.1 to 3.9.2. - [Release notes](https://github.com/elixir-ecto/ecto_sql/releases) - [Changelog](https://github.com/elixir-ecto/ecto_sql/blob/master/CHANGELOG.md) - [Commits](https://github.com/elixir-ecto/ecto_sql/compare/v3.9.1...v3.9.2) --- updated-dependencies: - dependency-name: ecto_sql dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- mix.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mix.lock b/mix.lock index 06eafd5161..93a169a88d 100644 --- a/mix.lock +++ b/mix.lock @@ -29,15 +29,15 @@ "credo": {:hex, :credo, "1.6.7", "323f5734350fd23a456f2688b9430e7d517afb313fbd38671b8a4449798a7854", [:mix], [{:bunt, "~> 0.2.1", [hex: :bunt, repo: "hexpm", optional: false]}, {:file_system, "~> 0.2.8", [hex: :file_system, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "41e110bfb007f7eda7f897c10bf019ceab9a0b269ce79f015d54b0dcf4fc7dd3"}, "csv": {:hex, :csv, "2.5.0", "c47b5a5221bf2e56d6e8eb79e77884046d7fd516280dc7d9b674251e0ae46246", [:mix], [{:parallel_stream, "~> 1.0.4 or ~> 1.1.0", [hex: :parallel_stream, repo: "hexpm", optional: false]}], "hexpm", "e821f541487045c7591a1963eeb42afff0dfa99bdcdbeb3410795a2f59c77d34"}, "dataloader": {:hex, :dataloader, "1.0.10", "a42f07641b1a0572e0b21a2a5ae1be11da486a6790f3d0d14512d96ff3e3bbe9", [:mix], [{:ecto, ">= 3.4.3 and < 4.0.0", [hex: :ecto, repo: "hexpm", optional: true]}, {:telemetry, "~> 1.0 or ~> 0.4", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "54cd70cec09addf4b2ace14cc186a283a149fd4d3ec5475b155951bf33cd963f"}, - "db_connection": {:hex, :db_connection, "2.4.2", "f92e79aff2375299a16bcb069a14ee8615c3414863a6fef93156aee8e86c2ff3", [:mix], [{:connection, "~> 1.0", [hex: :connection, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "4fe53ca91b99f55ea249693a0229356a08f4d1a7931d8ffa79289b145fe83668"}, + "db_connection": {:hex, :db_connection, "2.4.3", "3b9aac9f27347ec65b271847e6baeb4443d8474289bd18c1d6f4de655b70c94d", [:mix], [{:connection, "~> 1.0", [hex: :connection, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "c127c15b0fa6cfb32eed07465e05da6c815b032508d4ed7c116122871df73c12"}, "decimal": {:hex, :decimal, "2.0.0", "a78296e617b0f5dd4c6caf57c714431347912ffb1d0842e998e9792b5642d697", [:mix], [], "hexpm", "34666e9c55dea81013e77d9d87370fe6cb6291d1ef32f46a1600230b1d44f577"}, "decorator": {:hex, :decorator, "1.4.0", "a57ac32c823ea7e4e67f5af56412d12b33274661bb7640ec7fc882f8d23ac419", [:mix], [], "hexpm", "0a07cedd9083da875c7418dea95b78361197cf2bf3211d743f6f7ce39656597f"}, "deep_merge": {:hex, :deep_merge, "1.0.0", "b4aa1a0d1acac393bdf38b2291af38cb1d4a52806cf7a4906f718e1feb5ee961", [:mix], [], "hexpm", "ce708e5f094b9cd4e8f2be4f00d2f4250c4095be93f8cd6d018c753894885430"}, "dialyxir": {:hex, :dialyxir, "1.2.0", "58344b3e87c2e7095304c81a9ae65cb68b613e28340690dfe1a5597fd08dec37", [:mix], [{:erlex, ">= 0.2.6", [hex: :erlex, repo: "hexpm", optional: false]}], "hexpm", "61072136427a851674cab81762be4dbeae7679f85b1272b6d25c3a839aff8463"}, "digital_token": {:hex, :digital_token, "0.4.0", "2ad6894d4a40be8b2890aad286ecd5745fa473fa5699d80361a8c94428edcd1f", [:mix], [{:cldr_utils, "~> 2.17", [hex: :cldr_utils, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "a178edf61d1fee5bb3c34e14b0f4ee21809ee87cade8738f87337e59e5e66e26"}, "earmark_parser": {:hex, :earmark_parser, "1.4.29", "149d50dcb3a93d9f3d6f3ecf18c918fb5a2d3c001b5d3305c926cddfbd33355b", [:mix], [], "hexpm", "4902af1b3eb139016aed210888748db8070b8125c2342ce3dcae4f38dcc63503"}, - "ecto": {:hex, :ecto, "3.9.2", "017db3bc786ff64271108522c01a5d3f6ba0aea5c84912cfb0dd73bf13684108", [:mix], [{:decimal, "~> 1.6 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "21466d5177e09e55289ac7eade579a642578242c7a3a9f91ad5c6583337a9d15"}, - "ecto_sql": {:hex, :ecto_sql, "3.9.1", "9bd5894eecc53d5b39d0c95180d4466aff00e10679e13a5cfa725f6f85c03c22", [:mix], [{:db_connection, "~> 2.5 or ~> 2.4.1", [hex: :db_connection, repo: "hexpm", optional: false]}, {:ecto, "~> 3.9.0", [hex: :ecto, repo: "hexpm", optional: false]}, {:myxql, "~> 0.6.0", [hex: :myxql, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.16.0 or ~> 1.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:tds, "~> 2.1.1 or ~> 2.2", [hex: :tds, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "5fd470a4fff2e829bbf9dcceb7f3f9f6d1e49b4241e802f614de6b8b67c51118"}, + "ecto": {:hex, :ecto, "3.9.3", "d98ed414404f96eb07261074fef0548782628e3fbb06c7d1e4ea152a441b8493", [:mix], [{:decimal, "~> 1.6 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "7695b41246b78d5043f1e06836965e2aa5d065ba7667263782e557da5bf07ccb"}, + "ecto_sql": {:hex, :ecto_sql, "3.9.2", "34227501abe92dba10d9c3495ab6770e75e79b836d114c41108a4bf2ce200ad5", [:mix], [{:db_connection, "~> 2.5 or ~> 2.4.1", [hex: :db_connection, repo: "hexpm", optional: false]}, {:ecto, "~> 3.9.2", [hex: :ecto, repo: "hexpm", optional: false]}, {:myxql, "~> 0.6.0", [hex: :myxql, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.16.0 or ~> 1.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:tds, "~> 2.1.1 or ~> 2.2", [hex: :tds, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "1eb5eeb4358fdbcd42eac11c1fbd87e3affd7904e639d77903c1358b2abd3f70"}, "elixir_make": {:hex, :elixir_make, "0.6.3", "bc07d53221216838d79e03a8019d0839786703129599e9619f4ab74c8c096eac", [:mix], [], "hexpm", "f5cbd651c5678bcaabdbb7857658ee106b12509cd976c2c2fca99688e1daf716"}, "erlex": {:hex, :erlex, "0.2.6", "c7987d15e899c7a2f34f5420d2a2ea0d659682c06ac607572df55a43753aa12e", [:mix], [], "hexpm", "2ed2e25711feb44d52b17d2780eabf998452f6efda104877a3881c2f8c0c0c75"}, "ex_abi": {:hex, :ex_abi, "0.5.16", "735f14937bc3c8fd53c38f02936ef8bf93d26a0b999cb0230b105d901530acaf", [:mix], [{:ex_keccak, "~> 0.6.0", [hex: :ex_keccak, repo: "hexpm", optional: false]}, {:jason, "~> 1.4", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "82ee815f438c5d29ddc3e151a23a9eb5e906f3472cc6f5005b6f5a7f37332efe"}, From 4d80ddb82254f2dc71dd21aab05fedd77470b1ab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 22 Dec 2022 11:05:08 +0000 Subject: [PATCH 28/29] Bump ecto from 3.9.3 to 3.9.4 Bumps [ecto](https://github.com/elixir-ecto/ecto) from 3.9.3 to 3.9.4. - [Release notes](https://github.com/elixir-ecto/ecto/releases) - [Changelog](https://github.com/elixir-ecto/ecto/blob/v3.9.4/CHANGELOG.md) - [Commits](https://github.com/elixir-ecto/ecto/compare/v3.9.3...v3.9.4) --- updated-dependencies: - dependency-name: ecto dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- mix.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mix.lock b/mix.lock index 93a169a88d..855b8f29a5 100644 --- a/mix.lock +++ b/mix.lock @@ -36,7 +36,7 @@ "dialyxir": {:hex, :dialyxir, "1.2.0", "58344b3e87c2e7095304c81a9ae65cb68b613e28340690dfe1a5597fd08dec37", [:mix], [{:erlex, ">= 0.2.6", [hex: :erlex, repo: "hexpm", optional: false]}], "hexpm", "61072136427a851674cab81762be4dbeae7679f85b1272b6d25c3a839aff8463"}, "digital_token": {:hex, :digital_token, "0.4.0", "2ad6894d4a40be8b2890aad286ecd5745fa473fa5699d80361a8c94428edcd1f", [:mix], [{:cldr_utils, "~> 2.17", [hex: :cldr_utils, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "a178edf61d1fee5bb3c34e14b0f4ee21809ee87cade8738f87337e59e5e66e26"}, "earmark_parser": {:hex, :earmark_parser, "1.4.29", "149d50dcb3a93d9f3d6f3ecf18c918fb5a2d3c001b5d3305c926cddfbd33355b", [:mix], [], "hexpm", "4902af1b3eb139016aed210888748db8070b8125c2342ce3dcae4f38dcc63503"}, - "ecto": {:hex, :ecto, "3.9.3", "d98ed414404f96eb07261074fef0548782628e3fbb06c7d1e4ea152a441b8493", [:mix], [{:decimal, "~> 1.6 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "7695b41246b78d5043f1e06836965e2aa5d065ba7667263782e557da5bf07ccb"}, + "ecto": {:hex, :ecto, "3.9.4", "3ee68e25dbe0c36f980f1ba5dd41ee0d3eb0873bccae8aeaf1a2647242bffa35", [:mix], [{:decimal, "~> 1.6 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "de5f988c142a3aa4ec18b85a4ec34a2390b65b24f02385c1144252ff6ff8ee75"}, "ecto_sql": {:hex, :ecto_sql, "3.9.2", "34227501abe92dba10d9c3495ab6770e75e79b836d114c41108a4bf2ce200ad5", [:mix], [{:db_connection, "~> 2.5 or ~> 2.4.1", [hex: :db_connection, repo: "hexpm", optional: false]}, {:ecto, "~> 3.9.2", [hex: :ecto, repo: "hexpm", optional: false]}, {:myxql, "~> 0.6.0", [hex: :myxql, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.16.0 or ~> 1.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:tds, "~> 2.1.1 or ~> 2.2", [hex: :tds, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "1eb5eeb4358fdbcd42eac11c1fbd87e3affd7904e639d77903c1358b2abd3f70"}, "elixir_make": {:hex, :elixir_make, "0.6.3", "bc07d53221216838d79e03a8019d0839786703129599e9619f4ab74c8c096eac", [:mix], [], "hexpm", "f5cbd651c5678bcaabdbb7857658ee106b12509cd976c2c2fca99688e1daf716"}, "erlex": {:hex, :erlex, "0.2.6", "c7987d15e899c7a2f34f5420d2a2ea0d659682c06ac607572df55a43753aa12e", [:mix], [], "hexpm", "2ed2e25711feb44d52b17d2780eabf998452f6efda104877a3881c2f8c0c0c75"}, From ed80be01f5e4eb3a9347abbcc00af2a838feca4e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 22 Dec 2022 18:11:46 +0000 Subject: [PATCH 29/29] Bump @amplitude/analytics-browser in /apps/block_scout_web/assets Bumps [@amplitude/analytics-browser](https://github.com/amplitude/Amplitude-TypeScript) from 1.6.6 to 1.6.7. - [Release notes](https://github.com/amplitude/Amplitude-TypeScript/releases) - [Commits](https://github.com/amplitude/Amplitude-TypeScript/compare/@amplitude/analytics-browser@1.6.6...@amplitude/analytics-browser@1.6.7) --- updated-dependencies: - dependency-name: "@amplitude/analytics-browser" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- apps/block_scout_web/assets/package-lock.json | 62 +++++++++---------- apps/block_scout_web/assets/package.json | 2 +- 2 files changed, 32 insertions(+), 32 deletions(-) diff --git a/apps/block_scout_web/assets/package-lock.json b/apps/block_scout_web/assets/package-lock.json index 5b4abb383e..b727bd873d 100644 --- a/apps/block_scout_web/assets/package-lock.json +++ b/apps/block_scout_web/assets/package-lock.json @@ -7,7 +7,7 @@ "name": "blockscout", "license": "GPL-3.0", "dependencies": { - "@amplitude/analytics-browser": "^1.6.6", + "@amplitude/analytics-browser": "^1.6.7", "@fortawesome/fontawesome-free": "^6.2.1", "@tarekraafat/autocomplete.js": "^10.2.7", "@walletconnect/web3-provider": "^1.8.0", @@ -106,15 +106,15 @@ "version": "0.0.1" }, "node_modules/@amplitude/analytics-browser": { - "version": "1.6.6", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.6.tgz", - "integrity": "sha512-tR7JH5TPNt9h1PMOhnMP+aJdmty81ZaFg9UhIXHf86Crdac2GoYLXnzq3vMNK2Ad809jcGKssXJnVFkfXGxgIg==", + "version": "1.6.7", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.7.tgz", + "integrity": "sha512-XbiSH01hMpNrS7ymv5u5GB5Fwk1EO2EgWV3SZ0ck3ajKQZQg1/Q1p0TggrB79pSG047xYIdVQjoD0XzAtPdOug==", "dependencies": { - "@amplitude/analytics-client-common": "^0.5.0", - "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-client-common": "^0.5.1", + "@amplitude/analytics-core": "^0.11.1", "@amplitude/analytics-types": "^0.14.0", "@amplitude/ua-parser-js": "^0.7.31", - "tslib": "^2.3.1" + "tslib": "^2.4.1" } }, "node_modules/@amplitude/analytics-browser/node_modules/tslib": { @@ -123,14 +123,14 @@ "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==" }, "node_modules/@amplitude/analytics-client-common": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.5.0.tgz", - "integrity": "sha512-kqtv26b1bZoeGpQLaLqxW4E88S042++0mjpjCe/ekKbmk8pNlmq7nF3dfZZMDmtcAia7Z0YOxvZNgWoNPgiAUw==", + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.5.1.tgz", + "integrity": "sha512-RmIRJ1JG7Kre1bNY6x+mSp/LjnWNZngwL50zI9DsLuYw5fOmHCzJHn1Ntte+rQDlQ7dTr3jMg1zeP6+76CMw2Q==", "dependencies": { "@amplitude/analytics-connector": "^1.4.5", - "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-core": "^0.11.1", "@amplitude/analytics-types": "^0.14.0", - "tslib": "^2.3.1" + "tslib": "^2.4.1" } }, "node_modules/@amplitude/analytics-client-common/node_modules/tslib": { @@ -147,12 +147,12 @@ } }, "node_modules/@amplitude/analytics-core": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.11.0.tgz", - "integrity": "sha512-0X/3xMR/Ljl6JVgsIVALhKn9pBHxgyRgDqWIeRlwdingWIeWttQP8+TSpGI2S9xIeUdAdo0Urul/NMJGHFs07Q==", + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.11.1.tgz", + "integrity": "sha512-G+GgYFwxhD5DjYDKuC6jRcsO/kqJw4hLTlJ0x2mwppxVuMqQ44wRvdQ1hhzMRY02AGnmr0OR1xDtft8CabiIag==", "dependencies": { "@amplitude/analytics-types": "^0.14.0", - "tslib": "^2.3.1" + "tslib": "^2.4.1" } }, "node_modules/@amplitude/analytics-core/node_modules/tslib": { @@ -17022,15 +17022,15 @@ }, "dependencies": { "@amplitude/analytics-browser": { - "version": "1.6.6", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.6.tgz", - "integrity": "sha512-tR7JH5TPNt9h1PMOhnMP+aJdmty81ZaFg9UhIXHf86Crdac2GoYLXnzq3vMNK2Ad809jcGKssXJnVFkfXGxgIg==", + "version": "1.6.7", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-browser/-/analytics-browser-1.6.7.tgz", + "integrity": "sha512-XbiSH01hMpNrS7ymv5u5GB5Fwk1EO2EgWV3SZ0ck3ajKQZQg1/Q1p0TggrB79pSG047xYIdVQjoD0XzAtPdOug==", "requires": { - "@amplitude/analytics-client-common": "^0.5.0", - "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-client-common": "^0.5.1", + "@amplitude/analytics-core": "^0.11.1", "@amplitude/analytics-types": "^0.14.0", "@amplitude/ua-parser-js": "^0.7.31", - "tslib": "^2.3.1" + "tslib": "^2.4.1" }, "dependencies": { "tslib": { @@ -17041,14 +17041,14 @@ } }, "@amplitude/analytics-client-common": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.5.0.tgz", - "integrity": "sha512-kqtv26b1bZoeGpQLaLqxW4E88S042++0mjpjCe/ekKbmk8pNlmq7nF3dfZZMDmtcAia7Z0YOxvZNgWoNPgiAUw==", + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-client-common/-/analytics-client-common-0.5.1.tgz", + "integrity": "sha512-RmIRJ1JG7Kre1bNY6x+mSp/LjnWNZngwL50zI9DsLuYw5fOmHCzJHn1Ntte+rQDlQ7dTr3jMg1zeP6+76CMw2Q==", "requires": { "@amplitude/analytics-connector": "^1.4.5", - "@amplitude/analytics-core": "^0.11.0", + "@amplitude/analytics-core": "^0.11.1", "@amplitude/analytics-types": "^0.14.0", - "tslib": "^2.3.1" + "tslib": "^2.4.1" }, "dependencies": { "tslib": { @@ -17067,12 +17067,12 @@ } }, "@amplitude/analytics-core": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.11.0.tgz", - "integrity": "sha512-0X/3xMR/Ljl6JVgsIVALhKn9pBHxgyRgDqWIeRlwdingWIeWttQP8+TSpGI2S9xIeUdAdo0Urul/NMJGHFs07Q==", + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/@amplitude/analytics-core/-/analytics-core-0.11.1.tgz", + "integrity": "sha512-G+GgYFwxhD5DjYDKuC6jRcsO/kqJw4hLTlJ0x2mwppxVuMqQ44wRvdQ1hhzMRY02AGnmr0OR1xDtft8CabiIag==", "requires": { "@amplitude/analytics-types": "^0.14.0", - "tslib": "^2.3.1" + "tslib": "^2.4.1" }, "dependencies": { "tslib": { diff --git a/apps/block_scout_web/assets/package.json b/apps/block_scout_web/assets/package.json index bbdf9a40b9..f8acf36ce4 100644 --- a/apps/block_scout_web/assets/package.json +++ b/apps/block_scout_web/assets/package.json @@ -20,7 +20,7 @@ }, "dependencies": { "@fortawesome/fontawesome-free": "^6.2.1", - "@amplitude/analytics-browser": "^1.6.6", + "@amplitude/analytics-browser": "^1.6.7", "@tarekraafat/autocomplete.js": "^10.2.7", "@walletconnect/web3-provider": "^1.8.0", "assert": "^2.0.0",