Last Comment Bug 781445 - AttributeError: 'datetime.timedelta' object has no attribute 'total_seconds'
: AttributeError: 'datetime.timedelta' object has no attribute 'tot...
Product: Core
Classification: Components
Component: JavaScript Engine (show other bugs)
: unspecified
: All Mac OS X
-- normal (vote)
: mozilla17
Assigned To: Terrence Cole [:terrence]
: Jason Orendorff [:jorendorff]
Depends on:
  Show dependency treegraph
Reported: 2012-08-09 00:18 PDT by Luke Wagner [:luke]
Modified: 2012-08-09 19:57 PDT (History)
3 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

v0 (2.08 KB, patch)
2012-08-09 10:55 PDT, Terrence Cole [:terrence]
benjamin: review+
Details | Diff | Splinter Review

Description User image Luke Wagner [:luke] 2012-08-09 00:18:44 PDT
I'm seeing this on OSX 10.6:

/moz/mi/js/src/tests $ ../d/js
[   0|   0|   0| 153]   4% =>                                         |   0.0sTraceback (most recent call last):
  File "./", line 299, in <module>
  File "./", line 289, in main
    run_tests(options, test_list, results)
  File "./", line 26, in run_tests
    completed = run_all_tests(tests, results, options)
  File "/Volumes/data/moz/mi/js/src/tests/lib/", line 191, in run_all_tests
    timeout = get_max_wait(tasks, results, options.timeout)
  File "/Volumes/data/moz/mi/js/src/tests/lib/", line 55, in get_max_wait
    wait = wait.total_seconds()
AttributeError: 'datetime.timedelta' object has no attribute 'total_seconds'
Comment 1 User image Nicolas B. Pierron [:nbp] 2012-08-09 10:50:07 PDT
I had the same thing with python 2.6.7, but not with python 2.7.2.  What is your version of python ?
Comment 2 User image Terrence Cole [:terrence] 2012-08-09 10:55:01 PDT
Created attachment 650618 [details] [diff] [review]

I accidentally added a 2.7 only feature when implementing
Comment 3 User image :Benjamin Peterson 2012-08-09 11:01:13 PDT
Comment on attachment 650618 [details] [diff] [review]

Review of attachment 650618 [details] [diff] [review]:

Everyone should upgrade their Pythons!
Comment 4 User image Terrence Cole [:terrence] 2012-08-09 11:40:54 PDT
The REHL buildbots have Python2.5.  Fortunately, the only time buildbots interact with this script is when they call --make-manifests: that one path is very much 2.5 only.

Generally stuff that does not run in --make-manifests runs fine under whatever python version is on my machine :-).  Although, I will hustle to fix any bustage if anyone notices and it's a reasonable request.  In this case, installing stuff on MacOS is a pita and 2.6 isn't that old and it's a trivial and *stable* method to copy into our sources.

Comment 5 User image Ryan VanderMeulen [:RyanVM] 2012-08-09 19:57:38 PDT

Note You need to log in before you can comment on or make changes to this bug.