<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from text --><style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<meta content="text/html; charset=UTF-8">
<style type="text/css" style="">
<!--
p
        {margin-top:0;
        margin-bottom:0}
-->
</style>
<div dir="ltr">
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Helvetica,sans-serif">
<p>Hi Martin,</p>
<p><br>
</p>
<p>not sure if this is related, but I changed the behavior of the dependency sorter in a recent Monticello version. Could you try out <span>Monticello-ct.717 from the Inbox and tell us whether the problem remains?</span></p>
<p><span><br>
</span></p>
<p><span>Best,</span></p>
<p><span>Christoph</span></p>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>Von:</b> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Martin Kuball <martinkuball@web.de><br>
<b>Gesendet:</b> Freitag, 8. Mai 2020 13:57:18<br>
<b>An:</b> The general-purpose Squeak developers list<br>
<b>Betreff:</b> Re: [squeak-dev] Monticello postscript problem</font>
<div> </div>
</div>
</div>
<font size="2"><span style="font-size:10pt;">
<div class="PlainText">Hi Marcel,<br>
<br>
Am Freitag, 8. Mai 2020, 09:17:41 CEST schrieb Marcel Taeumel:<br>
> Hi Martin,<br>
><br>
> I think that it would be better to first run all initializers and only then<br>
> the package postscripts. I thought this happens anyway. :-)<br>
><br>
> Can you point me to the source code you found?<br>
<br>
Sure.  Look at MCPackageLoader>>basicLoad. The problem is almost at the end<br>
with this lines:<br>
<br>
        additions do: [:ea | ea postloadOver: (self obsoletionFor: ea)]<br>
                displayingProgress: 'Initializing ', pkgName.<br>
<br>
The instance variable additions holds MCDefinition objects. Mostly for the<br>
classes but although the postscript. I replaced above lines with:<br>
<br>
        (additions select: [:ea | ea isScriptDefinition not]) do:<br>
                [:ea | ea postloadOver: (self obsoletionFor: ea)]<br>
                displayingProgress: 'Initializing classes ', pkgName.<br>
<br>
        (additions select: [:ea | ea isScriptDefinition]) do:<br>
                [:ea | ea postloadOver: (self obsoletionFor: ea)]<br>
                displayingProgress: 'executing postscript ', pkgName.<br>
<br>
But it would be much nicer to either have an extra variable for the postscript<br>
(assuming there could only be one) or make sure it always stays at the end of<br>
the list.<br>
<br>
><br>
> Best,<br>
> Marcel<br>
> Am 07.05.2020 21:50:28 schrieb Martin Kuball <martinkuball@web.de>:<br>
><br>
> Am Donnerstag, 7. Mai 2020, 21:45:50 CEST schrieb Martin Kuball:<br>
> > Hi all,<br>
> ><br>
> > I have a problem with a postscript in one of my Monticello packages. It<br>
> > fails to execute because a class used in the script did not had it's<br>
> > initialize method run, yet. I took a look under the hood and found, that<br>
> > the postscript and the initializer execs are all mixed together in one<br>
> > list. But the postscript was not at the end of this list.<br>
> ><br>
> > So is this a bug or is there for some reason no guarantee that the<br>
> > postscript is run when everything else is done? I fixed this for me by<br>
> > running twice over the list. First for the non-scripts and then for the<br>
> > scripts. Not very pretty but seems to do the job.<br>
> ><br>
> > Martin<br>
><br>
> I guess I should tell you that I'm using version 708 of monticello.<br>
<br>
<br>
<br>
<br>
<br>
</div>
</span></font>
</body>
</html>