Returning error from a python-scripted Scenario

Keufran
Keufran Registered Posts: 12 ✭✭✭✭

Hello Dataiku-world,

I'm looking for a way to return a status (OK, ERROR) from a custom scripted scenario (Python, DSS 7.02)

I naivly tried the following:

scenario = Scenario()

scenario.outcome= "OK" (or "ERROR")

But this don't work. Even throwing an exception from my code is intercepted and the scenario appears to be executed correctly.

Best Answer

  • MarcH
    MarcH Dataiker Posts: 26 Dataiker
    edited July 17 Answer ✓

    Hello,

    Are you just trying to get the scenario to fail?

    How are you throwing the exception in your code? I was able to get a Python scenario to fail by simply raising an exception:

    raise Exception('failed run')

Answers

Setup Info
    Tags
      Help me…