Yes, there is a special method that starts when the MC package is downloaded: the initialize method!
To be more precise, it starts if the initialize method is different from the method that is already in the image. MC treats these class initializers on purpose (just like they treat on purpose when you use shifts instead of Monticello).
So in your example, everything is fine. Downloading the second version of initialize will execute it. (Edit: now that you have updated your example, so the initialization does not change on its own, you need to follow the recommendations in the next paragraph).
Be careful: if another version of the package has the same initialize class method, it will not be executed again. This is because Monticello, when downloading a package, takes into account only those methods that are different from what is in your image and what the download version offers. Therefore, if you want to enforce the initialize method, at least you need to give it a different timestamp.
source share