The Inbox: System-dtl.1170.mcz

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

The Inbox: System-dtl.1170.mcz

commits-2
A new version of System was added to project The Inbox:
http://source.squeak.org/inbox/System-dtl.1170.mcz

==================== Summary ====================

Name: System-dtl.1170
Author: dtl
Time: 12 September 2020, 2:52:23.835083 pm
UUID: cdd6e922-e25e-433b-a516-c503d0a772a8
Ancestors: System-mt.1169

End of the #World as we know it. Package postscript only. About two years ago we eliminated all dependencies on global World. However, the global binding has remained functional on the theory that some external packages might still expect it.

It is time to get rid of the binding now because:
- It gives the false impressing that the World is still in use as a global
- If a package is loaded that does need World, then "Smalltalk at: #World put: Project current world" will restore prior behavior.

=============== Diff against System-mt.1169 ===============

Item was changed:
+ (PackageInfo named: 'System') postscript: '"Global World is functional but no longer used in the image. Remove it now. If any package is loaded that requires the obsolete global binding, the prior behavior may be restored with:
+
+ Smalltalk at: #World put: Project current world
+ "
+
+ Smalltalk globals unbind: #World.
+ '!
- (PackageInfo named: 'System') postscript: 'SystemNavigation initializeAuthors. "new: Tim Johnson (tcj)"'!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-dtl.1170.mcz

Chris Muller-3
LOL... that first sentence...  although as from the users'
perspective, the global is going away, so it might be better without
the hashtag... lol

On Sat, Sep 12, 2020 at 1:52 PM <[hidden email]> wrote:

>
> A new version of System was added to project The Inbox:
> http://source.squeak.org/inbox/System-dtl.1170.mcz
>
> ==================== Summary ====================
>
> Name: System-dtl.1170
> Author: dtl
> Time: 12 September 2020, 2:52:23.835083 pm
> UUID: cdd6e922-e25e-433b-a516-c503d0a772a8
> Ancestors: System-mt.1169
>
> End of the #World as we know it. Package postscript only. About two years ago we eliminated all dependencies on global World. However, the global binding has remained functional on the theory that some external packages might still expect it.
>
> It is time to get rid of the binding now because:
> - It gives the false impressing that the World is still in use as a global
> - If a package is loaded that does need World, then "Smalltalk at: #World put: Project current world" will restore prior behavior.
>
> =============== Diff against System-mt.1169 ===============
>
> Item was changed:
> + (PackageInfo named: 'System') postscript: '"Global World is functional but no longer used in the image. Remove it now. If any package is loaded that requires the obsolete global binding, the prior behavior may be restored with:
> +
> +       Smalltalk at: #World put: Project current world
> + "
> +
> + Smalltalk globals unbind: #World.
> + '!
> - (PackageInfo named: 'System') postscript: 'SystemNavigation initializeAuthors. "new: Tim Johnson (tcj)"'!
>
>

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-dtl.1170.mcz

David T. Lewis
Sorry I just couldn't resist :-)

On Sat, Sep 12, 2020 at 03:50:45PM -0500, Chris Muller wrote:

> LOL... that first sentence...  although as from the users'
> perspective, the global is going away, so it might be better without
> the hashtag... lol
>
> On Sat, Sep 12, 2020 at 1:52 PM <[hidden email]> wrote:
> >
> > A new version of System was added to project The Inbox:
> > http://source.squeak.org/inbox/System-dtl.1170.mcz
> >
> > ==================== Summary ====================
> >
> > Name: System-dtl.1170
> > Author: dtl
> > Time: 12 September 2020, 2:52:23.835083 pm
> > UUID: cdd6e922-e25e-433b-a516-c503d0a772a8
> > Ancestors: System-mt.1169
> >
> > End of the #World as we know it. Package postscript only. About two years ago we eliminated all dependencies on global World. However, the global binding has remained functional on the theory that some external packages might still expect it.
> >
> > It is time to get rid of the binding now because:
> > - It gives the false impressing that the World is still in use as a global
> > - If a package is loaded that does need World, then "Smalltalk at: #World put: Project current world" will restore prior behavior.
> >
> > =============== Diff against System-mt.1169 ===============
> >
> > Item was changed:
> > + (PackageInfo named: 'System') postscript: '"Global World is functional but no longer used in the image. Remove it now. If any package is loaded that requires the obsolete global binding, the prior behavior may be restored with:
> > +
> > +       Smalltalk at: #World put: Project current world
> > + "
> > +
> > + Smalltalk globals unbind: #World.
> > + '!
> > - (PackageInfo named: 'System') postscript: 'SystemNavigation initializeAuthors. "new: Tim Johnson (tcj)"'!
> >
> >
>

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-dtl.1170.mcz

Eliot Miranda-2


> On Sep 12, 2020, at 3:27 PM, David T. Lewis <[hidden email]> wrote:
>
> Sorry I just couldn't resist :-)
>
>> On Sat, Sep 12, 2020 at 03:50:45PM -0500, Chris Muller wrote:
>> LOL... that first sentence...  although as from the users'
>> perspective, the global is going away, so it might be better without
>> the hashtag... lol
>>
>>> On Sat, Sep 12, 2020 at 1:52 PM <[hidden email]> wrote:
>>>
>>> A new version of System was added to project The Inbox:
>>> http://source.squeak.org/inbox/System-dtl.1170.mcz
>>>
>>> ==================== Summary ====================
>>>
>>> Name: System-dtl.1170
>>> Author: dtl
>>> Time: 12 September 2020, 2:52:23.835083 pm
>>> UUID: cdd6e922-e25e-433b-a516-c503d0a772a8
>>> Ancestors: System-mt.1169
>>>
>>> End of the #World as we know it.

ROTFL <3

>>> Package postscript only. About two years ago we eliminated all dependencies on global World. However, the global binding has remained functional on the theory that some external packages might still expect it.
>>>
>>> It is time to get rid of the binding now because:
>>> - It gives the false impressing that the World is still in use as a global
>>> - If a package is loaded that does need World, then "Smalltalk at: #World put: Project current world" will restore prior behavior.
>>>
>>> =============== Diff against System-mt.1169 ===============
>>>
>>> Item was changed:
>>> + (PackageInfo named: 'System') postscript: '"Global World is functional but no longer used in the image. Remove it now. If any package is loaded that requires the obsolete global binding, the prior behavior may be restored with:
>>> +
>>> +       Smalltalk at: #World put: Project current world
>>> + "
>>> +
>>> + Smalltalk globals unbind: #World.
>>> + '!
>>> - (PackageInfo named: 'System') postscript: 'SystemNavigation initializeAuthors. "new: Tim Johnson (tcj)"'!
>>>
>>>
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-dtl.1170.mcz

K K Subbu
In reply to this post by commits-2
On 12/09/20 6:52 pm, [hidden email] wrote:
> End of the #World as we know it. Package postscript only. About two
> years ago we eliminated all dependencies on global World. However,
> the global binding has remained functional on the theory that some
> external packages might still expect it.
When an undefined global var is encountered, is it possible to detect it
as an obsolete reference and then offer an option to replace it with a
proper object accessor? Perhaps a 'Obsolete Globals' dictionary mapping
an obsolete global symbol to an object access?

Currently, we just throw up a 'Undefined Variable' dialog offering
closest symbols to correct a possible misspelling.

Regards .. Subbu

Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: System-dtl.1170.mcz

Christoph Thiede

Hi all,


I just took a short look at all references to the #World binding in my main image, and there are several packages that would probably break if we completely dropped this binding: AnimationsMagicMouseMorphic Testing Framework, RefactoringTools, PhenoSwaLintSignalsWidgetsWindowAcrobatics. And this enumeration does neither yet include my own projects nor all other valuable packages I do not know yet. Even the trunk itself still somehow depends on #World, see HandMorph >> #objectForDataStream: or DiskProxy >> #comeFullyUpOnReload:.

I would really wish we could find a solution to raise a DeprecationWarning if the binding is still accessed but still provide a fallback for it. Compiler support sounds interesting as well, but we should notice that existing images should still keep working without reinstalling/patching any package. Hypothetically, we could change the Compiler (*not* the Parser) to compile a deprecated literal binding from an extra list differently, so that the source code still will look the same, but the binding will actually point to a method call. Or would such a source code/bytecode discrepancy be too confusing for other components such as the decompiler?


Please note that this problem is not only applicable to the World global. Whenever we decide to deprecate a class, we could benefit from a solution that raises a DeprecationWarning when an attempt is made to access it as well.


Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von K K Subbu <[hidden email]>
Gesendet: Sonntag, 13. September 2020 13:38:10
An: [hidden email]
Betreff: Re: [squeak-dev] The Inbox: System-dtl.1170.mcz
 
On 12/09/20 6:52 pm, [hidden email] wrote:
> End of the #World as we know it. Package postscript only. About two
> years ago we eliminated all dependencies on global World. However,
> the global binding has remained functional on the theory that some
> external packages might still expect it.
When an undefined global var is encountered, is it possible to detect it
as an obsolete reference and then offer an option to replace it with a
proper object accessor? Perhaps a 'Obsolete Globals' dictionary mapping
an obsolete global symbol to an object access?

Currently, we just throw up a 'Undefined Variable' dialog offering
closest symbols to correct a possible misspelling.

Regards .. Subbu



Carpe Squeak!