A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-February/060405.html below:

[Python-Dev] Path PEP and the division operator

[Python-Dev] Path PEP and the division operator [Python-Dev] Path PEP and the division operatorDuncan Booth duncan.booth at suttoncourtenay.org.uk
Sun Feb 5 11:10:08 CET 2006
Nick Coghlan <ncoghlan at gmail.com> wrote in
news:43E5543B.1080907 at gmail.com: 

> Duncan Booth wrote:
>> I'm not convinced by the rationale given why atime,ctime,mtime and
>> size are methods rather than properties but I do find this PEP much
>> more agreeable than the last time I looked at it.
> 
> A better rationale for doing it is that all of them may raise
> IOException. It's rude for properties to do that, so it's better to
> make them methods instead. 

Yes, that rationale sounds good to me.

> 
> That was a general guideline that came up the first time adding Path
> was proposed - if the functionality involved querying or manipulating
> the actual filesystem (and therefore potentially raising IOError),
> then it should be a method. If the operation related solely to the
> string representation, then it could be a property.

Perhaps Bjorn could add that to the PEP?
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4