Skip to content

Commit a1bd54f

Browse files
committed
fix: add instruction ids
1 parent 52166be commit a1bd54f

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

program_admin/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,8 @@ async def sync(
327327
publisher_program_signers,
328328
) = await self.sync_publisher_program(ref_publishers)
329329

330+
logger.debug(f"Syncing publisher program - {len(publisher_program_instructions)} instructions")
331+
330332
if publisher_program_instructions:
331333
instructions.extend(publisher_program_instructions)
332334
if send_transactions:

program_admin/publisher_program_instructions.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,14 @@ def initialize_publisher_program(
4444
)
4545

4646
ix_data_layout = Struct(
47+
"instruction_id" / Int8ul,
4748
"bump" / Int8ul,
4849
"authority" / Bytes(32),
4950
)
5051

5152
ix_data = ix_data_layout.build(
5253
dict(
54+
instruction_id=0,
5355
bump=bump,
5456
authority=bytes(authority),
5557
)
@@ -132,13 +134,15 @@ def initialize_publisher_config(
132134
)
133135

134136
ix_data_layout = Struct(
137+
"instruction_id" / Int8ul,
135138
"config_bump" / Int8ul,
136139
"publisher_config_bump" / Int8ul,
137140
"publisher" / Bytes(32),
138141
)
139142

140143
ix_data = ix_data_layout.build(
141144
dict(
145+
instruction_id=2,
142146
config_bump=config_bump,
143147
publisher_config_bump=publisher_config_bump,
144148
publisher=bytes(publisher_key),

0 commit comments

Comments
 (0)