report_problem
is a function, since you used the def
keyword to define it. Functions don't have a method called .new()
.
If you defined your ReportProblem()
instance to a variable named report_problem
previously, then when you define the function report_problem
, the instance is shadowed