Top-Q / difido-reports

This project aims to provide a generic implementation for HTML test reports.
http://top-q.github.io/difido-reports
Apache License 2.0
47 stars 31 forks source link

date is null in generate report casuing faild to enter document to ES #145

Closed ravivnice closed 6 years ago

ravivnice commented 7 years ago

hey,

try do debug the code and ( windows operation system ) and for some reason the report generate with date = null , casuing faild to enter to elastic search

execution json : "date":null," (execution.js)

do you have a clue why?

var execution = {"machines":[{"type":"machine","plannedTests":0,"name":"RAVIVE-T460","status":"success","children":[{"type":"scenario","scenarioProperties":null,"name":"default","status":"success","children":[{"type":"test","index":0,"uid":"5431500359021-1","description":"","duration":0,"date":null,"timestamp":"09:23:42:","className":"test.TestsExamples","parameters":null,"properties":null,"name":"test.TestsExamples","status":"success"}]}]}]};

elastic search error:

    at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-5.1.1.jar:5.1.1]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_131]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_131]
    at java.lang.Thread.run(Thread.java:748) [?:1.8.0_131]

Caused by: java.lang.IllegalArgumentException: Invalid format: "null 09:23:42:" at org.joda.time.format.DateTimeParserBucket.doParseMillis(DateTimeParserBucket.java:187) ~[joda-time-2.9.5.jar:2.9.5] at org.joda.time.format.DateTimeFormatter.parseMillis(DateTimeFormatter.java:826) ~[joda-time-2.9.5.jar:2.9.5] at org.elasticsearch.index.mapper.DateFieldMapper$DateFieldType.parse(DateFieldMapper.java:234) ~[elasticsearch-5.1.1.jar:5.1.1] at org.elasticsearch.index.mapper.DateFieldMapper.parseCreateField(DateFieldMapper.java:451) ~[elasticsearch-5.1.1.jar:5.1.1] at org.elasticsearch.index.mapper.FieldMapper.parse(FieldMapper.java:286) ~[elasticsearch-5.1.1.jar:5.1.1] ... 40 more

itaiag commented 6 years ago

There is a good chance that this issue is caused by issue #179 . I am closing this issue, but it will be reopened if the issue is reproduced after the fix of #179 is merged to the master branch.