Comment 2 for bug 1549999

Revision history for this message
Jose Idar (jose-idar) wrote :

Comment from related PR, copied here for clarity:

This IS actually being used by the ServerResponse model below, via the metaclass that defines it (inherited via KeyValuePrettyTableWithHeaders).
The implementation is kind of weird, but basically the class expects a variable named 'extensions' to exist within scope of the module (global), which it then uses to 'deserialize' all the extra attributes that may be present, beyond the base attributes listed in the model.
That list has to be inherited so that it can be auto-populated by the metaclass registration method.
A nice refactor would be to somehow get rid of the need for a globally scoped variable, but it does work as is.