From 0753b6c42d242bffd94559f57bdcabab5cf124e1 Mon Sep 17 00:00:00 2001 From: Viktor Baranov Date: Wed, 23 Mar 2022 13:44:11 +0300 Subject: [PATCH] lose_consensus function: remove excessive select --- CHANGELOG.md | 1 + apps/explorer/lib/explorer/chain/import/runner/blocks.ex | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9f8e0db54f..addf114d8d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -275,6 +275,7 @@ - [#8529](https://github.com/blockscout/blockscout/pull/8529) - Move PolygonEdge-related migration to the corresponding ecto repository - [#8504](https://github.com/blockscout/blockscout/pull/8504) - Deploy new UI through Makefile - [#8501](https://github.com/blockscout/blockscout/pull/8501) - Conceal secondary ports in docker compose setup +- [#5322](https://github.com/blockscout/blockscout/pull/5322) - DB denormalization: block consensus and timestamp in transaction table
Dependencies version bumps diff --git a/apps/explorer/lib/explorer/chain/import/runner/blocks.ex b/apps/explorer/lib/explorer/chain/import/runner/blocks.ex index ffb8c47d5c..4ed9d436d9 100644 --- a/apps/explorer/lib/explorer/chain/import/runner/blocks.ex +++ b/apps/explorer/lib/explorer/chain/import/runner/blocks.ex @@ -401,8 +401,7 @@ defmodule Explorer.Chain.Import.Runner.Blocks do join: s in subquery(acquire_query), on: transaction.block_hash == s.hash, # we don't want to remove consensus from blocks that will be upserted - where: transaction.block_hash not in ^hashes, - select: transaction.block_hash + where: transaction.block_hash not in ^hashes ), [set: [block_consensus: false, updated_at: updated_at]], timeout: timeout