FAQs are divided into 2 sections. User FAQs cover questions that may come up when searching for transactions or interacting and verifying smart contracts. Developer FAQs cover questions related to installation, instance customization and hosting. If you have a question that isn't answered here, please contact us in our Discord and the team and community can help troubleshoot your issue.
What does the "in" or "out" label mean on a transaction?
This label appears next to a transaction to signify whether a transaction was sent or received by a particular address.
- In: A transaction was sent to the address
- Out: A transaction was initiated from the address
What are the different transaction types?
There are 3 transaction types which can be accessed from the tabs menu for an EOA (Externally Owned Address) or Smart Contract.
Transactions:
An EOA, commonly known as a wallet address, initiates a transaction. Both incoming and outgoing transactions are recorded here, and includes any transaction that requires a gas fee (in the native token ETH, xDai etc) for execution.
Token Transfers:
Transactions of ERC-20 or ERC-721 tokens. This can include DeFi transactions (like adding or removing liquidity), EOA transfers, airdrops or other transactions where non-native tokens are sent and received.
Internal Transactions:
Transactions initiated and executed between smart contracts. Internal transactions are the result of an external transaction (EOA to contract). This initial transaction can then trigger many internal transactions between contracts as functions are called.
What is CSV export error 504?
If you request too much data at the same time you may receive a timeout. Decreasing the period of time for an export (1 week timeframe is recommended for addresses with lots of transactions) can reduce these errors.
How can I access and read/write contract methods?
Yes! The contract should be verified (or the bytecode matches an existing contract) to enable reading and writing to contracts and proxy contracts. More info here.
How do I verify a smart contract?
There are multiple methods including options from the Blockscout UI as well as an integration directly with Hardhat.
Blockscout UI:
- Via flattened source code (Solidity)
- Via standard JSON input
- Via Sourcify: Sources and metadata JSON file
- Vyper contract
Hardhat:
How do I speed up my self-hosted instance?
BlockScout can be resource intensive. If your instance is running slowly:
- clear the cache - the application cache is cleared on restart by running:
sudo systemctl restart explorer.service
- increase the memory limit for indexers https://github.com/poanetwork/blockscout/blob/b48305ece284e00084e2bb47ff1ad501bf24f115/apps/indexer/config/config.exs#L36 8 if indexing is slow.
- increase the number of CPUs if CPU is running at 100% on the web app server
- increase the memory if memory consumption is high on the web app server
- increase the number of CPUs or/and increase the memory on the database server if consumption is high.
Instructions for accessing and upgrading CPUs/memory will differ based on your setup. If you are running BlockScout on AWS, these settings can be accessed through your AWS services portal.
How do I customize the coin symbol / name?
- Specify coin name for exchange rates fetcher with the
COIN
ENV variables
BlockScout utilizes the COIN
environment variable which pulls the associated market data from the Coinmarketcap.com API or CoinGecko API to provide pricing data throughout the application.
In order to set displayed coin symbol, instance maintainer should set COIN_NAME
runtime environment variable:
export COIN_NAME=
For instance, in case of POA instance of Blockscout:
export COIN_NAME=POA
How do I manage deployment with AWS CodeDeploy?
1) Visit CodeDeploy in AWS. You will see a list of your deployments. Select the deployment id to view details https://console.aws.amazon.com/codesuite/codedeploy/deployments?region=us-east-1
2) Deployment status consists of several steps. Once step 2 is complete (application is installed on replacement instances), you manually reroute traffic. Click the Reroute traffic
button to initiate.
3) Once traffic is rerouted, you’ll be asked to terminate the original instance. Click the Terminate button to initiate.
4) Once complete, use the public DNS address of the Amazon EC2 instance to view in a web browser. (To get the public DNS value, choose your Amazon EC2 instance in the Amazon EC2 console, and look for the value in Public DNS in the Description tab).
What's the best way to deploy to AWS?
Currently the best existing way is through docker compose https://github.com/blockscout/blockscout/tree/master/docker-compose.
We are currently working on deployment through Kubernetes (K8s) and other methods for easily spinning up an instance on AWS.
How do I replace missing assets/version numbers?
- Find the public ip of corresponding Blockscout instance in the EC2 -> Instances of AWS Dashboard.
- Connect to the host via SSH
ssh -i <host.pem> ec2-user@<public_ip>
, where<host.pem>
is host’s private key file,<public_ip>
is the public ip of the host, that can be found in the AWS dashboard. - Go to assets folder
cd /opt/app/apps/block_scout_web/priv/static
- Add missing assets there or to
./images
folder depending on what is missing. Refresh Blockscout instance page. For example, iffavicon.ico
is missing in./images
folder, just copy it from the root assets folder `cp favicon.ico ./images/. You should see now the missing assets.
The app version number should be in the footer of BlockScout instance
- Find the public ip of corresponding Blockscout instance in the EC2 -> Instances of AWS Dashboard
- Connect to the host via SSH
ssh -i <host.pem> ec2-user@<public_ip>
, where<host.pem>
is host’s private key file,<public_ip>
is the public ip of the host, that can be found in the AWS dashboard. - Go to layout folder
/opt/app/apps/block_scout_web/lib/block_scout_web/templates/layout
- Open
_footer.html.eex
footer template in the favorite text editor. For examplenano ./_footer.html.eex
and fix the line<% version = version() %>
(it is in the bottom of the file) with the hardcoded new version, for example,<% version = 'v1.3.3-beta' %>
and save. - Restart the Blockscout instance with
sudo systemctl restart explorer.service
How do I fix the Gettext.Error?
You may receive this error after making changes to a specific BlockScout application.
(Gettext.Error) translation with msgid '...<msg_here>...' has a non-empty msgstr
To update gettext, run the following command in the app’s folder where the changes were made.
- Go to the ./apps/{name_of_app} folder where the changes were made.
- Run
mix gettext.extract —merge
- Repeat for other app folders as required.
More information on Gettext is available here.
How do I update the UI?
See the Branding configs page for details related to different UI elements.
For updates like adding elements/links etc you will need to change .eex templates. When changing .eex templates you don't need to rebuild. Run the application in dev mode (MIX_ENV=dev), and change the template. You'll see changes on-the-fly. When chaging js/scss while running the application, you need to run mix phx.digest
to apply the changes.
How can I view smart contracts using RPC?
Use the JSON RPC listcontracts
endpoint. For example, to view verified contracts, use the following query. Pagination is available
curl -X GET "
https://blockscout.com/xdai/mainnet/api?module=contract&action=listcontracts&page=1&offset=50&filter=verified
" -H "accept: application/json"
Why are Market Cap/Token Price stats wrong?
One reason may be related to the CoinGecko API refusing Blockscout requests without an API key.
If impacted, apply this pull request to your instance:
It implements CoinGecko API key management and alternative CoinMarketCap exchange rates.
How do I disable exchange rates?
Change the Explorer.ExchangeRates variable from enabled: true
to enabled: false
- config :explorer, Explorer.ExchangeRates,
enabled: false
, store: :ets
How can I migrate verified contracts between databases?
You may want to do this if you are creating a new instance or resyncing a new node.
- Backup the
smart_contracts
table - Restore this table following the resync.
Which Linux distro do I use for manual deployment?
Ubuntu 18.04 has been configured in Blockscout CI.
Can I set RPC variable to a normal http(s) url?
Yes you can. The ethereum_json_rpc_http
variable can be set to any url, it does not need to be a localhost. Client variant env variable should be specified in either case.
Do I need to enable ws?
No, it is not required. If ws is disabled, leave the ETHEREUM_JSONRPC_WS_URL
env var empty or unset it.
How to fix error message "execution timeout at pushGasToTopCall
"?
Try increasing time for the ETHEREUM_JSONRPC_DEBUG_TRACE_TRANSACTION_TIMEOUT
ENV variable. The default is 5 sec.
How do I fix Unknown Private Network error?
In a self-hosted or locally deployed instance, when attempting to do a write transaction on a verified contract, the following errors may appear:
Unauthorized
"You connected to Unknown Private Network chain in the wallet, but the current instance of Blockscout is for Unknown Private Network chain"
"No "from" address specified in neither the give options, nor the default options."
- Check that you set the correct
CHAIN_ID
env variable - Check correct variable for
NETWORK_ID
- Check that Metamask (or other web3 wallets) is connected to correct network.
- Read more about this issue here.
How do I fix indexer timeouts or update memory to fix indexer memory errors?
- More on indexer timeouts
- More on updating memory consumption
How to incorporate "Add to MM" functionality
Check that you are running the latest version and set the following variables. These can be set at runtime.
CHAIN_ID=
NETWORK_PATH=
SUBNETWORK=
COIN_NAME=
JSON_RPC=
Gnosis Chain Example:
CHAIN_ID=100
NETWORK_PATH=/xdai/mainnet
SUBNETWORK=Gnosis Chain
COIN_NAME=xDai
JSON_RPC=https://rpc.gnosischain.com/
How do I update the internal tx fetcher to skip blocks or start from block to prevent errors?
Set TRACE_FIRST_BLOCK
and TRACE_LAST_BLOCK
env variables.
What is the command to install the smart contract verifier?
cargo install --git
https://github.com/blockscout/blockscout-rs smart-contract-verifier-http
Learn more about the contract verifier
How to fix error: "Could not compile dependency :libsecp256k1, "mix compile" failed.
This error can happen when running mix local.rebar --force
Try this command:
cd deps/libsecp256k1
make