The System Package

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

The System Package

Alexandre Bergel-4
Dear All,

It seems that the class category 'System' is registered as a package  
and each System-XXX category is both a package and a class category.
As a consequence, System is a package that contains sub-packages, and  
'System-Object Storage' is listed as a package.

I suggest that package name should never contain a  '-'. This require  
quite some discipline to not mess up the thing.

Cheers,
Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: The System Package

Lukas Renggli
> It seems that the class category 'System' is registered as a package
> and each System-XXX category is both a package and a class category.
> As a consequence, System is a package that contains sub-packages, and
> 'System-Object Storage' is listed as a package.

I don't have a package registered called 'System', however there are
some other packaging related problems in the latest Pharo. The classes
BlockClosuresTestCase, ClosureTests, CollectionCombinator, and
DecompilerTests are in no package.

I used the following script, that is part of code critics:

| packages |
packages := MCWorkingCopy allManagers
        collect: [ :each | each packageInfo ].
SystemNavigation default allClassesAndTraits
        do: [ :class |
                (packages count: [ :package | package includesSystemCategory: class
category ]) ~= 1
                        ifTrue: [ Transcript show: class name; show: ' ('; show: class
category; show: ')'; cr ]
                        ifFalse: [ [ :mclass |
                                mclass selectors do: [ :selector |
                                        (packages count: [ :package | package includesMethod: selector
ofClass: mclass ]) ~= 1
                                                ifTrue: [ Transcript show: mclass name; show: '>>'; show:
selector; cr ] ] ] value: class; value: class class ] ]
        displayingProgress: 'Checking Packages'

> I suggest that package name should never contain a  '-'. This require
> quite some discipline to not mess up the thing.

That does not solve the problem of overlapping packages. See
<http://code.google.com/p/seaside/wiki/PackageNaming> for a large
scale packaging scheme that works.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: The System Package

Stéphane Ducasse
Same here
        ScriptLoader new deletePackage: 'System' -> error no



On Apr 16, 2009, at 10:16 AM, Lukas Renggli wrote:

>> It seems that the class category 'System' is registered as a package
>> and each System-XXX category is both a package and a class category.
>> As a consequence, System is a package that contains sub-packages, and
>> 'System-Object Storage' is listed as a package.
>
> I don't have a package registered called 'System', however there are
> some other packaging related problems in the latest Pharo. The classes
> BlockClosuresTestCase, ClosureTests, CollectionCombinator, and
> DecompilerTests are in no package.

Ah this is another problem.
I will add an entry when the web site works again.

>
>
> I used the following script, that is part of code critics:
>
> | packages |
> packages := MCWorkingCopy allManagers
> collect: [ :each | each packageInfo ].
> SystemNavigation default allClassesAndTraits
> do: [ :class |
> (packages count: [ :package | package includesSystemCategory: class
> category ]) ~= 1
> ifTrue: [ Transcript show: class name; show: ' ('; show: class
> category; show: ')'; cr ]
> ifFalse: [ [ :mclass |
> mclass selectors do: [ :selector |
> (packages count: [ :package | package includesMethod: selector
> ofClass: mclass ]) ~= 1
> ifTrue: [ Transcript show: mclass name; show: '>>'; show:
> selector; cr ] ] ] value: class; value: class class ] ]
> displayingProgress: 'Checking Packages'
>
>> I suggest that package name should never contain a  '-'. This require
>> quite some discipline to not mess up the thing.
>
> That does not solve the problem of overlapping packages. See
> <http://code.google.com/p/seaside/wiki/PackageNaming> for a large
> scale packaging scheme that works.
>
> Lukas
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: The System Package

Stéphane Ducasse
In reply to this post by Lukas Renggli
Now in http://code.google.com/p/pharo/issues/detail?id=746

Stef


On Apr 16, 2009, at 10:16 AM, Lukas Renggli wrote:

> I don't have a package registered called 'System', however there are
> some other packaging related problems in the latest Pharo. The classes
> BlockClosuresTestCase, ClosureTests, CollectionCombinator, and
> DecompilerTests are in no package.
>
> I used the following script, that is part of code critics:
>
> | packages |
> packages := MCWorkingCopy allManagers
> collect: [ :each | each packageInfo ].
> SystemNavigation default allClassesAndTraits
> do: [ :class |
> (packages count: [ :package | package includesSystemCategory: class
> category ]) ~= 1
> ifTrue: [ Transcript show: class name; show: ' ('; show: class
> category; show: ')'; cr ]
> ifFalse: [ [ :mclass |
> mclass selectors do: [ :selector |
> (packages count: [ :package | package includesMethod: selector
> ofClass: mclass ]) ~= 1
> ifTrue: [ Transcript show: mclass name; show: '>>'; show:
> selector; cr ] ] ] value: class; value: class class ] ]
> displayingProgress: 'Checking Packages'


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: The System Package

Alexandre Bergel-4
In reply to this post by Lukas Renggli
> I don't have a package registered called 'System',

Strange, I do not know what went wrong. Sorry, we should have checked  
in a fresh image before.

> That does not solve the problem of overlapping packages. See
> <http://code.google.com/p/seaside/wiki/PackageNaming> for a large
> scale packaging scheme that works.

Why using - in package names where it is a special character for MC.  
Why not _ instead?
Just wondering. In Moose, we have Moose-All, Moose-OBBrowser, ..., but  
if one define a package Moose, then we are a kind of screwed.

Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project