femic.fansier_runtime
The femic.fansier_runtime module owns FEMIC’s tracked FAN$IER GUI-automation
runtime seam on Windows.
Use this module when you need to:
launch FAN$IER from a clean session;
open the Batch form without a preloaded main-window regime;
load .rgm and optional .dis files;
drive broad product/age selections using FAN$IER’s own checked-list context-menu actions;
and harvest deterministic manifests around unattended batch outputs.
Why this module exists
FAN$IER’s broad unattended batch extraction surface turned out to be real, but the stable implementation path was not generic UIA checkbox poking. The key runtime seam is FAN$IER’s own checked-list context menu (Check All / Uncheck All) combined with the batch-form calculations label.
That means the code here owns:
Windows-only process/bootstrap logic for
Fansier.exe;batch-form synchronization against the live calculations label;
tracked manifest writing for unattended runs; and
the public helper surface used by the CLI.
Current scope
The first tracked runtime surface focuses on launching and running unattended batch extraction, not on downstream normalization of FAN$IER report text into tabular FEMIC artifacts. Output parsing is a follow-on concern.
Operational shape
In practical FEMIC use, this module now owns a Windows GUI-automation seam with the following stable shape:
launch FAN$IER from a clean session;
load one .rgm and optional .dis;
open Batch mode directly;
drive broad product/age selection through FAN$IER’s own checked-list context menus rather than generic UIA checkbox poking;
export deterministic batch reports; and
write a tracked manifest around the unattended run.
This is intentionally documented as GUI automation, not as a native FAN$IER CLI contract. If you need the higher-level one-command composition or the normalized output tables, move next to:
Windows FAN$IER batch-runtime helpers.
- class femic.fansier_runtime.FansierBatchRunResult(run_id, fansier_exe_path, rgm_path, output_dir, report_type, long_report, product_cols, activity_cols, discount_name, product_count, age_count, calculations, first_output_path, output_files, manifest_path, status_label)[source]
Bases:
objectOutputs from one unattended FAN$IER batch run.
- Parameters:
run_id (str)
fansier_exe_path (Path)
rgm_path (Path)
output_dir (Path)
report_type (str)
long_report (bool)
product_cols (bool)
activity_cols (bool)
discount_name (str)
product_count (int)
age_count (int)
calculations (int)
first_output_path (Path)
output_files (tuple[Path, ...])
manifest_path (Path)
status_label (str)
- activity_cols: bool
- age_count: int
- calculations: int
- discount_name: str
- fansier_exe_path: Path
- first_output_path: Path
- long_report: bool
- manifest_path: Path
- output_dir: Path
- output_files: tuple[Path, ...]
- product_cols: bool
- product_count: int
- report_type: str
- rgm_path: Path
- run_id: str
- status_label: str
- class femic.fansier_runtime.FansierCalculationCounts(regimes, settings, products, ages, calculations)[source]
Bases:
objectParsed counts from FAN$IER batch-form status text.
- Parameters:
regimes (int)
settings (int)
products (int)
ages (int)
calculations (int)
- ages: int
- calculations: int
- products: int
- regimes: int
- settings: int
- exception femic.fansier_runtime.FansierRuntimeError[source]
Bases:
RuntimeErrorRaised when unattended FAN$IER automation fails.
- femic.fansier_runtime.parse_fansier_calculation_counts(text)[source]
Parse the FAN$IER batch-form calculations label.
- Parameters:
text (str)
- Return type:
FansierCalculationCounts | None
- femic.fansier_runtime.run_fansier_batch(*, rgm_path, out_dir=PosixPath('tipsy_io/logs/fansier_batch'), log_dir=PosixPath('tipsy_io/logs'), run_id, fansier_exe_path=PosixPath('C:\\Program Files\\TIPSY 4.7\\Fansier\\Fansier.exe'), discount_name='FEMIC Raw 0%', discount_dis_path=None, report_type='txt', long_report=False, product_cols=True, activity_cols=False, select_all_products=False, select_all_ages=False, product_name='Lumber & Mill Residues (All Grades) (1)', age_name='Max MAI (12.5)')[source]
Run unattended FAN$IER batch extraction on Windows.
- Parameters:
rgm_path (Path)
out_dir (Path)
log_dir (Path)
run_id (str)
fansier_exe_path (Path)
discount_name (str)
discount_dis_path (Path | None)
report_type (str)
long_report (bool)
product_cols (bool)
activity_cols (bool)
select_all_products (bool)
select_all_ages (bool)
product_name (str)
age_name (str)
- Return type: