In my experience the mentioned problem:

> AttributeError: 'TestCaseMetadata' object has no attribute 'time'

It's a simple reflection of a regression not being able to complete its 
execution (note, this is different than failing), and it is not strictly 
related to testlib.
If the regression is timing out, testlib is not able to produce the execution 
time and it is therefore raising an exception when the metadata needs to be
serialized to the xml file.

I think we should consider adding a default zero value to the time property so 
that people don't get mislead by the python backtrace

Kind Regards

Giacomo

> -----Original Message-----
> From: Gabe Black via gem5-dev <[email protected]>
> Sent: 10 February 2021 21:59
> To: gem5 Developer List <[email protected]>
> Cc: Gabe Black <[email protected]>
> Subject: [gem5-dev] Re: test library error
>
> I don't think so, I just wanted to point it out since it would otherwise 
> probably
> never get seen. I do occasionally see weird errors like this, but not all that
> often. I haven't paid close enough attention to them to notice if they follow 
> a
> pattern.
>
> Gabe
>
> On Wed, Feb 10, 2021 at 11:30 AM Bobby Bruce via gem5-dev <gem5-
> [email protected] <mailto:[email protected]> > wrote:
>
>
> Hey Gabe,
>
> This is weird, though I cannot replicate it. I'd also guess it's weird
> timeout. Have you seen it elsewhere?
>
> Kind regards,
> Bobby
>
> --
>
> Dr. Bobby R. Bruce
> Room 2235,
> Kemper Hall, UC Davis
> Davis,
> CA, 95616
>
>
> web: https://www.bobbybruce.net
>
>
>
> On Mon, Feb 8, 2021 at 9:31 PM Gabe Black via gem5-dev <gem5-
> [email protected] <mailto:[email protected]> > wrote:
>
>
> Hi folks. In the kokoro log for this run, I see the below error. I
> suspect it timed out? In any case, it looks like there's a bug in the testing 
> library
> somebody might want to look into.
>
> https://gem5-
> review.googlesource.com/c/public/gem5/+/40795/3
>
>
> https://source.cloud.google.com/results/invocations/558d1dfb-a6bd-
> 46f9-baac-6f53d3ac0fd3
>
>
>
> ======== Results: 597 Passed, 6 Failed, 1 Errored in 1.3e+04
> seconds ========== Traceback (most recent call last): File "./main.py", line 
> 25,
> in <module> sys.exit(testlib()) File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/main.py", line 331, in main result =
> globals()['do_'+configuration.config.command]() File "/tmpfs/src/git/jenkins-
> gem5-prod/tests/../ext/testlib/main.py", line 303, in do_run return
> run_schedule(test_schedule, log_handler) File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/main.py", line 277, in run_schedule
> log_handler.finish_testing() File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/main.py", line 68, in finish_testing
> self.result_handler.close() File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/handlers.py", line 164, in close self._save() File
> "/tmpfs/src/git/jenkins-gem5-prod/tests/../ext/testlib/handlers.py", line 156,
> in _save result.JUnitSavedResults.save( File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/result.py", line 330, in save results =
> JUnitTestSuites(results) File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/result.py", line 238, in __init__
> self.elements.append(JUnitTestSuite(suite)) File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/result.py", line 264, in __init__
> self.elements.append(JUnitTestCase(test)) File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/result.py", line 277, in __init__ 
> XMLAttribute('time',
> str(test_result.time["user_time"])), File "/tmpfs/src/git/jenkins-gem5-
> prod/tests/../ext/testlib/result.py", line 77, in time return 
> self._metadata.time
> AttributeError: 'TestCaseMetadata' object has no attribute 'time'
>
> _______________________________________________
> gem5-dev mailing list -- [email protected] <mailto:gem5-
> [email protected]>
> To unsubscribe send an email to [email protected]
> <mailto:[email protected]>
> %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
>
> _______________________________________________
> gem5-dev mailing list -- [email protected] <mailto:gem5-
> [email protected]>
> To unsubscribe send an email to [email protected]
> <mailto:[email protected]>
> %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

IMPORTANT NOTICE: The contents of this email and any attachments are 
confidential and may also be privileged. If you are not the intended recipient, 
please notify the sender immediately and do not disclose the contents to any 
other person, use it for any purpose, or store or copy the information in any 
medium. Thank you.
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to