Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-05-05 Thread Clemens Heuberger
[X] Phase out properties which perform any non-trivial computation, and officially condone the use of properties as "getters" of trivial private information. Best, Clemens -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-05-02 Thread Johan S . R . Nielsen
> Consistency is a definitive plus, as well as not impeding > introspection. So I would tend to agree to officially phase out > properties from the public API. > > There is one use case for properties in the public API though which I > would like to bring up, namely "glorified methods". > ...

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-05-02 Thread Erik Bray
On Mon, May 2, 2016 at 10:35 AM, Jeroen Demeyer wrote: > My vote: > >> [X] Phase out properties which perform any non-trivial computation > > > In certain cases, properties might be useful (but it could very well be that > there are 0 such cases in Sage). I generally feel

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-05-02 Thread Jeroen Demeyer
On 2016-04-29 10:38, Nicolas M. Thiery wrote: P.f(x) # use the morphism as a function P.f.rank() # play with the morphism itself cached method also does this. You can do P.f(x) to call the cached_method f but you also do stuff like

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-05-02 Thread Jeroen Demeyer
My vote: [X] Phase out properties which perform any non-trivial computation In certain cases, properties might be useful (but it could very well be that there are 0 such cases in Sage). -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-04-29 Thread Johan S . R . Nielsen
> Wouldn't you have to get rid of all public attributes as well when doing > this? > Or why should > sage: x.some_attribute > work and > sage: x.some_attribute_by_at_property > be forbidden? My impression is that public attributes generally are frowned upon, in Sage as in many other

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-04-29 Thread Nicolas M. Thiery
On Fri, Apr 29, 2016 at 09:31:31AM +0200, Johan S. R. Nielsen wrote: > I call for the following vote: > > [ ] Phase out all uses of properties in the public API and make them > into methods that take no arguments. Add in the developer's manual > somewhere that this is the general policy.

Re: [sage-devel] Deprecate the use of properties in all public API (was: Heavy-computation @property in Matrix class)

2016-04-29 Thread Daniel Krenn
On 2016-04-29 09:31, Johan S. R. Nielsen wrote: > [ ] Phase out all uses of properties in the public API and make them > into methods that take no arguments. Add in the developer's manual > somewhere that this is the general policy. Wouldn't you have to get rid of all public attributes as