This is an automated notification sent by LCG Savannah.
It relates to:
task #12102, project CDS Invenio
==============================================================================
LATEST MODIFICATIONS of task #12102:
==============================================================================
Follow-up Comment #1, task #12102 (project cdsware):
I recently stumbled upon:
<http://www.egenix.com/products/python/mxBase/mxDateTime/>. This might help
solve this issue...
[...]
* Parses date/time string values in an almost seamless way.
* Provides conversion routines to and from many different alternative
date/time storage formats.
* Includes an easy-to-use C API which makes integration a breeze.
* Fast, memory efficient, accurate.
* Georgian and Julian calendar support.
* Vast range of valid dates (including B.C. dates).
* Compatible to Python's datetime and time modules.
* Stable, robust and portable (mxDateTime has been around for almost 10
years now).
* Free to use and redistribute.
* Fully interoperates with Python's time and datetime modules.
[...]
==============================================================================
OVERVIEW of task #12102:
==============================================================================
URL:
<http://savannah.cern.ch/task/?12102>
Summary: OAIRepository: handle dates before 1900-01-01
Project: CDS Invenio
Submitted by: jcaffaro
Submitted on: 2009-10-22 05:40
Should Start On: 2009-10-22 00:00
Should be Finished on: 2009-10-22 00:00
Category: BibHarvest
Priority: 5 - Normal
Status: None
Privacy: Public
Percent Complete: 0%
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Effort: 0.00
_______________________________________________________
The OAI gateway does not support dates prior to 1900, due to usage of the
_time_ module.
Solutions to explore:
* Use built-in _datetime_ module (be cautious since _datetime.strftime()_
still does not support years prior to 1900)
* Use python-dateutil module
* Do not accept dates prior to 1900 as input (at least returns an
OAI-compliant output)
uri:
</oai2d.py/?verb=ListRecords&metadataPrefix=oai_dc&from=0000-01-01&until=1899-12-31>
>>> Traceback details
Forced traceback (most recent call last):
File "/usr/lib64/python2.3/site-packages/mod_python/importer.py", line
1229, in _process_target
result = _execute_target(config, req, object, arg)
File "/usr/lib64/python2.3/site-packages/mod_python/importer.py", line
1128, in _execute_target
result = object(arg)
File "/usr/lib64/python2.3/site-packages/invenio/webinterface_handler.py",
line 320, in _profiler
return _handler(req)
Traceback (most recent call last):
File "/usr/lib64/python2.3/site-packages/invenio/webinterface_handler.py",
line 362, in _handler
return root._traverse(req, path, False, guest_p)
File "/usr/lib64/python2.3/site-packages/invenio/webinterface_handler.py",
line 207, in _traverse
return obj._traverse(req, path, do_head, guest_p)
File "/usr/lib64/python2.3/site-packages/invenio/webinterface_handler.py",
line 226, in _traverse
result = _check_result(req, obj(req, form))
File
"/usr/lib64/python2.3/site-packages/invenio/oai_repository_webinterface.py",
line 125, in __call__
req.write(oai_repository.oailistrecords(args))
File "/usr/lib64/python2.3/site-packages/invenio/oai_repository.py", line
510, in oailistrecords
sysnos = oaigetsysnolist(arg['set'], arg['from'], arg['until'])
File "/usr/lib64/python2.3/site-packages/invenio/oai_repository.py", line
748, in oaigetsysnolist
d2=utc_to_localtime(untildate),
File "/usr/lib64/python2.3/site-packages/invenio/oai_repository.py", line
210, in utc_to_localtime
utc_time = time.mktime((int(lyear), int(lmonth), int(lday), int(lhour),
int(lminute), int(lsec), 0, 0, -1))
ValueError: year out of range
_______________________________________________________
Follow-up Comments:
-------------------------------------------------------
Date: 2010-02-22 05:50 By: Samuele Kaplun <skaplun>
I recently stumbled upon:
<http://www.egenix.com/products/python/mxBase/mxDateTime/>. This might help
solve this issue...
[...]
* Parses date/time string values in an almost seamless way.
* Provides conversion routines to and from many different alternative
date/time storage formats.
* Includes an easy-to-use C API which makes integration a breeze.
* Fast, memory efficient, accurate.
* Georgian and Julian calendar support.
* Vast range of valid dates (including B.C. dates).
* Compatible to Python's datetime and time modules.
* Stable, robust and portable (mxDateTime has been around for almost 10
years now).
* Free to use and redistribute.
* Fully interoperates with Python's time and datetime modules.
[...]
_______________________________________________________
Carbon-Copy List:
CC Address | Comment
------------------------------------+-----------------------------
2195 | -COM-
2407 | -SUB-
==============================================================================
This item URL is:
<http://savannah.cern.ch/task/?12102>
_______________________________________________
Message sent via/by LCG Savannah
http://savannah.cern.ch/