Documentation

Troubleshooting

Common issues and solutions when running Cylend

Ponder Indexer Issues

Indexer won't start

Symptoms: Error on startup, can't connect to RPC

Solutions:

  • • Check RPC URLs in .env are correct and accessible
  • • Test RPC with: curl https://rpc.sepolia.mantle.xyz
  • • Ensure contract addresses match deployed contracts
  • • Try deleting .ponder/ folder and restarting

Indexer not syncing new events

Symptoms: Old data showing, new deposits not appearing

Solutions:

  • • Check if RPC has rate limiting issues
  • • Verify start block in ponder.config.ts
  • • Run npm run db migrate to reset database
  • • Use dedicated RPC endpoints for production

GraphQL errors

Symptoms: Queries fail, schema errors

Solutions:

  • • Run npm run codegen to regenerate types
  • • Check ponder.schema.ts for syntax errors
  • • Verify indexer is running on port 42069

Frontend Issues

Can't connect to Ponder API

Symptoms: "Failed to fetch" errors, empty data

Solutions:

  • • Ensure Ponder is running before starting frontend
  • • Check NEXT_PUBLIC_PONDER_API_URL is correct
  • • Look for CORS errors in browser console
  • • Verify Ponder GraphQL at localhost:42069/graphql

Wallet connection fails

Symptoms: Wallet won't connect, RainbowKit errors

Solutions:

  • • Get a WalletConnect Project ID from WalletConnect Cloud
  • • Set NEXT_PUBLIC_WALLETCONNECT_PROJECT_ID
  • • Ensure wallet is connected to Mantle Sepolia
  • • Try a different wallet (MetaMask, Rainbow, etc.)

Transaction fails

Symptoms: Deposit or action transaction reverts

Solutions:

  • • Check you have enough MNT for gas
  • • Verify contract addresses are correct
  • • For ERC20 deposits, ensure token approval first
  • • Check explorer for detailed error message

Backend Service Issues

Actions stuck in "Pending"

Symptoms: Actions never process, no backend logs

Solutions:

  • • Verify backend service is running
  • • Check OWNER_PRIVATE_KEY is correct deployer address
  • • Ensure owner wallet has ROSE for Sapphire gas
  • • Check service logs for error messages

processAction() fails

Symptoms: Service logs show transaction errors

Solutions:

  • • Verify CORE_ADDRESS is correct LendingCore address
  • • Check Sapphire RPC is accessible
  • • Ensure prices aren't stale (oracle may need update)
  • • Check health factor for borrow/withdraw actions

Service can't find pending actions

Symptoms: "No pending actions" but actions exist

Solutions:

  • • Check PONDER_API_URL points to running Ponder
  • • Verify Ponder has indexed the action events
  • • Check GraphQL query in service code

Common Error Messages

Error: insufficient funds for gas

Get testnet tokens from faucets. You need MNT for Mantle and ROSE for Sapphire.

Error: execution reverted: Ownable: caller is not the owner

The OWNER_PRIVATE_KEY doesn't have permission. Use the deployer's private key.

Error: health factor too low

Borrow or withdraw would make health factor fall below 1.0. Reduce the amount or add collateral.

Error: deposit not found or already released

The deposit was already fully consumed or doesn't belong to your address.

Error: CORS policy blocked

Frontend and Ponder are on different ports. Ponder should handle CORS automatically in dev mode.

Getting Help

Tip

When reporting issues, include: error messages, terminal logs, browser console output, and steps to reproduce.

Related Guides