sec_interp.core.services.export.path_resolver module

Path resolution for export operations.

sec_interp.core.services.export.path_resolver.get_profile_name(controller: Any | None) → str

Return sanitized profile name derived from the section layer.

Parameters:

controller – Optional controller holding settings.section.layer_name.

Returns:

Sanitized profile name, defaults to "profile".

sec_interp.core.services.export.path_resolver.resolve_export_path(folder: Path, base_name: str, profile_name: str, naming_pattern: str | None, ext: str) → tuple[Path, str]

Generate unified output path and logical layer name.

Parameters:
  • folder – Base output directory.

  • base_name – Logical export name (e.g. "topo_profile").

  • profile_name – Sanitized profile/section name.

  • naming_pattern – Optional pattern with {filename} and {profile} placeholders.

  • ext – File extension including dot (.csv, .shp, .gpkg, .dxf).

Returns:

Tuple of (filesystem Path, logical layer name).