Skip to content

Conversation

@alex-sumner
Copy link

Fixes #240

Summary

When programs are deployed via BPF Loader Upgradeable, only the ProgramData account gets written to the ExecutionRecord, not the Program account. This causes subsequent transactions to fail.

Changes

  • Set executable flag for Program accounts in sync_accounts()
  • Add load_all_existing_programs() to scan and load uncached programs
  • Auto-load programs during transaction execution if missing from cache
  • Sync BPF loader accounts even when not writable in execute_tx_helper()
  • Add load_existing_programs() public API
  • Add tests

Test Plan

  • cargo test --package litesvm --test bpf_upgradeable_autoload (4 tests pass)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BPF Loader Upgradeable programs not automatically loaded after deployment

1 participant