DTLcode — User Guide v1.7-3

Quickly analyze a source file and understand its role without executing it.

versionv1.7-3dateJuly 30, 2026outputHTMLplatformWindows / PythonlicenseMIT

What does DTLcode do?

DTLcode helps answer a simple question: “What does this source file do?” It reads the file, recognizes its language, identifies its components, and produces a clear HTML page describing its likely purpose.

Use it to discover a legacy program, prepare documentation, guide an audit, or obtain an initial overview before reading the code in detail.

No execution risk: DTLcode never runs the analyzed file. It handles it only as text.

Requirements

Using the executable

Run DTLcode.exe directly. Python is not required on the computer.

Using the source

Use Python 3.10 or later. No external library is required.

Getting started

Simplest method: the file dialog

  1. Double-click DTLcode.exe.
  2. Select the source file in the file dialog.
  3. Wait for DTLcode_report.html to be created.
  4. The report opens automatically in your default browser.

If you cancel the selection, the program exits without creating a file or displaying an error.

Command-line use

DTLcode.exe MyProgram.py

This command analyzes MyProgram.py, writes DTLcode_report.html in the current directory, and attempts to open it.

python DTLcode.py MyProgram.py

The same operation can be run from the Python source.

Reading the report

The top of the page shows the file name and path, detected language, line count, size, and encoding. Use this information to immediately confirm that the correct file was analyzed.

Purpose and workflow

What this file is for summarizes its likely purpose. How the program obtains the result lists the main observed steps, such as reading data, analysis, transformation, external calls, or result creation.

Subroutine table

The table has two columns:

ColumnContent
FunctionA readable functional label for the subroutine.
DescriptionOne or two sentences explaining the operations actually observed: reading, analysis, validation, object creation, HTML generation, and so on.

The description does not repeat the technical subroutine name. If its role is uncertain, DTLcode reports visible operations instead of inventing intent.

Resources, errors, and usage

Practical examples

Analyze a Python program

DTLcode.exe "D:\Projects\tool\main.py"

Use quotation marks when a path contains spaces. Python receives the richest analysis: imports, classes, functions, assignments, and operations found inside function bodies.

Choose the report name and location

DTLcode.exe main.py -o "D:\Reports\main-analysis.html"

The -o or --output option sets the HTML page path. The destination directory must already exist and be writable.

Use DTLcode from a script

DTLcode.exe source.ps1 -o source-report.html if errorlevel 1 echo Analysis failed

The exit code allows a Batch or PowerShell script to detect failure. Automatic report opening depends on the HTML file association configured in Windows.

Display the version

DTLcode.exe --version

This command displays the application name and version without analyzing a file.

Messages, errors, and troubleshooting

Exit codes

CodeSituationSuggested action
0Report created, version displayed, or selection cancelled.No action required.
1Read, write, or operating-system error.Check permissions, encoding, and the output directory.
2The path does not exist or is not a file.Correct the path or select another file.

Common problems

SymptomLikely causeSolution
The report does not openNo application is associated with HTML files.Open the report manually in a browser.
The report cannot be writtenThe folder is missing or protected.Choose an existing folder where you have write access.
Unknown languageThe extension is missing or unrecognized.Check the extension; generic analysis is still produced.
Very little informationGeneric language, dynamic code, or a mostly data-oriented file.Treat the report as an orientation aid and complete it with human review.
Incorrect charactersAn uncommon encoding was not recognized.Convert a copy of the file to UTF-8 and analyze it again.

Interpreting results correctly

Tip: use DTLcode to decide where to look first, then confirm important conclusions by reading the code or its official documentation.