stravalib.client.ActivityUploader#
- class stravalib.client.ActivityUploader(client, response, raise_exc=True)[source]#
The “future” object that holds information about an activity file upload and can wait for upload to finish, etc.
- __init__(client, response, raise_exc=True)[source]#
- client: stravalib.client.Client
The
stravalib.client.Clientobject that is handling the upload.- response: Dict[str,Any]
The initial upload response.
- raise_exc: bool
Whether to raise an exception if the response indicates an error state. (default True)
Methods
__init__(client, response[, raise_exc])client: stravalib.client.Client
poll()Update internal state from polling strava.com.
raise_for_error()update_from_response(response[, raise_exc])Updates internal state of object.
upload_photo(photo[, timeout])Uploads a photo to the activity.
wait([timeout, poll_interval])Wait for the upload to complete or to err out.
Attributes
is_completeis_erroris_processingphoto_metadataphoto metadata for the activity upload response, if any.