Skip to content

Commit

Permalink
Update osc2_scenario_configuration.py (#1040)
Browse files Browse the repository at this point in the history
Add super.__init__() to class OSC2ScenarioConfiguration to prevent error "AttributeError: 'OSC2ScenarioConfiguration' object has no attribute 'route'" when running scenario_runner.py with --openscenario2 parameter

Co-authored-by: glopezdiest <[email protected]>
  • Loading branch information
Ylmdrin and glopezdiest committed May 3, 2024
1 parent 40b38fc commit 25db835
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions srunner/scenarioconfigs/osc2_scenario_configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ def flat_list(list_of_lists):

class OSC2ScenarioConfiguration(ScenarioConfiguration):
def __init__(self, filename, client):
super(OSC2ScenarioConfiguration, self).__init__()

self.name = self.filename = filename
self.ast_tree = OSC2Helper.gen_osc2_ast(self.filename)

Expand Down

0 comments on commit 25db835

Please sign in to comment.