Skip to content

RustPython becomes silent if raising an error in trace() function #4906

@xiaxinmeng

Description

@xiaxinmeng

RustPython becomes silent if an error is raised in trace() function. The following example can normally print things on CPython while it fails on RustPython.

import sys
def trace(frame, event, arg):
    raise NameError
    return trace

sys.settrace(trace)
print("fail here")
try:
    a = 1/0
except:
    print("not allowed")

Output on RustPython --- silent

Output on CPython (Expected):
fail here
not allowed

Environment
Ubuntu 18.04
RustPython 0.2.0
CPython 3.11.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-vmArea: virtual machineC-bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions