Streamer client for game files transfer#

class Config(**kwargs)[source]#

Bases: object

playing_file = ''#
sync_runs = False#
modded = False#
debug = False#
secret = ''#
use_mt = False#
use_slice = False#
steam_id = ''#
server_url = ''#
spiredir = ''#
user_profile = ''#
slice_curses = ''#
export()[source]#
class Main[source]#

Bases: object

Main client class. Only one instance should be active at a time.

is_exception_recurring() bool[source]#

Check if the ongoing exception keeps re-ocurring.

Raises:

RuntimeError – If there is no active exception.

Returns:

True if the exception is the same as the previous one, False otherwise.

Return type:

bool

load_last_modified()[source]#

Load last-modified information, to save on network transfers.

update_modified_timestamp(**kwargs: dict[str, str | int | float | None])[source]#

Keep track of what was modified, to only update when needed.

save_last_modified(*, force=False)[source]#

Save last-modified information, for cross-session persistence.

Parameters:

force (bool, default False) – Whether to force a commit to disk.

async run()[source]#
async check_twitch_credentials()[source]#

Check if the app is registered, prompt it if not.

get_savefile_sts1() Path | None[source]#

Find and return the current run save file, or None if no run is ongoing.

Raises:

ValueError – If multiple possible saves are detected.

Returns:

Slay the Spire current run save file.

Return type:

pathlib.Path | None

get_savefile_sts2() Path | None[source]#

Find and return the current run save file, or None if no run is ongoing.

Raises:

ValueError – If multiple possible saves are detected.

Returns:

Slay the Spire 2 current run save file.

Return type:

pathlib.Path | None

async sync_savefile(savefile: Path | None, game_version: int)[source]#
async sync_runfiles_sts1()[source]#

Fetch and sync the Spire 1 run files.

async sync_runfiles_sts2()[source]#

Fetch and sync the Spire 2 run files.

async sync_profiles()[source]#

Update all Spire profiles.

async sync_slice_dice_data()[source]#
get_monster_train_folder(game_version: int)[source]#

Get the filepatch for the Monster Train data. May not exist.

async sync_monster_train_save(game_version: int)[source]#
async get_now_playing()[source]#