Filecoin
An overview of using Filecoin with Tableland.
Filecoin is an EVM-compatible Layer 1 chain that Tableland currently supports. Check out the overview of what this network is and relevant information when using it.
Overview
The Filecoin EVM runtime (FEVM) is a fully compatible Ethereum Virtual Machine (EVM) implementation built on top of the Filecoin Virtual Machine (FVM). This compatibility enables Ethereum and Solidity developers to seamlessly deploy and run their smart contracts on the Filecoin network with minimal modifications. By supporting popular EVM development tools and offering the Ethereum JSON-RPC API, the FEVM simplifies the process of integrating existing blockchain applications into the Filecoin ecosystem, including Tableland.
Block & SQL finality
Filecoin block times are 30 seconds long. But, there are two components to SQL being materialized in Tableland:
- SQL event being emitted so that Tableland can process it.
- Awaiting block finality to prevent against chain reorgs.
The FVM generates receipts in the tipset following a transaction's submission to the mempool. Since Tableland needs the event / receipt in order to see any SQL that's written, this typically adds a ~1 minute delay after transaction submission—thus, 1 block (30 seconds) plus waiting for the following tipset's receipt (~1 minute) (see here for more detail). Additionally, Tableland waits 5 blocks for finality (~2.5 mins) until the SQL is materialized in Tableland. Finality in Filecoin is actually 900 epochs (~7.5 hours), but in practice, the 5 block finality is sufficient for Tableland.
From the time an onchain SQL transaction is submitted until it is materialized in the Tableland database network, it can take up to ~4 minutes.
Setup & resources
filecoin calibration (testnet)
- Chain ID:
314159
- Contract address:
0x030BCf3D50cad04c2e57391B12740982A9308621
- Network name:
filecoin-calibration
(used for Hardhat or ethersjs) - Tableland validator API:
https://testnets.tableland.network/api/v1
- RPC URLs: https://chainlist.org/chain/314159
- Block time: 30 seconds
- Block depth: 5
- SQL materialization time: 180-240 seconds
- Symbol: tFIL
- Faucet: https://faucet.calibnet.chainsafe-fil.io/funds.html
filecoin (mainnet)
- Chain ID:
314
- Contract address:
0x59EF8Bf2d6c102B4c42AEf9189e1a9F0ABfD652d
- Network name:
filecoin
(used for Hardhat or ethersjs) - Tableland validator API:
https://tableland.network/api/v1
- RPC URLs: https://chainlist.org/chain/314
- Block time: 30 seconds
- Block depth: 5
- SQL materialization time: 180-240 seconds
- Symbol: FIL
Currently, Filecoin Calibration node providers do not store an archive of chain history past the most recent 2000 blocks. This should not have an impact on development if you’re using the primary Tableland node, barring some unforeseen & unlikely downtime of ~17 hours. If you’re a node operator of the Tableland protocol, this does have an impact but will (hopefully) be resolved soon.
Getting testnet funds
Request testnet FIL from the faucet noted above—this should send funds directly to the identified wallet.