Hi Andrew, Sorry for the late reply,
On Wed, Jul 11, 2018 at 4:31 PM Andrew P. Black <apbl...@pdx.edu> wrote: > Hi Guillermo, > > Thanks for the explanation. I guess that I really don't have much idea > how this baseline stuff is supposed to work, so when it fails, I don't know > where to look. > > My initial question was about why iceberg (or Metacello?) was looking in > the wrong directory, but that seems to have been the wrong question. > > So, you are right; the BaselineOfSmaCC has not been updated to include the > SmaCC-Reification package, which is new (and experimental). So it seems > that I have to add it. Here is the current baseline: > > BaselineOfSmaCC >> baseline: spec > <baseline> > spec > for: #common > do: [ spec blessing: #baseline. > spec > package: 'SmaCC-Source-Editing'; > package: 'SmaCC-Runtime'; > package: 'SmaCC-GLR-Runtime' > with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Debugging-Support' > with: [ spec requires: 'SmaCC-Development' ]. > spec > package: 'SmaCC-Development' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]. > spec > for: #Alt > do: [ spec > package: 'SmaCC-Alt' with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Development-UI' > with: [ spec > requires: #('SmaCC-Development' 'SmaCC-Alt' 'SmaCC-Debugging-Support') ] ]. > spec > for: #NoAlt > do: [ spec > package: 'SmaCC-Development-UI' > with: [ spec requires: #('SmaCC-Development' 'SmaCC-Debugging-Support') ] > ]. > spec > package: 'SmaCC-Tests' > with: [ spec requires: 'SmaCC-Development' ]; > package: 'SmaCC-Browser' with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Parse-Tree-Comparison' > with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Rewrite-Engine' > with: [ spec > requires: #('SmaCC-GLR-Runtime' 'SmaCC-Source-Editing' 'SmaCC-CSV-Parser') > ]; > package: 'SmaCC-Rewrite-Engine-Tests' > with: [ spec requires: 'SmaCC-Rewrite-Engine' ]; > package: 'SmaCC-Rewrite-Engine-Command-Line' > with: [ spec requires: 'SmaCC-Rewrite-Engine' ]; > package: 'SmaCC-Rewrite-Server'; > package: 'SmaCC-Rewrite-Server-Worker' > with: [ spec requires: 'SmaCC-Rewrite-Engine' ]; > package: 'SmaCC-Swift' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-Smalltalk-Parser' > with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Generic-Smalltalk-Parser' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-C-Parser' > with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-CSV-Parser' > with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-CSharp' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-Cucumber' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-Javascript-Parser' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-Java' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-Python' with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Python-Tests' > with: [ spec requires: 'SmaCC-Python' ]; > package: 'SmaCC-Line-Parser' > with: [ spec requires: 'SmaCC-Runtime' ]; > package: 'SmaCC-Delphi' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-DelphiForms' > with: [ spec requires: 'SmaCC-GLR-Runtime' ]; > package: 'SmaCC-IDL' with: [ spec requires: 'SmaCC-Runtime' ]. > spec > group: 'default' with: #('Tools'); > group: 'Runtime' with: #('SmaCC-GLR-Runtime'); > group: 'Rewrite' with: #('SmaCC-Rewrite-Engine'); > group: 'Rewrite-Server' > with: > #('SmaCC-Rewrite-Server-Worker' 'SmaCC-Rewrite-Server' 'Rewrite' > 'SmaCC-Rewrite-Engine-Command-Line'); > group: 'Tools' > with: > #('SmaCC-Development-UI' 'Examples' 'Rewrite' > 'SmaCC-Parse-Tree-Comparison'); > group: 'Debugging' with: #('SmaCC-Debugging-Support'); > group: 'Examples' > with: > #('SmaCC-Smalltalk-Parser' 'SmaCC-C-Parser' 'SmaCC-Java' > 'SmaCC-CSV-Parser' 'SmaCC-Line-Parser'); > group: 'Examples-Extra' > with: > #('SmaCC-IDL' 'SmaCC-CSharp' 'SmaCC-Cucumber' 'SmaCC-Swift' 'SmaCC-Delphi' > 'SmaCC-DelphiForms' 'SmaCC-Python' 'SmaCC-Javascript-Parser'); > group: 'Tests' > with: #('SmaCC-Tests' 'SmaCC-Rewrite-Engine-Tests' 'SmaCC-Python-Tests') ] > > > Should I add a new group, something like > > spec group: 'Reification' > > with: #('SmaCC-Reification') > > > But then I must also specify the dependencies of the SmaCC-Reification > package, so I need to add > > spec package: 'SmaCC-Reification' with: [ spec requires: > #('SmaCC-Smalltalk-Parser' 'SmaCC-Runtime' 'SmaCC-Java') ] > > > (I assumed that this would go earlier in the method, with the other > package specs. So I put it right after package: 'SmaCC-IDL') > Yep. You must do both :). Also, I think the order is not important, they are just declarations, the engine takes care of calculating the order later. > > Once I've done that, I tried to load the BaselineOfSmaCC again, and I find > that I've broken it. I get a walkback with the message > "Could not resolve: SmaCC-Reification [SmaCC-Reification] in > /Users/black/Development/Pharo/images/Pharo 7.0 SmallGrace > 0.34/pharo-local/package-cache g...@github.com:apblack/SmaCC.git[fglr]" > > Why is it trying to load SmaCC-Reficiation? Did my changes to the > baseline somehow change the default configuration too? > By default, if you don't specify anything, a baseline will load **all described packages**. If you want to override that behaviour, AFAIR you need to override the #default group spec group: 'default' with: #( .... ) Actually, I've cloned your project and see that default is defined as download tools. So, how are you loading your project. Moreover, I've just tried it and it worked, so there is something else to it: - I've cloned SmaCC - I've checked out the flgr branch - I've loaded the baseline and added spec package: 'SmaCC-Reification' with: [ spec requires: #('SmaCC-Smalltalk-Parser' 'SmaCC-Runtime' 'SmaCC-Java') ] - then, I've done right click on the iceberg project and selected Metacello -> load baseline... => then inserted SmaCC-Reification and I got that package + dependencies loaded... > Moreover, my original problem is still there — it's looking in a > nonexistent package cache, rather than on github, or in my > ~/iceberg/apblack/SmaCC clone of github. > I don't think this is quite like that... Metacello will try to lookup the package in several places. And it will check at last the package cache. So it fails because it was not able to found that package in any of your repositories, but the last it checked was the package cache. > - If SmaCC-Reification is in a non-default group, you probably want to add > > spec > baseline: 'SmaCC-Reification' > with: [ spec repository: 'github://apblack/SmaCC:working'; loads: #( > 'NAME-OF-YOUR-REIFICATION-GROUP' ) ]. > > > This would go in the BaselineOfGrace package, right? Not in > BaselineOfSmaCC > yep. > > And then your packages can depend on it. > > - IF SmaCC-Reification is not in the SmaCC baseline, then, there is > nothing you can do, but to add it :) > > > Thanks for the help so far > > Andrew > > -- Guille Polito Research Engineer Centre de Recherche en Informatique, Signal et Automatique de Lille CRIStAL - UMR 9189 French National Center for Scientific Research - *http://www.cnrs.fr <http://www.cnrs.fr>* *Web:* *http://guillep.github.io* <http://guillep.github.io> *Phone: *+33 06 52 70 66 13