I have a shapefile with a start and end time field, properly formatted. However my dates range from 1864-1995. When I try to use the shape file with the QGIS time manager plugin I keep getting this message:

An error has occured while executing Python code:

Traceback (most recent call last):
  File "C:/PROGRA~2/Quantum GIS Wroclaw/apps/qgis/./python/plugins\TimeManager
   \timemanagerguicontrol.py", line 342, in updateTimeExtents
ValueError: year out of range

I found that one limitation of time manager is: The range of manageable years is limited due to limitations in time.mktime. The exact range is platform dependent.

Is there a way to find out what the exact range is or change it?

When I tested a sample of my shapefile for 1977 and 1984 they worked fine.


On my Win7 x64, the minimum datetime is 1970-01-01 01:00:00 (mktime returns 0).

A quick and dirty solution is to "shift" the dates into the supported range (over year 1970) by adding a big enough number to the year value.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.