Skip to content

Tests fail with cocotb v2.x #46

@Subhankar-hub

Description

@Subhankar-hub

Problem

The project doesn't work with cocotb v2.x due to API changes:

  • cocotb-config --prefix no longer exists (replaced with --lib-dir)
  • MODULE env var renamed to COCOTB_TEST_MODULES
  • PYGPI_PYTHON_BIN env var is now required
  • Clock() parameter units renamed to unit
  • LogicArray values can't be used directly in arithmetic operations (need explicit int() conversion)

Error Messages

cocotb-config: error: unrecognized arguments: --prefix
libcocotbvpi_icarus: Unable to find a 'libcocotbvpi_icarus.vpi' module on the search path.
PYGPI_PYTHON_BIN variable not set. Can't initialize Python interpreter!
TypeError: unsupported operand type(s) for *: 'LogicArray' and 'LogicArray'

Environment

  • cocotb v2.0.1
  • Python 3.13
  • Icarus Verilog 12.0

Fix

A fix has been submitted in PR #45

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions