diff --git a/api-openbis-python3-pybis/src/python/CHANGELOG.md b/api-openbis-python3-pybis/src/python/CHANGELOG.md index 682a0df5180e38fe0b71bc30faf03f86d8228920..f9a9f9fe9823c9ba458fc415fa06b56a12392aa5 100644 --- a/api-openbis-python3-pybis/src/python/CHANGELOG.md +++ b/api-openbis-python3-pybis/src/python/CHANGELOG.md @@ -1,3 +1,7 @@ +## Changes with pybis-1.35.11 + +- Improvements to dataset upload performance + ## Changes with pybis-1.35.10 - Fixed issue with changing properties for linked datasets diff --git a/api-openbis-python3-pybis/src/python/pybis/__init__.py b/api-openbis-python3-pybis/src/python/pybis/__init__.py index 5d5df0f11d731c9362661edc45000005ab7ad302..c2b117fa5198e446738104f6c00567f4f21ca0af 100644 --- a/api-openbis-python3-pybis/src/python/pybis/__init__.py +++ b/api-openbis-python3-pybis/src/python/pybis/__init__.py @@ -15,7 +15,7 @@ name = "pybis" __author__ = "ID SIS • ETH Zürich" __email__ = "openbis-support@id.ethz.ch" -__version__ = "1.35.10" +__version__ = "1.35.11" from . import pybis from .pybis import DataSet diff --git a/api-openbis-python3-pybis/src/python/pybis/dataset.py b/api-openbis-python3-pybis/src/python/pybis/dataset.py index 9ba2f319b59b4f2e3776b74d40d077571bd6157f..7b29adfc32cd4c9f3b2e8cb2c680ce175f4a7016 100644 --- a/api-openbis-python3-pybis/src/python/pybis/dataset.py +++ b/api-openbis-python3-pybis/src/python/pybis/dataset.py @@ -1245,9 +1245,14 @@ class DataSetUploadQueue: file_size = os.path.getsize(filename) if self.multipart is True: - file = {filename: open(filename, "rb")} - resp = requests.post(upload_url, files=file, verify=verify_certificates) - resp.raise_for_status() + from requests_toolbelt.multipart.encoder import MultipartEncoder + with open(filename, "rb") as f: + m = MultipartEncoder( + fields={filename: (filename, f, 'application/octet-stream')}) + headers = {'Content-Type': m.content_type} + r = requests.post(upload_url, data=m, headers=headers, + verify=verify_certificates) + r.raise_for_status() else: # upload the file to our DSS session workspace with open(filename, "rb") as f: diff --git a/api-openbis-python3-pybis/src/python/setup.cfg b/api-openbis-python3-pybis/src/python/setup.cfg index 8c8e06e5b17f356187b80935a30471c5bbdab801..0cdcd3a74f79000a9bc01b08c97fa0134dde98a1 100644 --- a/api-openbis-python3-pybis/src/python/setup.cfg +++ b/api-openbis-python3-pybis/src/python/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = PyBIS -version = 1.35.10 +version = 1.35.11 author = ID SIS • ETH Zürich author_email = openbis-support@id.ethz.ch license = Apache Software License Version 2.0 diff --git a/api-openbis-python3-pybis/src/python/setup.py b/api-openbis-python3-pybis/src/python/setup.py index 6bf70e05b69b428fc82fc2954d76ba27e6ff2165..8d94cd3df9542c77a24724bba9eeff55acd43f1a 100644 --- a/api-openbis-python3-pybis/src/python/setup.py +++ b/api-openbis-python3-pybis/src/python/setup.py @@ -26,7 +26,7 @@ with open("README.md", "r", encoding="utf-8") as fh: setup( name="PyBIS", - version="1.35.10", + version="1.35.11", author="ID SIS • ETH Zürich", author_email="openbis-support@id.ethz.ch", description="openBIS connection and interaction, optimized for using with Jupyter", diff --git a/api-openbis-python3-pybis/src/python/tests/jenkinstest/test.py b/api-openbis-python3-pybis/src/python/tests/jenkinstest/test.py index 26e3904b7aa3a207205884a155caacd0c9eedbf6..f1700ac09ccd83dc62c0033822df4c78daa4073c 100644 --- a/api-openbis-python3-pybis/src/python/tests/jenkinstest/test.py +++ b/api-openbis-python3-pybis/src/python/tests/jenkinstest/test.py @@ -27,7 +27,7 @@ class TestCase(testcase.TestCase): self.openbisController = self.createOpenbisController() self.openbisController.allUp() # run tests - util.executeCommand(['pytest', '--junitxml=test_results_pybis.xml', + util.executeCommand(['pytest', '--verbose', '--junitxml=test_results_pybis.xml', 'api-openbis-python3-pybis/src/python/tests']) diff --git a/app-openbis-command-line/src/python/CHANGELOG.md b/app-openbis-command-line/src/python/CHANGELOG.md index d4bc519116d59a986d86dffb07734e6661ff845e..461d6c1c0acff0e347b2d373863655b5f80fe992 100644 --- a/app-openbis-command-line/src/python/CHANGELOG.md +++ b/app-openbis-command-line/src/python/CHANGELOG.md @@ -4,7 +4,7 @@ * Added recursive search to object and data_set search commands * Updated documentation regarding authentication * Added dataset ids to sample search results -* changed pybis dependency to version == 1.35.10 +* changed pybis dependency to version == 1.35.11 # New in version 0.4.1 diff --git a/app-openbis-command-line/src/python/obis/__init__.py b/app-openbis-command-line/src/python/obis/__init__.py index dd4ec142b180477405183dd6e20e9806e5aae0fb..bba01c84213abed1ed19e527218e764d35c95461 100644 --- a/app-openbis-command-line/src/python/obis/__init__.py +++ b/app-openbis-command-line/src/python/obis/__init__.py @@ -14,6 +14,6 @@ # __author__ = "ID SIS • ETH Zürich" __email__ = "openbis-support@id.ethz.ch" -__version__ = "0.4.2rc5" +__version__ = "0.4.2rc6" from .dm import * diff --git a/app-openbis-command-line/src/python/setup.py b/app-openbis-command-line/src/python/setup.py index 29c14b57c26e007494206d4086176d30b924487e..267cea437ffead2b487d965101d0c14d3c6b91db 100644 --- a/app-openbis-command-line/src/python/setup.py +++ b/app-openbis-command-line/src/python/setup.py @@ -31,7 +31,7 @@ data_files = [ setup( name="obis", - version="0.4.2rc5", + version="0.4.2rc6", description="Local data management with assistance from OpenBIS.", long_description=long_description, long_description_content_type="text/markdown", @@ -42,7 +42,7 @@ setup( packages=["obis", "obis.dm", "obis.dm.commands", "obis.scripts"], data_files=data_files, package_data={"obis": ["dm/git-annex-attributes"]}, - install_requires=["pyOpenSSL", "pytest", "pybis==1.35.10", "click"], + install_requires=["pyOpenSSL", "pytest", "pybis==1.35.11", "click"], entry_points={"console_scripts": ["obis=obis.scripts.cli:main"]}, zip_safe=False, python_requires=">=3.3", diff --git a/docs/software-developer-documentation/apis/python-v3-api.md b/docs/software-developer-documentation/apis/python-v3-api.md index 9055bb1d98301aba1ddbac04271da61f78999c6b..22712262b1c173c42f46b8209e37db24cc7da58f 100644 --- a/docs/software-developer-documentation/apis/python-v3-api.md +++ b/docs/software-developer-documentation/apis/python-v3-api.md @@ -1540,4 +1540,4 @@ pt.save() Currently, the value of the `custom_widget` key can be set to either - `Spreadsheet` (for tabular, Excel-like data) -- `Word Processor` (for rich text data) \ No newline at end of file +- `Word Processor` (for rich text data)