оба все потерляи что было, щас код import base58
import base64
import requests

from solders.keypair import Keypair
from solders.pubkey import Pubkey
from solders.instruction import Instruction, AccountMeta
from solders.message import MessageV0
from solders.hash import Hash
from solders.transaction import VersionedTransaction
from solders.signature import Signature
from solders.address_lookup_table_account import AddressLookupTableAccount

# 1. Приватник
privkey = base58.b58decode("tmeDHdFydjFM4GptgNwgFVRgFgjnJZwof37WHrFq6quwJWUURkJngzXrZtrKeVemw8kgDhkuy7o9VWWXWH1i2bY")
keypair = Keypair.from_bytes(privkey)
payer = keypair.pubkey()

# 2. Получаем актуальный blockhash
from solana.rpc.api import Client
client = Client("https://api.mainnet-beta.solana.com")
blockhash = client.get_latest_blockhash().value.blockhash

# 3. accountKeys (8 адресов)
account_keys = [
    "5tkBUejYPqrKVJVKrRK1AYv8wv5fQUebuiJUxCJQuBzm",  # 0
    "Bnt78xuR94TsKdCBeMDn6UsswVoKNAg8gztaxN3ZqvuB",  # 1
    "9LHqWDSuXCCEkZasVeN5BhF8ynyHTXtFoMTfGmXUo2Nh",  # 2
    "4sbctz5tPVysDuJhoVHui7BMcLsqhN7As47EGnhqM7sh",  # 3
    "ADuUkR4vqLUMWXxW9gh6D6L8pMSawimctcNZ5pGwDcEt",  # 4
    "ComputeBudget111111111111111111111111111111",    # 5
    "F9SixdqdmEBP5kprp2gZPZNeMmfHJRCTMFjN22dx3akf",   # 6
    "11111111111111111111111111111111",               # 7
]

# 4. Address Table
writable_table = [
    "8LJfcPpkwvYdWdyd85TtKFvjGEU8tC12jWYBDcVgjdwi",   # 8
    "4LN5Bbx56RHrsevEMnu3ah8bCU25D7XAzjX1ukhT1iCQ",   # 9
    "33nQCgievSd3jJLSWFBefH3BJRN7h6sAoS82VFFdJGF5",   # 10
    "FVDwxopybdSGWSgmpMQj5tsCBrQFzRY9pUTWXCTqhxnM",   # 11
]
readonly_table = [
    "Sysvar1nstructions1111111111111111111111111",    # 12
    "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA",    # 13
    "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb",    # 14
    "metaqbxxUerdq28cj1RbAWkYQm3ybzjb6a8bt518x1s",    # 15
    "cmtDvXumGCrqC1Age74AVPhSRVXJMd8PJS91L8KbNCK",    # 16
    "noopb9bkMVfRPU8AsbpTUg8AQkHtKwMYZiFUjNRtMmV",    # 17
    "SysvarS1otHashes111111111111111111111111111",    # 18
    "BGUMAp9Gq7iTEuizy4pqaxsTyUCBK68MDfK752saRPUY",   # 19
    "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",   # 20
    "CoREENxT6tW1HoK8ypY1SxRMZTcVPm7R94rH4PZNhX7d",   # 21
]

# 5. Получаем AddressLookupTableAccount через solana-py
lookup_table_address = "4A8bRNVgfk6Z76R5rTFWeJAXtKLi8NMoTGz17VedEpAq"
lookup_table_pubkey = Pubkey.from_string(lookup_table_address)
lookup_table_resp = client.get_account_info(lookup_table_pubkey, encoding="base64")

if lookup_table_resp.value is None:
    raise Exception("Address Lookup Table account не найден! Проверь адрес таблицы.")

lookup_table_account_info = lookup_table_resp.value.data[0]
if not isinstance(lookup_table_account_info, str):
    raise Exception("Address Lookup Table account не инициализирован или пустой!")

lookup_table_account_bytes = base64.b64decode(lookup_table_account_info)
lookup_table_account = AddressLookupTableAccount.deserialize(lookup_table_account_bytes)

# 6. Инструкции
ix1 = Instruction(
    program_id=Pubkey.from_string(account_keys[5]),
    accounts=[],
    data=base58.b58decode("3QGMXYP8FsXD")
)
ix2 = Instruction(
    program_id=Pubkey.from_string(account_keys[5]),
    accounts=[],
    data=base58.b58decode("HzQDd1")
)
ix3_accounts_idx = [
    0, 0, 8, 2, 9, 10, 7, 6, 6, 6, 6, 6, 12, 13, 14, 15, 16, 17, 18, 19, 6, 6, 20, 21, 11, 1, 14, 9, 9, 3
]
all_keys = account_keys + writable_table + readonly_table
ix3_accounts = [
    AccountMeta(Pubkey.from_string(all_keys[i]), is_signer=(i == 0), is_writable=True) for i in ix3_accounts_idx
]
ix3 = Instruction(
    program_id=Pubkey.from_string(account_keys[6]),
    accounts=ix3_accounts,
    data=base58.b58decode("Rm3k6WZqNkGjUohNmVmVK25QvjBG37aMuFW4F")
)
ix4_accounts_idx = [0, 4]
ix4_accounts = [
    AccountMeta(Pubkey.from_string(account_keys[i]), is_signer=(i == 0), is_writable=True) for i in ix4_accounts_idx
]
ix4 = Instruction(
    program_id=Pubkey.from_string(account_keys[7]),
    accounts=ix4_accounts,
    data=base58.b58decode("3Bxs4ThwQbE4vyj5")
)

# 7. Собираем message и транзакцию (с address lookup table!)
message = MessageV0.try_compile(
    payer,
    [ix1, ix2, ix3, ix4],
    [lookup_table_account],
    blockhash
)

sig1 = keypair.sign_message(bytes(message))
sig2 = Signature.default()  # пустая подпись для mint-адреса

tx = VersionedTransaction.populate(message, [sig1, sig2])

raw_tx = bytes(tx)
b64_tx = base64.b64encode(raw_tx).decode("utf-8")

json_data = {
    "id": 1,
    "jsonrpc": "2.0",
    "method": "sendTransaction",
    "params": [
        b64_tx,
        {"encoding": "base64"},
    ],
}

headers = {
    "accept": "*/*",
    "content-type": "application/json",
    "user-agent": "Mozilla/5.0",
}

url = "https://rpc.ironforge.network/mainnet?apiKey=01HTWR63WZ6CYWWKH9RRE1PYYZ"

response = requests.post(
    url,
    headers=headers,
    json=json_data,
)
print(response.json())

Но Traceback (most recent call last):
  File "D:\CryptoProject\StickerManager\solanatest.py", line 66, in <module>
    raise Exception("Address Lookup Table account не инициализирован или пустой!")
Exception: Address Lookup Table account не инициализирован или пустой!