WiscAr / pychron

Data acquisition and processing framework for Ar-Ar geochronology and noble gas mass spectrometry
http://pychron.readthedocs.org/en/latest/
Apache License 2.0
0 stars 0 forks source link

bug when choosing sample in the browser #27

Open wiscarlab opened 5 years ago

wiscarlab commented 5 years ago

active branch=release/py3/v18.2

active analyses=UW146:A5-01A,UW146:A5-02A,UW146:A5-03A,UW146:A5-04A,UW146:A5-05A,UW146:A5-06A,UW146:A5-07A,UW146:A5-08A,UW146:A5-09A,UW146:A5-10A,UW146:A5-11A,UW146:A5-12A,UW146:A5-13A,UW146:A5-14A,UW146:A5-15A,UW146:A5-16A,UW146:A5-17A

description="analysis time was exactly 00:00:000 between 3/17 and 3/18. Peter added one sec to time stamp and bug still appears when you click on this sample in the browser."

Traceback

Traceback (most recent call last):
  File "C:\Users\jross\AppData\Local\conda\conda\envs\pychron3\lib\site-packages\traits\trait_notifiers.py", line 340, in __call__
    self.handler( *args )
  File "C:\Users\raregas\.pychron.0\pychron\pychron\envisage\browser\browser_model.py", line 239, in _selected_samples_changed
    self._selected_samples_changed_hook(new)
  File "C:\Users\raregas\.pychron.0\pychron\pychron\envisage\browser\sample_browser_model.py", line 293, in _selected_samples_changed_hook
    self.analysis_table.set_analyses(ans, selected_identifiers={ai.identifier for ai in new})
  File "C:\Users\raregas\.pychron.0\pychron\pychron\envisage\browser\analysis_table.py", line 188, in set_analyses
    new_items = sort_items(aa)
  File "C:\Users\raregas\.pychron.0\pychron\pychron\envisage\browser\analysis_table.py", line 42, in sort_items
    return sorted(ans, key=attrgetter('timestampf'))
  File "C:\Users\raregas\.pychron.0\pychron\pychron\dvc\dvc_orm.py", line 161, in timestampf
    return make_timef(self.timestamp)
  File "C:\Users\raregas\.pychron.0\pychron\pychron\core\helpers\datetime_tools.py", line 75, in make_timef
    t = time.mktime(timestamp.timetuple())
OverflowError: mktime argument out of range
jirhiker commented 5 years ago

the timestamp in the database and in the json files are incorrect.

e.g for NAI1298 the timestamp is 1903-12-31 18:00:00