8000 mpy-cross: Assertion failed when compiling tests/basics/exception_chain.py. · Issue #17547 · micropython/micropython · GitHub
[go: up one dir, main page]

Skip to content
mpy-cross: Assertion failed when compiling tests/basics/exception_chain.py. #17547
Open
@agatti

Description

@agatti

Port, board and/or hardware

Unix on Linux/amd64

MicroPython version

MicroPython v1.26.0-preview.261.gbcc8d4ee1.dirty on 2025-06-22; linux [GCC 15.1.1] version

Reproduction

  1. Build mpy-cross with no special flags (make -C mpy-cross clean && make -C mpy-cross)
  2. Compile tests/basics/exception_chain.py into native code (arch does not matter) with mpy-cross -X emit=native -march=debug tests/basics/exception_chain.py
  3. mpy-cross will crash.

Expected behaviour

Compiling tests/basics/exception_chain.py should not crash mpy-cross.

Observed behaviour

mpy-cross crashes with:

mpy-cross: ../py/emitnative.c:2947: emit_native_raise_varargs: Assertion `n_args == 1' failed.`

Additional Information

If having a multi-arg exception is not supported for native code compilation, then an error message should be printed rather than crashing the compiler.

Code of Conduct

Yes, I agree

528D

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0