How to get Katalon's console log in Collection of Suite execution?

I am trying to run the Collection of Test Suite. And at the end of execution, I could not find a way to get the detail log of all these Test Suite execution, which we usually see in Katalon’s console tab.
Is katalon already saving the logs somewhere ? if not, is there any way to get the logs stored in some file ?

Thanks for the response. It helps for now.
Coming to the second question, is there any way to get these logs stored in some file along with the report ?

Let me explain by example. A katalon project named β€œtest” has a Test Suite Collection named β€œTSC” which comprises with 2 Test Suites: β€œTS1” and β€œTS2”. The TSC wrote files in the Reports folder as follows:

:~/katalon-workspace/test (master *)
$ tree -s Reports/20221109_170914/
[        160]  Reports/20221109_170914/
β”œβ”€β”€ [         96]  TS1
β”‚   └── [        352]  20221109_170915
β”‚       β”œβ”€β”€ [        312]  20221109_170915.csv
β”‚       β”œβ”€β”€ [     202413]  20221109_170915.html
β”‚       β”œβ”€β”€ [       1603]  JUnit_Report.xml
β”‚       β”œβ”€β”€ [       2678]  execution.properties
β”‚       β”œβ”€β”€ [         36]  execution.uuid
β”‚       β”œβ”€β”€ [       8154]  execution0.log
β”‚       β”œβ”€β”€ [         91]  testCaseBinding
β”‚       β”œβ”€β”€ [         15]  tsc_id.txt
β”‚       └── [         64]  videos
β”œβ”€β”€ [         96]  TS2
β”‚   └── [        352]  20221109_170917
β”‚       β”œβ”€β”€ [        738]  20221109_170917.csv
β”‚       β”œβ”€β”€ [     208071]  20221109_170917.html
β”‚       β”œβ”€β”€ [      13820]  JUnit_Report.xml
β”‚       β”œβ”€β”€ [       2678]  execution.properties
β”‚       β”œβ”€β”€ [         36]  execution.uuid
β”‚       β”œβ”€β”€ [      27767]  execution0.log
β”‚       β”œβ”€β”€ [         91]  testCaseBinding
β”‚       β”œβ”€β”€ [         15]  tsc_id.txt
β”‚       └── [        128]  videos
β”‚           β”œβ”€β”€ [     136470]  screen_recording_1_0.avi
β”‚           └── [        335]  screen_recording_1_0.srt
└── [         96]  TSC
    └── [         96]  20221109_170914
        └── [       1299]  20221109_170914.rp

8 directories, 19 files

In each Test Suite folder, you find a file named execution0.log. This is the file you want.

I guess, you would be surprised to find the execute0.log file is not a plain line-oriented text; it is an XML file like this:

$ head -n 20 Reports/20221109_170914/TS1/20221109_170915/execution0.log
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE log SYSTEM "logger.dtd">
<log>
<record>
  <date>2022-11-09T17:09:22</date>
  <millis>1667981362757</millis>
  <sequence>0</sequence>
  <level>START</level>
  <class>com.kms.katalon.core.logging.XmlKeywordLogger</class>
  <method>startSuite</method>
  <thread>1</thread>
  <message>Start Test Suite : Test Suites/TS1</message>
  <nestedLevel>0</nestedLevel>
  <escapedJava>false</escapedJava>
  <property name="rerunTestFailImmediately">false</property>
  <property name="retryCount">0</property>
  <property name="name">TS1</property>
  <property name="description"></property>
  <property name="id">Test Suites/TS1</property>
</record>

Classical shell commands (grep, sed, etc) are not enough. You need a program that parses the execution0.log to extract information you want out of it. You need to develop it for yourself.

Ths execution0.log find tends to be very large (20Kbytes, 20mb, or even larger). Therefore DOM-oriented XML parsers are not good fit for processing it. Katalon Studio uses StAX parser to process execution0.log file. See the following article about StAX programming:

1 Like

Thank you so much.
I will take it from here :slight_smile: