Skip to content

Conversation

@redpanda-f
Copy link

This PR adds comprehensive support for local Filecoin networks to enable easier development and testing.

Changes

  • Add localnet support to Synapse SDK for local Filecoin network development
  • Introduce localnet configuration utilities with environment variable support for chain ID, RPC URLs, and contract addresses
  • Update FilecoinNetworkType to include 'localnet' alongside mainnet and calibration
  • Enhance network detection to automatically recognize localnet by chain ID
  • Add localnet contract address resolution with required/optional address validation
  • Update example scripts (storage-e2e, post-deploy-setup) to support --network localnet option
  • Export localnet configuration from synapse-core and synapse-sdk packages
  • Maintain backward compatibility with existing mainnet/calibration functionality

Environment Variables

The following environment variables can be used to configure localnet:

  • LOCALNET_CHAIN_ID (default: 1414)
  • LOCALNET_RPC_URL (default: http://127.0.0.1:5700/rpc/v1)
  • LOCALNET_RPC_WS_URL (default: ws://127.0.0.1:5700/rpc/v1)
  • LOCALNET_BLOCK_EXPLORER_URL (default: http://localhost:8080)
  • LOCALNET_MULTICALL3_ADDRESS,
  • LOCALNET_USDFC_ADDRESS, etc. for contract addresses

@github-project-automation github-project-automation bot moved this to 📌 Triage in FS Jan 2, 2026
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 2, 2026

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
❌ Deployment failed
View logs
synapse-dev 5c094bc Jan 12 2026, 04:07 PM

@redpanda-f redpanda-f changed the title feat: Add Localnet Support to Synapse SDK feat: (foc-localnet-v1-rc) Add Localnet Support to Synapse SDK Jan 2, 2026
@BigLep
Copy link
Contributor

BigLep commented Jan 5, 2026

@redpanda-f : will you take care of the lint failures?

@BigLep BigLep moved this from 📌 Triage to 🔎 Awaiting review in FS Jan 5, 2026
@rvagg rvagg force-pushed the feat/redpanda/localnet-support branch from 4431d7c to ebfd645 Compare January 6, 2026 05:21
* ```
*/

export {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this was a mistake? we recently removed a bunch of stuff from here, are they needed for this PR?

PDP_PERMISSION_NAMES,
} from '../packages/synapse-sdk/src/session/index.ts'

// Parse command line arguments
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's not do this, it already uses env vars and we can stick to that, I don't really want to overcomplicate it for now and keep it ~clean, let's just extend the env var use to add in the devnet variables

let WARM_STORAGE_ADDRESS = process.env.WARM_STORAGE_ADDRESS

// Set defaults based on network if not provided
if (!RPC_URL) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as above, I don't think this is required, make the caller specify RPC_URL

@rjan90 rjan90 added this to the M4: Filecoin Service Liftoff milestone Jan 8, 2026
@BigLep BigLep moved this from 🔎 Awaiting review to ⌨️ In Progress in FS Jan 8, 2026
@redpanda-f redpanda-f force-pushed the feat/redpanda/localnet-support branch from ebfd645 to 5c094bc Compare January 12, 2026 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: ⌨️ In Progress

Development

Successfully merging this pull request may close these issues.

5 participants