[Q] Package dependencies

stéphane ducasse ducasse at iam.unibe.ch
Wed Nov 3 20:05:58 UTC 2004


chris

I do not know if this is the solution but why not having a separate and 
empty package (called map after)

MagmaServer 23
	requires MagmaClient.24
	requires MaClient.17
	requires Ma Object Serialization 21

Then when you change

MagmaServer 24
	requires MagmaClient.24
	requires MaClient.17
	requires Ma Object Serialization 26

This way you always control a complete coherent pieces of working 
together packages
but you do not have the problems you encountered.

We will try to develop SmallWiki two this way and try to minimise 
hardcoding dependencies
inside the packages.

Note that ned at OOPSLA suggested to me not to have nested map because 
this way
you are sure that you do not get twice and child with different version 
in separated nested maps.

If you used this way of structuring your code I would appreciate that 
you let us know if this is working.

Stef


On 3 nov. 04, at 19:41, Chris Muller wrote:

> I am at a crossroads trying to determine whether I should keep 
> bothering with
> package-dependencies.
>
> Monticello supports dependencies by using "add required package" on 
> the menu.
> But I have run into an unexpected, but understandable behavior.  To 
> describe,
> consider my package hierarchy:
>
>   MagmaServer.23
>     requires MagmaClient.24
>       requires Ma Client Server.17
>         requires Ma Object Serialization.21
>
> Now I do some work on MagmaServer and Ma Object Serialization, and now 
> have
> MagmaServer.24 and Ma Object Serialization.26.  Note that Ma Client 
> Server did
> NOT change, it is still at version 17.
>
> Now I Save MagmaServer.24.  Even though expanding the hierarchy in the
> Monticello browser shows the most-recent, working-copy versions of all 
> my
> packages as the dependencies, Ma Client Server.17 is still referencing 
> Ma
> Object Serialization.21 instead of 26.
>
> I understand that Ma Client Server references its exact dependency 
> versions by
> UUID and, since it didn't change, didn't resave it just because one of 
> its
> dependencies evolved.
>
> Still, its confusing that the UI shows the version of the current 
> working copy
> when you expand the dependency tree, not the exact dependency version. 
>  Also,
> when I save a package that defines dependencies, Monticello 
> automatically saves
> versions of all *changed* dependencies; implying that the root-package 
> you are
> saving is being saved with its dependencies as a whole.  But wait, 
> those
> packages that didn't change are still pointing to older versions of 
> their
> dependent packages.
>
> I expect this is also why, after copying all my latest .mcz files into 
> a SAR
> that I sometimes still get "not found" errors when trying to load on 
> another
> computer; the referenced dependency is an old one and I only have the 
> newest
> ones in the SAR.
>
> This is painful, so I'm thinking of just ditching dependencies and 
> loading
> packages and building SAR's manually..  unless there are other 
> alternatives I'm
> not considering..
>
> Doesn't everyone have these challenges?  What is a best-practice?
>
> Thanks,
>   Chris
>




More information about the Squeak-dev mailing list