evo-files 0.2.1__tar.gz → 0.2.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,33 @@
1
+ # IDE Settings
2
+ .idea/
3
+ .project
4
+ .pydevproject
5
+ .vscode/
6
+
7
+ # Distribution / Packaging
8
+ *.egg*
9
+ *.whl
10
+ __pycache__/
11
+ site/
12
+ build/
13
+
14
+ # Reporting
15
+ .coverage
16
+
17
+ # Environmnents
18
+ venv/
19
+ venv*/
20
+ .venv/
21
+ .env
22
+ .tox/
23
+
24
+ # Jupyter Notebook checkpoints
25
+ .ipynb_checkpoints/
26
+
27
+ # Sample data directories (ignore all data except input folders)
28
+ samples/*/publish*/data/*
29
+ samples/*/download*/data/*
30
+ !samples/*/publish*/data/input/
31
+
32
+ # macOS invisible files
33
+ .DS_Store
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: evo-files
3
- Version: 0.2.1
3
+ Version: 0.2.3
4
4
  Summary: Python SDK for using the Seequent Evo File API
5
5
  Project-URL: Source, https://github.com/SeequentEvo/evo-python-sdk
6
6
  Project-URL: Tracker, https://github.com/SeequentEvo/evo-python-sdk/issues
@@ -1,7 +1,7 @@
1
1
  [project]
2
2
  name = "evo-files"
3
3
  description = "Python SDK for using the Seequent Evo File API"
4
- version = "0.2.1"
4
+ version = "0.2.3"
5
5
  requires-python = ">=3.10"
6
6
  license-files = ["LICENSE.md"]
7
7
  dynamic = ["readme"]
@@ -50,6 +50,9 @@ line-length = 120
50
50
  [tool.ruff.lint]
51
51
  extend-select = ["I", "RUF022"]
52
52
 
53
+ [tool.ruff.lint.isort]
54
+ known-first-party = ["evo"]
55
+
53
56
  [build-system]
54
57
  requires = ["hatchling", "hatch-fancy-pypi-readme"]
55
58
  build-backend = "hatchling.build"
@@ -24,7 +24,7 @@ For more information on using the File API, see [Overview](https://developer.see
24
24
 
25
25
 
26
26
  This code is generated from the OpenAPI specification for File API.
27
- API version: 2.8.0
27
+ API version: 2.10.0
28
28
  """
29
29
 
30
30
  # Import endpoint apis.
@@ -24,11 +24,12 @@ For more information on using the File API, see [Overview](https://developer.see
24
24
 
25
25
 
26
26
  This code is generated from the OpenAPI specification for File API.
27
- API version: 2.8.0
27
+ API version: 2.10.0
28
28
  """
29
29
 
30
30
  from evo.common.connector import APIConnector
31
31
  from evo.common.data import EmptyResponse, RequestMethod
32
+ from evo.common.utils import get_header_metadata
32
33
 
33
34
  from ..models import * # noqa: F403
34
35
 
@@ -95,7 +96,7 @@ class FileV2Api:
95
96
  }
96
97
 
97
98
  # Prepare the header parameters.
98
- _header_params = {}
99
+ _header_params = {} | get_header_metadata(__name__)
99
100
  if additional_headers is not None:
100
101
  _header_params.update(additional_headers)
101
102
 
@@ -161,7 +162,7 @@ class FileV2Api:
161
162
  }
162
163
 
163
164
  # Prepare the header parameters.
164
- _header_params = {}
165
+ _header_params = {} | get_header_metadata(__name__)
165
166
  if additional_headers is not None:
166
167
  _header_params.update(additional_headers)
167
168
 
@@ -249,7 +250,7 @@ class FileV2Api:
249
250
  # Prepare the header parameters.
250
251
  _header_params = {
251
252
  "Accept": "application/json",
252
- }
253
+ } | get_header_metadata(__name__)
253
254
  if additional_headers is not None:
254
255
  _header_params.update(additional_headers)
255
256
 
@@ -332,7 +333,7 @@ class FileV2Api:
332
333
  # Prepare the header parameters.
333
334
  _header_params = {
334
335
  "Accept": "application/json",
335
- }
336
+ } | get_header_metadata(__name__)
336
337
  if additional_headers is not None:
337
338
  _header_params.update(additional_headers)
338
339
 
@@ -458,7 +459,7 @@ class FileV2Api:
458
459
  # Prepare the header parameters.
459
460
  _header_params = {
460
461
  "Accept": "application/json",
461
- }
462
+ } | get_header_metadata(__name__)
462
463
  if additional_headers is not None:
463
464
  _header_params.update(additional_headers)
464
465
 
@@ -546,7 +547,7 @@ class FileV2Api:
546
547
  # Prepare the header parameters.
547
548
  _header_params = {
548
549
  "Accept": "application/json",
549
- }
550
+ } | get_header_metadata(__name__)
550
551
  if additional_headers is not None:
551
552
  _header_params.update(additional_headers)
552
553
 
@@ -626,7 +627,7 @@ class FileV2Api:
626
627
  # Prepare the header parameters.
627
628
  _header_params = {
628
629
  "Accept": "application/json",
629
- }
630
+ } | get_header_metadata(__name__)
630
631
  if additional_headers is not None:
631
632
  _header_params.update(additional_headers)
632
633
 
@@ -109,9 +109,19 @@ class FileAPIUpload(Upload, _FileIOMixin):
109
109
  self._id = file_id
110
110
  self._version_id = version_id
111
111
 
112
+ @property
113
+ def file_id(self) -> UUID:
114
+ """The ID of the file that is being uploaded."""
115
+ return self._id
116
+
117
+ @property
118
+ def version_id(self) -> str:
119
+ """The ID of the version that will be created after the upload completes."""
120
+ return self._version_id
121
+
112
122
  @property
113
123
  def label(self) -> str:
114
- """The file and version ID for the file that is being uploaded."""
124
+ """The file and version ID of the file that is being uploaded."""
115
125
  return f"{self._id}?version_id={self._version_id}"
116
126
 
117
127
  async def get_upload_url(self) -> str:
@@ -1,24 +0,0 @@
1
- # IDE Settings
2
- .idea/
3
- .project
4
- .pydevproject
5
- .vscode/
6
-
7
- # Distribution / Packaging
8
- *.egg*
9
- *.whl
10
- __pycache__/
11
- site/
12
- build/
13
-
14
- # Reporting
15
- .coverage
16
-
17
- # Environmnents
18
- venv/
19
- venv*/
20
- .venv/
21
- .env
22
- .tox/
23
-
24
- .DS_store
File without changes