On Wed, 5 Feb 2003, John Peacock wrote: > No, it's clear that the modules are deeply intertwined. My primary concern is > that it is currently impossible to install both on a fresh machine without > skipping the tests on one of the two (at least to begin with). In my mind, > DateTime is the parent module (and DateTime::TimeZone is the crazy cousin ;) and > should be installed first. DT::TZ should be dependent on DT, IMHO, not the > other way round.
That's probably true. > The DateTime tests do not fully exercise DateTime::TimeZone (nor would you > expect them to). So, how about including only those portions of DT::TZ which > are required to pass the DT tests. At a quick glance, that would be > TimeZone.pm, UTC.pm, Floating.pm, America/Chicago.pm, and America/NewYork.pm. > For that matter, since you know exactly what tests are being performed, you can > include exactly the portions of the OlsonDB that are used in the DateTime tests > and no more. It seems rather arbitrary to only include Chicago and New York. I can just see all the questions about why the others aren't included! It might be best to just skip those tests if the DateTime::TimeZone package isn't installed, though. > The TimeZone.pm that would be distributed with DateTime could be suitably > booby-trapped (i.e. warn "You must install the full DateTime::TimeZone before > using this module"). It would be replaced by the full version after DT::TZ was > tested and installed. Or distribute everything _but_ the generated files and DateTime::TimeZone::OlsonDB. That way you could do offset only and floating time zone stuff, but to do the historical/rules-based stuff you install a separate package. > I would also suggest that the base DateTime::TimeZone release only needs to > contain stub modules for the data files and the Makefile.PL should actually be > responsible for generating the multitude of PM's prior to testing. You could > even include a preamble to Makefile.PL which would download the latest Olson > file (if you want to make the installation dependent on Net::FTP). For those > that don't have Net::FTP installed, the Makefile.PL could request that they > independently download the Olson files themselves and expand them into a top > level OlsonDB directory and rerun 'perl Makefile.PL' to build the TZ files. Now that's a PITA! It depends on Net::FTP _and_ Archive::Zip (the TZ data is in a zip file). Too much work for now at least. -dave /*======================= House Absolute Consulting www.houseabsolute.com =======================*/