rlsbl v0.113.0 /rlsbl.lint.protocol
On this page

Abstract protocol defining the interface that all per-language linters must implement for boundary violation detection and reporting.

#rlsbl.lint.protocol

#rlsbl.lint.protocol

Abstract protocols defining interfaces for per-language linters and import scanners.

#LanguageLinter

Interface for per-language linters that check library boundary violations.

#lint

python
def lint(self, project_path: str, config: LanguageLintConfig) -> list[LintResult]

Run all lint checks on the project and return violations.

#ImportScanner

Interface for AST-based import scanners that extract all imports from a project.

#scan_imports

python
def scan_imports(self, project_path: str) -> set[tuple[str, str, int, bool]]

Collect all imports from source files in a project.

Returns a set of (package_name, file_path, line_number, guarded) tuples. Guarded imports are those inside try/except ImportError blocks.

Search