bliss.get_axis() gives different, non-synchronised objects after config.reload(), called through ApplyConfig on SPEC reconfig
Hi,
We don't know if this is a bug or a feature, but we are facing the problem of multiple instances of the same 'axis', which are not at all synchronised between them.
The problem arrives when bliss.get_axis() is called in BlissAxisManager after a config.reload(), triggered by a SPEC reconfig:
>>> from bliss.config.static import get_config
>>> import gevent
>>> def position(mot):
... gevent.sleep(.1)
... return mot.position()
...
>>> config = get_config()
>>> sim_mu1 = config.get('sim_mu')
>>> print position(sim_mu1)
0.0
>>> sim_mu1b = config.get('sim_mu')
>>> print sim_mu1 is sim_mu1b
True
>>> config.reload()
>>> sim_mu2 = config.get('sim_mu')
>>> print sim_mu1 is sim_mu2
False
>>> print position(sim_mu1)
0.00140549496781
>>> print position(sim_mu2)
0.0
>>> sim_mu2.move(2)
>>> print position(sim_mu1)
0.00140549496781
>>> print position(sim_mu2)
2.00000002953
>>> config.reload()
>>> sim_mu3 = config.get('sim_mu')
>>> print position(sim_mu1)
1.76821988886
>>> print position(sim_mu2)
2.00000002953
>>> print position(sim_mu3)
0.0
Is this what we want as functionality?
Today this represents a problem in Tango BlissAxisManager, because dynamically created groups created from bliss.get_axis() hold instances of motor objects uncorrelated from the 'static' ones kept by the individual Tango axes.