test-bugzilla-files/test-bugzilla-files.py | 7 ++++--- test-bugzilla-files/zip.sh | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-)
New commits: commit 5f98759d3b424308c5688c30ec87110fbab0faf7 Author: Gülşah Köse <[email protected]> AuthorDate: Mon Oct 18 17:08:29 2021 +0300 Commit: Miklos Vajna <[email protected]> CommitDate: Mon Oct 18 16:31:00 2021 +0200 Create odfundifflog.csv in a simple way. Remove import_csv and export_csv functions and just write the data to a file directly. Change-Id: Ia28f15984e630647f2097516c3da2c8f61257034 Reviewed-on: https://gerrit.libreoffice.org/c/dev-tools/+/123751 Tested-by: Miklos Vajna <[email protected]> Reviewed-by: Miklos Vajna <[email protected]> diff --git a/test-bugzilla-files/test-bugzilla-files.py b/test-bugzilla-files/test-bugzilla-files.py index 6dec0e0..ac219ac 100644 --- a/test-bugzilla-files/test-bugzilla-files.py +++ b/test-bugzilla-files/test-bugzilla-files.py @@ -34,7 +34,6 @@ import time import uuid import datetime import re -from analyze_logs import import_csv, export_csv import signal import threading @@ -340,8 +339,10 @@ def handleODFunDiff(file, odfundifflog): result["total-diff-count"] = len(odfundifflog.splitlines()) - 1 # Last line of log is not a real difference result["attr-diff-count"] = getDifferencesByType("Attribute" , odfundifflog) result["node-diff-count"] = getDifferencesByType("Node", odfundifflog) - reader = import_csv("odfundifflog.csv") - export_csv("odfundifflog.csv", result, reader, header=False) + + odfundifflog_f = open("odfundifflog.csv", "a") + odfundifflog_f.write(file + "," + str(result["total-diff-count"]) + "," + str(result["attr-diff-count"]) + "," + str(result["node-diff-count"]) + "\n") + odfundifflog_f.close() def getDifferencesByType(type, odfundifflog): difflist = odfundifflog.splitlines() diff --git a/test-bugzilla-files/zip.sh b/test-bugzilla-files/zip.sh index a923cb5..b35117f 100755 --- a/test-bugzilla-files/zip.sh +++ b/test-bugzilla-files/zip.sh @@ -9,7 +9,7 @@ mkdir -p /srv/crashtestdata/logs/$SHA/backtraces for a in */core*; do gdb ~/build/instdir/program/soffice.bin $a -ex "thread apply all backtrace full" --batch > /srv/crashtestdata/logs/$SHA/backtraces/`dirname "$a"`-`basename "$a"`.backtrace.txt; done cat */crashlog.txt > /srv/crashtestdata/logs/$SHA/crashlog.txt cat */exportCrash.txt > /srv/crashtestdata/logs/$SHA/exportCrash.txt -echo "attr-diff-count,filename,node-diff-count,total-diff-count" > /srv/crashtestdata/logs/$SHA/odfundifflog.csv +echo "filename,total-diff-count,attr-diff-count,node-diff-count" > /srv/crashtestdata/logs/$SHA/odfundifflog.csv cat */odfundifflog.csv >> /srv/crashtestdata/logs/$SHA/odfundifflog.csv # Ignore the header. num_of_odf_diffs=$(($(< "/srv/crashtestdata/logs/$SHA/odfundifflog.csv" wc -l)-1))
