Skip Menu |

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

Report information
The Basics
Id: 39531
Status: resolved
Priority: 0/
Queue: MooseX-Types-DateTime

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

Bug Information
Severity: Wishlist
Broken in: 0.03
Fixed in: (no value)



I can't really see why MooseX::Types::DateTime and MooseX::Types::DateTimeX should be seperate modules even in the same distribution. It would be nice to have these rolled into one.
Subject: MooseX::Types::DateTimeX -- why seperate
I can't really see why MooseX::Types::DateTime and MooseX::Types::DateTimeX should be seperate modules even in the same distribution. It would be nice to have these rolled into one.
From: jjn1056 [...] yahoo.com
On Tue Sep 23 03:15:47 2008, CTBROWN wrote: Show quoted text
> I can't really see why MooseX::Types::DateTime and > MooseX::Types::DateTimeX should be seperate modules even in the same > distribution. It would be nice to have these rolled into one. >
I think the issue here is that the process of parsing the strings into objects is somewhere subject to ambiguity. Both modules should play nicely together, you can import DateTime from one and Duration for another, for example. Also you can switch one for the other based on need without requiring changes. MX:T:DateTimeX is a full superset of MX:T:DateTime as well, so if you use the extended one you can be sure to get all the features. If there is something that having the design this way is preventing for you, please let me know. This structure came out of a discussion between the author of DateTimeX and DateTime as a best compromise. Thanks! John Napiorkowski
Subject: Re: [rt.cpan.org #39531] MooseX::Types::DateTimeX -- why seperate
Date: Tue, 23 Sep 2008 19:13:23 +0300
To: Christopher Brown via RT <bug-MooseX-Types-DateTime [...] rt.cpan.org>
From: Yuval Kogman <nothingmuch [...] woobling.org>
Since DateTimeX provides coercions from strings which can be ambiguous, locale sensitive, and dependent on what is and isn't installed, it's not safe to provide it by default. This way if you want DWIM (like a coercion from a user typed string in a UI) then DateTimeX works well, but if you are programming a backend then it would sometimes be really annoying to debug On Tue, Sep 23, 2008 at 03:16:24 -0400, Christopher Brown via RT wrote: Show quoted text
> Tue Sep 23 03:16:22 2008: Request 39531 was acted upon. > Transaction: Ticket created by CTBROWN > Queue: MooseX-Types-DateTime > Subject: MooseX::Types::DateTimeX -- why seperate > Broken in: 0.03 > Severity: Wishlist > Owner: Nobody > Requestors: ctbrown@cpan.org > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=39531 > > > > I can't really see why MooseX::Types::DateTime and > MooseX::Types::DateTimeX should be seperate modules even in the same > distribution. It would be nice to have these rolled into one. > >
-- Yuval Kogman <nothingmuch@woobling.org> http://nothingmuch.woobling.org 0xEBD27418