Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the DateTime-Locale CPAN distribution.

Report information
The Basics
Id: 62448
Status: resolved
Priority: 0/
Queue: DateTime-Locale

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in:
  • 0.44
  • 0.45
Fixed in: (no value)



Subject: More documentation for deprecated methods
Since 0.44 it seems that a number of DateTime::Locale methods are deprecated. The Changes file lists them, and suggests to replace them, but I cannot find any hint what are the new method names to use. Eventually I found the %subs mapping in the DateTime/Locale/Base.pm source. That said, why not keep the deprecated methods forever in this mapping, without any warnings? Regards, Slaven
Subject: Re: [rt.cpan.org #62448] More documentation for deprecated methods
Date: Mon, 25 Oct 2010 15:28:11 -0500 (CDT)
To: Slaven_Rezic via RT <bug-DateTime-Locale [...] rt.cpan.org>
From: Dave Rolsky <autarch [...] urth.org>
On Mon, 25 Oct 2010, Slaven_Rezic via RT wrote: Show quoted text
> Since 0.44 it seems that a number of DateTime::Locale methods are > deprecated. The Changes file lists them, and suggests to replace them, > but I cannot find any hint what are the new method names to use. > Eventually I found the %subs mapping in the DateTime/Locale/Base.pm > source. > > That said, why not keep the deprecated methods forever in this mapping, > without any warnings?
Most of these methods were deprecated because they obscure the differences between different types of data that's available, and/or they are just plain wrong. For example, the old am_pm method takes a DateTime object and returns one value if the time is before noon, and another if it's after. Well, for some locales, there may be 3+ "time of day" names that should be used. This applies to other things like eras as well. The deprecated format methods attempt to convert CLDR formats to strftime, which is simply broken, because CLDR suppors many more specifiers than strftime. Basically, the old methods don't jive well with the rich amount of data provided by CLDR these days. That said, I'm not running to rip them out any time soon. A patch to use Package::DeprecationManager would be welcome, and that would make it easier for you to explicitly disable deprecations for your code. -dave /*============================================================ http://VegGuide.org http://blog.urth.org Your guide to all that's veg House Absolute(ly Pointless) ============================================================*/
Marking this resolved as these methods have mostly been removed in the 1.00 releases.