paper_firehose.core.config

Configuration management for YAML-based config files.

Classes

ConfigManager([config_path])

Manages loading and validation of YAML configuration files.

class paper_firehose.core.config.ConfigManager(config_path=None)[source]

Bases: object

Manages loading and validation of YAML configuration files.

Parameters:

config_path (str | None)

check_unknown_keys()[source]

Return warnings for unrecognised keys in main and topic configs.

Return type:

List[str]

get_available_topics()[source]

Get list of available topic configuration files.

Return type:

List[str]

get_enabled_feeds()[source]

Get all enabled feeds from the main configuration.

Return type:

Dict[str, Dict[str, Any]]

get_priority_journals()[source]

Get the list of priority journals.

Return type:

List[str]

load_config()[source]

Load the main configuration file.

Return type:

Dict[str, Any]

load_topic_config(topic_name)[source]

Load a topic-specific configuration file.

Return type:

Dict[str, Any]

Parameters:

topic_name (str)

validate_config()[source]

Validate the configuration files.

Return type:

bool