class DirectionalDerivative will not pickle field 'dim'
The init_arg_names in DirectionalDerivative (relevant code) does not contain field dim, which is added to the object in ancestor class Kernel.
I believe for now we could get around this by just adding dim to init_arg_names, but I suggest in the long run we should, across pytential and sumpy,
- get rid of
__getinitargs__all together, because it is not used in new-style classes for both Python 2 and Python 3. - either call
__init__in__setstate__, or modifyinit_arg_namesto includes all fields instead of just initialization arguments.
See a related issue in Pytential pytential#110 (closed).
Edited by Hao Gao