Skip to content

Commit

Permalink
Fixes for 0.5.3
Browse files Browse the repository at this point in the history
  • Loading branch information
tilk committed Nov 19, 2024
1 parent 0809619 commit 5ca7161
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions coreblocks/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ def __init__(self, *, gen_params: GenParams):
def elaborate(self, platform):
m = TModule()

connect(m, flipped(self.wb_instr), self.wb_master_instr.wb_master)
connect(m, flipped(self.wb_data), self.wb_master_data.wb_master)
connect(m.top_module, flipped(self.wb_instr), self.wb_master_instr.wb_master)
connect(m.top_module, flipped(self.wb_data), self.wb_master_data.wb_master)

m.submodules.wb_master_instr = self.wb_master_instr
m.submodules.wb_master_data = self.wb_master_data
Expand Down
2 changes: 2 additions & 0 deletions test/transactron/testing/test_log.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ def test_error_log(self, caplog):
async def proc(sim: TestbenchContext):
await sim.tick()
sim.set(m.input, 1)
await sim.tick() # A log after the last tick is not handled

with pytest.raises(AssertionError):
with self.run_simulation(m) as sim:
Expand All @@ -112,6 +113,7 @@ def test_assertion(self, caplog):
async def proc(sim: TestbenchContext):
await sim.tick()
sim.set(m.input, 1)
await sim.tick() # A log after the last tick is not handled

with pytest.raises(AssertionError):
with self.run_simulation(m) as sim:
Expand Down
2 changes: 1 addition & 1 deletion transactron/testing/logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ async def log_process(sim: ProcessContext) -> None:
ticks = DependencyContext.get().get_dependency(TicksKey())

async for _, _, ticks_val, combined_trigger_val, *record_vals in (
sim.tick("sync_neg")
sim.tick()
.sample(ticks, combined_trigger)
.sample(*itertools.chain(*([record.trigger] + record.fields for record in records)))
):
Expand Down

0 comments on commit 5ca7161

Please sign in to comment.