diff --git a/dataproxy_sdk/python/__init__.py b/dataproxy_sdk/python/__init__.py index 46f09c2..773a130 100644 --- a/dataproxy_sdk/python/__init__.py +++ b/dataproxy_sdk/python/__init__.py @@ -4,4 +4,4 @@ __all__ = [ "DataProxyFileAdapter", "proto", -] \ No newline at end of file +] diff --git a/dataproxy_sdk/python/dp_file_adapter.py b/dataproxy_sdk/python/dp_file_adapter.py index 38a79b5..5d506d8 100644 --- a/dataproxy_sdk/python/dp_file_adapter.py +++ b/dataproxy_sdk/python/dp_file_adapter.py @@ -1,6 +1,7 @@ from . import libdataproxy from . import dp_pb2 as proto + class DataProxyFileAdapter: def __init__(self, config: proto.DataProxyConfig): self.data_proxy_file = libdataproxy.DataProxyFile(config.SerializeToString()) @@ -8,8 +9,16 @@ def __init__(self, config: proto.DataProxyConfig): def close(self): self.data_proxy_file.close() - def download_file(self, info: proto.DownloadInfo, file_path: str, file_format: proto.FileFormat): - self.data_proxy_file.download_file(info.SerializeToString(), file_path, file_format) + def download_file( + self, info: proto.DownloadInfo, file_path: str, file_format: proto.FileFormat + ): + self.data_proxy_file.download_file( + info.SerializeToString(), file_path, file_format + ) - def upload_file(self, info: proto.UploadInfo, file_path: str, file_format: proto.FileFormat): - self.data_proxy_file.upload_file(info.SerializeToString(), file_path, file_format) \ No newline at end of file + def upload_file( + self, info: proto.UploadInfo, file_path: str, file_format: proto.FileFormat + ): + self.data_proxy_file.upload_file( + info.SerializeToString(), file_path, file_format + ) diff --git a/dataproxy_sdk/python/dp_pb2.py b/dataproxy_sdk/python/dp_pb2.py index 7b6470e..b115c57 100644 --- a/dataproxy_sdk/python/dp_pb2.py +++ b/dataproxy_sdk/python/dp_pb2.py @@ -1 +1 @@ -from dataproxy_sdk.proto.data_proxy_pb_pb2 import * \ No newline at end of file +from dataproxy_sdk.proto.data_proxy_pb_pb2 import * diff --git a/docs/conf.py b/docs/conf.py index ea55e5d..84a6124 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -33,9 +33,9 @@ # -- Project information ----------------------------------------------------- -project = 'DataProxy' -copyright = '2023 Ant Group Co., Ltd.' -author = 'DataProxy authors' +project = "DataProxy" +copyright = "2023 Ant Group Co., Ltd." +author = "DataProxy authors" # -- General configuration --------------------------------------------------- @@ -43,36 +43,36 @@ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ - 'sphinx.ext.napoleon', - 'sphinx.ext.autodoc', - 'sphinx.ext.graphviz', - 'sphinx.ext.todo', - 'sphinx.ext.viewcode', - 'sphinx.ext.extlinks', - 'sphinx.ext.autosectionlabel', - 'myst_parser', + "sphinx.ext.napoleon", + "sphinx.ext.autodoc", + "sphinx.ext.graphviz", + "sphinx.ext.todo", + "sphinx.ext.viewcode", + "sphinx.ext.extlinks", + "sphinx.ext.autosectionlabel", + "myst_parser", "nbsphinx", - 'sphinxcontrib.actdiag', - 'sphinxcontrib.blockdiag', - 'sphinxcontrib.nwdiag', - 'sphinxcontrib.packetdiag', - 'sphinxcontrib.rackdiag', - 'sphinxcontrib.seqdiag', - 'sphinx_design', + "sphinxcontrib.actdiag", + "sphinxcontrib.blockdiag", + "sphinxcontrib.nwdiag", + "sphinxcontrib.packetdiag", + "sphinxcontrib.rackdiag", + "sphinxcontrib.seqdiag", + "sphinx_design", ] -nbsphinx_requirejs_path = '' +nbsphinx_requirejs_path = "" # Make sure the target is unique autosectionlabel_prefix_document = True # Add any paths that contain templates here, relative to this directory. -templates_path = ['_templates'] +templates_path = ["_templates"] # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. # This pattern also affects html_static_path and html_extra_path. -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] # Enable TODO todo_include_todos = True @@ -82,20 +82,20 @@ # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. # -html_theme = 'pydata_sphinx_theme' +html_theme = "pydata_sphinx_theme" # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ['_static'] +html_static_path = ["_static"] -html_favicon = '_static/favicon.ico' +html_favicon = "_static/favicon.ico" html_css_files = [ - 'css/custom.css', + "css/custom.css", ] -html_js_files = ['js/custom.js'] +html_js_files = ["js/custom.js"] html_theme_options = { "icon_links": [ @@ -139,9 +139,9 @@ # app setup hook def setup(app): app.add_config_value( - 'recommonmark_config', + "recommonmark_config", { - 'auto_toc_tree_section': 'Contents', + "auto_toc_tree_section": "Contents", }, True, )