StudioService does not fire PropertyChangedSignal for ActiveScript when switching back to viewport

When switching between open scripts in Studio, the property changed signal for ActiveScript under StudioService does not fire when it is changed to nil, i.e. when you tab back into the viewport.

You can reproduce this by running this code in the command bar and switching between open script tabs and the viewport. You will notice that nothing gets printed when you switch back to the viewport, not even if you explicitly close the currently open script.

The expected behavior is that this fires when this property is changed to nil.

game.StudioService:GetPropertyChangedSignal("ActiveScript"):Connect(function() 
    print(game.StudioService.ActiveScript)
end)

A side effect of this issue is my Color3 previewer plugin no longer automatically closing when you return to the viewport or close a script.

5 Likes

Thanks for the report! We’ve filed this internally and we’ll follow up here when we have an update for you.