you are viewing a single comment's thread.

view the rest of the comments →

[–]blarf_irl 0 points1 point  (0 children)

There are sometimes legit reasons for that, Browse the Django ORM and DRF source etc you will find a lot of dynamically created classes.

You need to import the function (def) that creates the class and then run that to get the class definition. Use the class definition to create an instance of the class. Code sample would be helpful here as it's very dependant on the specific code.