I have similar experience. I understand that if we switch themes, widgets come to sidebars according to the theme’s settings. But in my case, my two themes are identical but with different names. In this case, should all widgets go missing too? Knowing the fact that if theme’s registered sidebar numbers are different, then only widgets go inactive. Please help me in this. If there is some code which can solve this, would be highly helpful for me.