pcdshub / transfocate

Automated calculation of beryllium lens focusing optics
https://pcdshub.github.io/transfocate
Other
1 stars 7 forks source link

Lens object does not create proper device_tuple #24

Closed teddyrendahl closed 6 years ago

teddyrendahl commented 6 years ago

Copied from https://github.com/pcdshub/pcdsdevices/issues/157

Current Behavior

Currently when you create a Lens object and call .get() the command fails with an error message such as:

__new__() got an unexpected keyword argument 'your_signal'

On further investigation, the traceback reveals that this is raised while trying to create a self._device_tuple object. If you look at what this object actually is it looks like:

YourDeviceTuple(state, _1, _2, _3, _4)

I'm guessing the MRO of these class definitions does not produce a DeviceTuple that includes the signals attached by the child class. This causes an issue because when get tries to fill the tuple with component_names there are no spots in the tuple for all the components. It is worth noting that component_names contains all the signals, probably just not in time for the _device_tuple creation.

Your Environment

ophyd == v1.1.0

teddyrendahl commented 6 years ago

Cause by signal names with leading underscores. Chasing this down in ophyd.

teddyrendahl commented 6 years ago

Closed by https://github.com/NSLS-II/ophyd/pull/515

ZLLentz commented 6 years ago

closing issue that is already marked as closed by