Debug information is very valuable information. The information gives an in-depth look into what is happening inside the program. Troubleshooting problems is made a lot easier as the programmer can see step by step what the program is doing.
How to enable debug info?
- Go to Templates -> Templates
- Click on the name of your template to Edit the template
- Select the Details tab
- Set the Enable logging to Yes.
- After you ran an import or export, you will be shown the results page and here you can find the debug log options:
These options are also available if you click on Logs in the menu.
- There are 3 options available:
This will show the debug log in a popup window
This will open the debug log in a new window
This will download the debug log in a zip file or if the debug log is too large, it will download as a text file
- Now you have a debug log.
- Click on Process
- Select Import or Export
- Select your component
- Select the operation you want to perform
- Click on Go
- Under File set the Collect debug information option to Yes. So it looks like this:
- After the Import or Export, click on Show Panel
- Click on Log
- Click on the Import /Export you just did
- See here the Download debug log link:
- Click on the Download link and post the zip file in the forum for checking.
- Now you have a debug log.
Import crashes and no debug log
It can happen that the import crashes and no log details are stored, the debug log is still created but need to be retrieved from the server. The debug logs are stored in the folder logs/ for CSVI 6 and tmp/com_csvi/debug for CSVI 5. Find the last created file in this folder and that will be your debug log for your last import.
Debug information collects a lot of info, it is advised not to use it with large imports, rather use a small sample of a few records.
What to do with the debug output?
Once the debug output is generated it is ready for analysis and can be posted on the forum along with the description of the problem and a sample of the import file. Make sure the debug log is zipped otherwise it cannot be uploaded.
Limiting number of lines in Debug log
Starting from CSVI 7.7.0 version a new feature for limiting the lines in to the debug log has been added. This feature is very helpful in case of Imports with large number of records. Instead of generating a huge debug log with entries of all records and struggling to handling the large debug log file, you can now limit the number of lines in debug log so the generated debug log is small and easy to handle in forum as well as for checking on issues.
To add the number of lines to log file, go to CSVI Dashboard page, click on Options button on top right corner, on Site tab set Number of lines in log file field. By default it is 20.