Metadata-Version: 2.4
Name: fastpluggy-debug-tools
Version: 0.1.6
Summary: Debug Tools plugin for Fastpluggy
Author: FastPluggy Team
License-Expression: MIT
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: FastPluggy>=0.4.5
Requires-Dist: psutil
Requires-Dist: packaging
Provides-Extra: all
Requires-Dist: pympler; extra == "all"
Provides-Extra: tests
Requires-Dist: pytest>=7.0; extra == "tests"
Requires-Dist: pytest-cov>=4.0; extra == "tests"
Dynamic: license-file

# fastpluggy-debug-tools

![Debug Tools](https://img.shields.io/badge/FastPluggy-Debug%20Tools-blue)
[![Release](https://gitlab.ggcorp.fr/open/fastpluggy/plugins/debug_tools/-/badges/release.svg)](https://gitlab.ggcorp.fr/open/fastpluggy/plugins/debug_tools/-/releases)
[![Pipeline Status](https://gitlab.ggcorp.fr/open/fastpluggy/plugins/debug_tools/badges/main/pipeline.svg?key_text=CI)](https://gitlab.ggcorp.fr/open/fastpluggy/plugins/debug_tools/-/pipelines?ignore_skipped=true)
[![Coverage](https://gitlab.ggcorp.fr/open/fastpluggy/plugins/debug_tools/badges/main/coverage.svg)](https://gitlab.ggcorp.fr/open/fastpluggy/plugins/debug_tools/-/pipelines)

Debug Tools plugin for FastPluggy — runtime introspection and diagnostics.

## Install

```bash
pip install -e .
```

Optional extras for memory profiling:

```bash
pip install -e ".[all]"
```

## Usage

Register the plugin in your FastPluggy configuration. Once loaded it provides diagnostic pages for inspecting the running application: loaded plugins, configuration, routes, memory usage, and plugin compliance verification.

### Access

Every page requires a signed-in user with the `fp_admin` role. Without an auth manager (no authentication plugin installed), the core lets every visitor in, so these pages are open too: install an authentication plugin before exposing an application that loads `debug_tools`.

The environment-variables page masks the value of any variable whose name contains `PASS`, `SECRET`, `TOKEN`, `KEY`, `CREDENTIAL`, `AUTH`, `URL` or `DSN`, even for an administrator.

### Plugin Verification

The plugin provides compliance checking pages at:

- **`/verify/settings`** — Checks that plugin settings classes inherit from `BaseDatabaseSettings`
- **`/verify/compliance`** — Validates plugins against R1–R13 compliance rules (file structure, CI templates, e2e tests, etc.)
- **`/verify/`** — Overview page combining both checks with expandable per-plugin details

Access these pages from the debug tools dashboard menu.
