Loading external tox with different type destroys ref

When defining a reference to a COMP in my extension, this reference will break when loading a component with a different OP-Type.
After that, using the reference will result in a SystemError

SystemError: error return without exception set

As long as they stay the same OP-Type, the reference seems to stay valid.

Please find a minimum reproduction here: (Use the PulseParameter to load diferent styles of COMPs)
LoadingRefIssue.zip (5.2 KB)

Imho, the replace operator should be marked as invalid and throw the appropiate exception.

Best, Wieland

Hi @plusplusone

thanks for pointing this out.

Indeed, self.entrypoint still evaluates to a object that doesn’t exist anymore.
We are looking at it.

cheers
Markus

Hi @plusplusone

this behavior now raises a proper error:

Traceback (most recent call last):
  File "/project1/Loader/parexec1", line 12, in onPulse
  File "/project1/Loader/extLoader", line 15, in Load
td.tdError: Operator /project1/Loader/Entrypoint type has changed. Reference is invalid.

cheers
Markus