@wireio/stake 2.7.1 → 2.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/stake.d.ts CHANGED
@@ -1869,6 +1869,9 @@ type LiqsolCore$1 = {
1869
1869
  },
1870
1870
  {
1871
1871
  "name": "tokenProgram";
1872
+ },
1873
+ {
1874
+ "name": "systemProgram";
1872
1875
  }
1873
1876
  ];
1874
1877
  "args": [];
@@ -3447,6 +3450,43 @@ type LiqsolCore$1 = {
3447
3450
  }
3448
3451
  ];
3449
3452
  },
3453
+ {
3454
+ "name": "migrateUserRecord";
3455
+ "discriminator": [
3456
+ 6,
3457
+ 118,
3458
+ 249,
3459
+ 178,
3460
+ 209,
3461
+ 106,
3462
+ 197,
3463
+ 25
3464
+ ];
3465
+ "accounts": [
3466
+ {
3467
+ "name": "admin";
3468
+ "writable": true;
3469
+ "signer": true;
3470
+ },
3471
+ {
3472
+ "name": "globalConfig";
3473
+ },
3474
+ {
3475
+ "name": "userAta";
3476
+ },
3477
+ {
3478
+ "name": "userRecord";
3479
+ "writable": true;
3480
+ },
3481
+ {
3482
+ "name": "distributionState";
3483
+ },
3484
+ {
3485
+ "name": "systemProgram";
3486
+ }
3487
+ ];
3488
+ "args": [];
3489
+ },
3450
3490
  {
3451
3491
  "name": "processGraveyardValidatorsBatch";
3452
3492
  "docs": [
@@ -5964,12 +6004,20 @@ type LiqsolCore$1 = {
5964
6004
  ];
5965
6005
  "type": "u8";
5966
6006
  },
6007
+ {
6008
+ "name": "aggregationStartedEpoch";
6009
+ "docs": [
6010
+ "The epoch when the current aggregation batch started.",
6011
+ "Prevents stale partial accumulators from being committed if an epoch boundary is crossed mid-aggregation."
6012
+ ];
6013
+ "type": "u64";
6014
+ },
5967
6015
  {
5968
6016
  "name": "reserved";
5969
6017
  "type": {
5970
6018
  "array": [
5971
6019
  "u8",
5972
- 31
6020
+ 23
5973
6021
  ];
5974
6022
  };
5975
6023
  }
@@ -7632,6 +7680,13 @@ type LiqsolCore$1 = {
7632
7680
  {
7633
7681
  "name": "bump";
7634
7682
  "type": "u8";
7683
+ },
7684
+ {
7685
+ "name": "trackedBalance";
7686
+ "docs": [
7687
+ "Last reconciled liqSOL token balance for this user ATA"
7688
+ ];
7689
+ "type": "u64";
7635
7690
  }
7636
7691
  ];
7637
7692
  };
package/lib/stake.js CHANGED
@@ -396,6 +396,9 @@ var instructions$7 = [
396
396
  },
397
397
  {
398
398
  name: "token_program"
399
+ },
400
+ {
401
+ name: "system_program"
399
402
  }
400
403
  ],
401
404
  args: [
@@ -1999,6 +2002,44 @@ var instructions$7 = [
1999
2002
  }
2000
2003
  ]
2001
2004
  },
2005
+ {
2006
+ name: "migrate_user_record",
2007
+ discriminator: [
2008
+ 6,
2009
+ 118,
2010
+ 249,
2011
+ 178,
2012
+ 209,
2013
+ 106,
2014
+ 197,
2015
+ 25
2016
+ ],
2017
+ accounts: [
2018
+ {
2019
+ name: "admin",
2020
+ writable: true,
2021
+ signer: true
2022
+ },
2023
+ {
2024
+ name: "global_config"
2025
+ },
2026
+ {
2027
+ name: "user_ata"
2028
+ },
2029
+ {
2030
+ name: "user_record",
2031
+ writable: true
2032
+ },
2033
+ {
2034
+ name: "distribution_state"
2035
+ },
2036
+ {
2037
+ name: "system_program"
2038
+ }
2039
+ ],
2040
+ args: [
2041
+ ]
2042
+ },
2002
2043
  {
2003
2044
  name: "process_graveyard_validators_batch",
2004
2045
  docs: [
@@ -4536,12 +4577,20 @@ var types$9 = [
4536
4577
  ],
4537
4578
  type: "u8"
4538
4579
  },
4580
+ {
4581
+ name: "aggregation_started_epoch",
4582
+ docs: [
4583
+ "The epoch when the current aggregation batch started.",
4584
+ "Prevents stale partial accumulators from being committed if an epoch boundary is crossed mid-aggregation."
4585
+ ],
4586
+ type: "u64"
4587
+ },
4539
4588
  {
4540
4589
  name: "_reserved",
4541
4590
  type: {
4542
4591
  array: [
4543
4592
  "u8",
4544
- 31
4593
+ 23
4545
4594
  ]
4546
4595
  }
4547
4596
  }
@@ -6204,6 +6253,13 @@ var types$9 = [
6204
6253
  {
6205
6254
  name: "bump",
6206
6255
  type: "u8"
6256
+ },
6257
+ {
6258
+ name: "tracked_balance",
6259
+ docs: [
6260
+ "Last reconciled liqSOL token balance for this user ATA"
6261
+ ],
6262
+ type: "u64"
6207
6263
  }
6208
6264
  ]
6209
6265
  }
@@ -7626,11 +7682,18 @@ var instructions$4 = [
7626
7682
  96
7627
7683
  ],
7628
7684
  accounts: [
7685
+ {
7686
+ name: "admin",
7687
+ signer: true
7688
+ },
7629
7689
  {
7630
7690
  name: "payer",
7631
7691
  writable: true,
7632
7692
  signer: true
7633
7693
  },
7694
+ {
7695
+ name: "global_config"
7696
+ },
7634
7697
  {
7635
7698
  name: "extra_account_meta_list",
7636
7699
  writable: true
@@ -7662,6 +7725,19 @@ var accounts$3 = [
7662
7725
  4,
7663
7726
  103
7664
7727
  ]
7728
+ },
7729
+ {
7730
+ name: "GlobalConfig",
7731
+ discriminator: [
7732
+ 149,
7733
+ 8,
7734
+ 156,
7735
+ 202,
7736
+ 160,
7737
+ 252,
7738
+ 176,
7739
+ 217
7740
+ ]
7665
7741
  }
7666
7742
  ];
7667
7743
  var errors$4 = [
@@ -7681,6 +7757,11 @@ var errors$4 = [
7681
7757
  code: 6003,
7682
7758
  name: "CannotTransferToBucket",
7683
7759
  msg: "Cannot transfer liqSOL directly to bucket - only protocol minting is allowed"
7760
+ },
7761
+ {
7762
+ code: 6004,
7763
+ name: "Unauthorized",
7764
+ msg: "Unauthorized: caller is not the admin"
7684
7765
  }
7685
7766
  ];
7686
7767
  var types$6 = [
@@ -7745,6 +7826,229 @@ var types$6 = [
7745
7826
  }
7746
7827
  ]
7747
7828
  }
7829
+ },
7830
+ {
7831
+ name: "GlobalConfig",
7832
+ docs: [
7833
+ "Zero-copy global config PDA"
7834
+ ],
7835
+ serialization: "bytemuckunsafe",
7836
+ repr: {
7837
+ kind: "c"
7838
+ },
7839
+ type: {
7840
+ kind: "struct",
7841
+ fields: [
7842
+ {
7843
+ name: "bump",
7844
+ type: "u8"
7845
+ },
7846
+ {
7847
+ name: "_padding",
7848
+ type: {
7849
+ array: [
7850
+ "u8",
7851
+ 7
7852
+ ]
7853
+ }
7854
+ },
7855
+ {
7856
+ name: "admin",
7857
+ type: "pubkey"
7858
+ },
7859
+ {
7860
+ name: "cranky",
7861
+ type: "pubkey"
7862
+ },
7863
+ {
7864
+ name: "_reserved_pubkey",
7865
+ type: {
7866
+ array: [
7867
+ "pubkey",
7868
+ 1
7869
+ ]
7870
+ }
7871
+ },
7872
+ {
7873
+ name: "min_user_deposit",
7874
+ docs: [
7875
+ "Minimum SOL amount a user can deposit"
7876
+ ],
7877
+ type: "u64"
7878
+ },
7879
+ {
7880
+ name: "min_unstake_request",
7881
+ docs: [
7882
+ "Minimum SOL amount for an unstake/withdrawal request"
7883
+ ],
7884
+ type: "u64"
7885
+ },
7886
+ {
7887
+ name: "min_rebalance_stake_delta",
7888
+ docs: [
7889
+ "Minimum stake delta to trigger a stake rebalance order"
7890
+ ],
7891
+ type: "u64"
7892
+ },
7893
+ {
7894
+ name: "min_rebalance_unstake_delta",
7895
+ docs: [
7896
+ "Minimum unstake delta to trigger an unstake rebalance order"
7897
+ ],
7898
+ type: "u64"
7899
+ },
7900
+ {
7901
+ name: "transient_threshold",
7902
+ docs: [
7903
+ "Minimum transient stake to include in effective stake calculations"
7904
+ ],
7905
+ type: "u64"
7906
+ },
7907
+ {
7908
+ name: "min_late_epoch_slot_gate",
7909
+ docs: [
7910
+ "Minimum slots that must have elapsed in the epoch before late epoch operations can execute"
7911
+ ],
7912
+ type: "u64"
7913
+ },
7914
+ {
7915
+ name: "_reserved_u64",
7916
+ type: {
7917
+ array: [
7918
+ "u64",
7919
+ 2
7920
+ ]
7921
+ }
7922
+ },
7923
+ {
7924
+ name: "cooldown_epochs",
7925
+ docs: [
7926
+ "Epochs a validator must wait in the graveyard before it is booted. This begins after the last recorded state change"
7927
+ ],
7928
+ type: "u16"
7929
+ },
7930
+ {
7931
+ name: "deposit_fee_multiplier",
7932
+ docs: [
7933
+ "Multiplier for deposit fee calculation, this would be average \"pay rate x number of epochs we expect the stake to warm up\""
7934
+ ],
7935
+ type: "u16"
7936
+ },
7937
+ {
7938
+ name: "min_vpp_entry",
7939
+ docs: [
7940
+ "Minimum VPP score required to enter the active validator set, this is a fall back for when the val set is really small"
7941
+ ],
7942
+ type: "u16"
7943
+ },
7944
+ {
7945
+ name: "min_vpp_exit",
7946
+ docs: [
7947
+ "VPP score threshold below which a validator is removed from active set, again a fall back"
7948
+ ],
7949
+ type: "u16"
7950
+ },
7951
+ {
7952
+ name: "tiny_network_threshold",
7953
+ docs: [
7954
+ "Max validators for \"tiny\" network band (uses fixed VPP thresholds) as above"
7955
+ ],
7956
+ type: "u16"
7957
+ },
7958
+ {
7959
+ name: "small_network_threshold",
7960
+ docs: [
7961
+ "Max validators for \"small\" network band (uses percentile-based selection)"
7962
+ ],
7963
+ type: "u16"
7964
+ },
7965
+ {
7966
+ name: "medium_network_threshold",
7967
+ docs: [
7968
+ "Max validators for \"medium\" network band (uses percentile-based selection)"
7969
+ ],
7970
+ type: "u16"
7971
+ },
7972
+ {
7973
+ name: "large_network_entry_rank",
7974
+ docs: [
7975
+ "Fixed rank threshold to enter active set in large networks (0-indexed)"
7976
+ ],
7977
+ type: "u16"
7978
+ },
7979
+ {
7980
+ name: "large_network_exit_rank",
7981
+ docs: [
7982
+ "Fixed rank threshold to exit active set in large networks (0-indexed)"
7983
+ ],
7984
+ type: "u16"
7985
+ },
7986
+ {
7987
+ name: "_reserved_u16",
7988
+ type: {
7989
+ array: [
7990
+ "u16",
7991
+ 3
7992
+ ]
7993
+ }
7994
+ },
7995
+ {
7996
+ name: "small_network_entry_percent",
7997
+ docs: [
7998
+ "Percentile rank required to enter active set in small networks"
7999
+ ],
8000
+ type: "u8"
8001
+ },
8002
+ {
8003
+ name: "small_network_exit_percent",
8004
+ docs: [
8005
+ "Percentile rank below which validators exit in small networks"
8006
+ ],
8007
+ type: "u8"
8008
+ },
8009
+ {
8010
+ name: "medium_network_entry_percent",
8011
+ docs: [
8012
+ "Percentile rank required to enter active set in medium networks"
8013
+ ],
8014
+ type: "u8"
8015
+ },
8016
+ {
8017
+ name: "medium_network_exit_percent",
8018
+ docs: [
8019
+ "Percentile rank below which validators exit in medium networks"
8020
+ ],
8021
+ type: "u8"
8022
+ },
8023
+ {
8024
+ name: "_reserved_u8",
8025
+ type: {
8026
+ array: [
8027
+ "u8",
8028
+ 2
8029
+ ]
8030
+ }
8031
+ },
8032
+ {
8033
+ name: "feature_flags",
8034
+ docs: [
8035
+ "Bit 0: DepositsEnabled, Bit 1: WithdrawalsEnabled, Bit 2: ClaimWithdrawalsEnabled,",
8036
+ "Bit 3: ProcessStakeOrdersEnabled, Bit 4: ProcessUnstakeOrdersEnabled,",
8037
+ "Bit 5: ProcessPayCycleEnabled, Bit 6: RebalancingEnabled, Bits 7-15: Reserved"
8038
+ ],
8039
+ type: "u16"
8040
+ },
8041
+ {
8042
+ name: "_reserved_flags",
8043
+ type: {
8044
+ array: [
8045
+ "u16",
8046
+ 1
8047
+ ]
8048
+ }
8049
+ }
8050
+ ]
8051
+ }
7748
8052
  }
7749
8053
  ];
7750
8054
  var mainnetTransferHookIDL = {