@@ -4097,36 +4097,9 @@ class ProjectWikiManager(CRUDMixin, RESTManager):
40974097 _list_filters = ("with_content" ,)
40984098
40994099
4100- class ProjectExport (RefreshMixin , RESTObject ):
4100+ class ProjectExport (ExportMixin , RefreshMixin , RESTObject ):
41014101 _id_attr = None
41024102
4103- @cli .register_custom_action ("ProjectExport" )
4104- @exc .on_http_error (exc .GitlabGetError )
4105- def download (self , streamed = False , action = None , chunk_size = 1024 , ** kwargs ):
4106- """Download the archive of a project export.
4107-
4108- Args:
4109- streamed (bool): If True the data will be processed by chunks of
4110- `chunk_size` and each chunk is passed to `action` for
4111- reatment
4112- action (callable): Callable responsible of dealing with chunk of
4113- data
4114- chunk_size (int): Size of each chunk
4115- **kwargs: Extra options to send to the server (e.g. sudo)
4116-
4117- Raises:
4118- GitlabAuthenticationError: If authentication is not correct
4119- GitlabGetError: If the server failed to perform the request
4120-
4121- Returns:
4122- str: The blob content if streamed is False, None otherwise
4123- """
4124- path = "/projects/%s/export/download" % self .project_id
4125- result = self .manager .gitlab .http_get (
4126- path , streamed = streamed , raw = True , ** kwargs
4127- )
4128- return utils .response_content (result , streamed , action , chunk_size )
4129-
41304103
41314104class ProjectExportManager (GetWithoutIdMixin , CreateMixin , RESTManager ):
41324105 _path = "/projects/%(project_id)s/export"
0 commit comments