m-labs / migen

A Python toolbox for building complex digital hardware
https://m-labs.hk/migen
Other
1.23k stars 210 forks source link

Python 3.12 namer issue #288

Closed sbourdeauducq closed 4 months ago

sbourdeauducq commented 4 months ago

Shows up in MiSoC tests

python3.12-misoc> ======================================================================
python3.12-misoc> ERROR: test_init (misoc.test.test_duc.TestMultiDDS.test_init)
python3.12-misoc> ----------------------------------------------------------------------
python3.12-misoc> Traceback (most recent call last):
python3.12-misoc>   File "/build/source/misoc/test/test_duc.py", line 243, in setUp
python3.12-misoc>     self.dut = duc.MultiDDS(n=5, fwidth=32, xwidth=16)
python3.12-misoc>                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/build/source/misoc/cores/duc.py", line 321, in __init__
python3.12-misoc>     i = Signal(n, reset=1)
python3.12-misoc>         ^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/nix/store/c912sb909f9bbhq7vqkjwajndga0mw10-python3.12-migen/lib/python3.12/site-packages/migen/fhdl/structure.py", line 395, in __init__
python3.12-misoc>     self.backtrace = _tracer.trace_back(name)
python3.12-misoc>                      ^^^^^^^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/nix/store/c912sb909f9bbhq7vqkjwajndga0mw10-python3.12-migen/lib/python3.12/site-packages/migen/fhdl/tracer.py", line 111, in trace_back
python3.12-misoc>     varname = get_var_name(frame)
python3.12-misoc>               ^^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/nix/store/c912sb909f9bbhq7vqkjwajndga0mw10-python3.12-migen/lib/python3.12/site-packages/migen/fhdl/tracer.py", line 64, in get_var_name
python3.12-misoc>     return code.co_cellvars[name_index]
python3.12-misoc>            ~~~~~~~~~~~~~~~~^^^^^^^^^^^^
python3.12-misoc> IndexError: tuple index out of range
python3.12-misoc> ======================================================================
python3.12-misoc> ERROR: test_seq (misoc.test.test_duc.TestMultiDDS.test_seq)
python3.12-misoc> ----------------------------------------------------------------------
python3.12-misoc> Traceback (most recent call last):
python3.12-misoc>   File "/build/source/misoc/test/test_duc.py", line 243, in setUp
python3.12-misoc>     self.dut = duc.MultiDDS(n=5, fwidth=32, xwidth=16)
python3.12-misoc>                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/build/source/misoc/cores/duc.py", line 321, in __init__
python3.12-misoc>     i = Signal(n, reset=1)
python3.12-misoc>         ^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/nix/store/c912sb909f9bbhq7vqkjwajndga0mw10-python3.12-migen/lib/python3.12/site-packages/migen/fhdl/structure.py", line 395, in __init__
python3.12-misoc>     self.backtrace = _tracer.trace_back(name)
python3.12-misoc>                      ^^^^^^^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/nix/store/c912sb909f9bbhq7vqkjwajndga0mw10-python3.12-migen/lib/python3.12/site-packages/migen/fhdl/tracer.py", line 111, in trace_back
python3.12-misoc>     varname = get_var_name(frame)
python3.12-misoc>               ^^^^^^^^^^^^^^^^^^^
python3.12-misoc>   File "/nix/store/c912sb909f9bbhq7vqkjwajndga0mw10-python3.12-migen/lib/python3.12/site-packages/migen/fhdl/tracer.py", line 64, in get_var_name
python3.12-misoc>     return code.co_cellvars[name_index]
python3.12-misoc>            ~~~~~~~~~~~~~~~~^^^^^^^^^^^^
python3.12-misoc> IndexError: tuple index out of range
python3.12-misoc> ----------------------------------------------------------------------