tribler.core.versioning.restapi.versioning_endpoint

Attributes

RequestType

Classes

VersioningEndpoint

An endpoint for version determination and upgrading from the previous version.

Module Contents

type tribler.core.versioning.restapi.versioning_endpoint.RequestType = TriblerRequest[tuple[VersioningManager]]
class tribler.core.versioning.restapi.versioning_endpoint.VersioningEndpoint(middlewares: tuple = (), client_max_size: int = MAX_REQUEST_SIZE)

Bases: tribler.core.restapi.rest_endpoint.RESTEndpoint

An endpoint for version determination and upgrading from the previous version.

path = '/api/versioning'
versioning_manager: tribler.core.versioning.manager.VersioningManager | None = None
required_components = ('versioning_manager',)
async get_current_version(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Get the current release version, or None when running from archive or GIT.

async get_versions(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Get all versions in our state directory.

async check_version(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Check the tribler.org + GitHub websites for a new version.

async can_upgrade(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Check if we have old database/download files to port to our current version.

async perform_upgrade(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Perform an upgrade.

async is_upgrading(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Check if the upgrade is still running.

async remove_version(request: RequestType) tribler.core.restapi.rest_endpoint.RESTResponse

Remove the files for a version.