Skip to content

Bunch of fixes

Jakub Ziebinski requested to merge jziebinski/fix-inheritance-in-operations into master

Reviewers: @kmochocki @jziebinski

Related:

Work done:

  • fixed inheritance order
  • cohesion: corrected order of typevars / unions, hive constants renames
  • created and exposed specializations instead of generic models of operations (still same should be done for the API models)

About the inheritance order:

All operations should have this order of inheritance:

class ExampleOperation(Operation, GenericModel, Generic[AssetTypes])

instead of the way it is now:

class ExampleOperation(Generic[AssetTypes], GenericModel, Operation). 

Creating operation models this way generates TypeError: Object of type '_GenericAlias' is not JSON serializable when creating an operation object like:

ExampleOperation[some specialization]()

instead of

ExampleOperation()
Edited by Mateusz Żebrak

Merge request reports

Loading