Skip to content

Commit 157226e

Browse files
[Storage] Fix datetime parsing docstring (#34926)
* Adjust docstring
1 parent b07db72 commit 157226e

File tree

12 files changed

+54
-83
lines changed

12 files changed

+54
-83
lines changed

sdk/storage/azure-storage-blob/azure/storage/blob/_models.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -792,9 +792,8 @@ class AccessPolicy(GenAccessPolicy):
792792
:param start:
793793
The time at which the shared access signature becomes valid. If
794794
omitted, start time for this call is assumed to be the time when the
795-
storage service receives the request. Azure will always convert values
796-
to UTC. If a date is passed in without timezone info, it is assumed to
797-
be UTC.
795+
storage service receives the request. The provided datetime will always
796+
be interpreted as UTC.
798797
:type start: ~datetime.datetime or str
799798
"""
800799
def __init__(self, permission=None, expiry=None, start=None):

sdk/storage/azure-storage-blob/azure/storage/blob/_shared/shared_access_signature.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,8 @@ def generate_account(self, services, resource_types, permission, expiry, start=N
136136
:param start:
137137
The time at which the shared access signature becomes valid. If
138138
omitted, start time for this call is assumed to be the time when the
139-
storage service receives the request. Azure will always convert values
140-
to UTC. If a date is passed in without timezone info, it is assumed to
141-
be UTC.
139+
storage service receives the request. The provided datetime will always
140+
be interpreted as UTC.
142141
:type start: datetime or str
143142
:param str ip:
144143
Specifies an IP address or a range of IP addresses from which to accept requests.

sdk/storage/azure-storage-blob/azure/storage/blob/_shared_access_signature.py

+11-17
Original file line numberDiff line numberDiff line change
@@ -91,9 +91,8 @@ def generate_blob(self, container_name, blob_name, snapshot=None, version_id=Non
9191
:param start:
9292
The time at which the shared access signature becomes valid. If
9393
omitted, start time for this call is assumed to be the time when the
94-
storage service receives the request. Azure will always convert values
95-
to UTC. If a date is passed in without timezone info, it is assumed to
96-
be UTC.
94+
storage service receives the request. The provided datetime will always
95+
be interpreted as UTC.
9796
:type start: datetime or str
9897
:param str policy_id:
9998
A unique value up to 64 characters in length that correlates to a
@@ -178,9 +177,8 @@ def generate_container(self, container_name, permission=None, expiry=None,
178177
:param start:
179178
The time at which the shared access signature becomes valid. If
180179
omitted, start time for this call is assumed to be the time when the
181-
storage service receives the request. Azure will always convert values
182-
to UTC. If a date is passed in without timezone info, it is assumed to
183-
be UTC.
180+
storage service receives the request. The provided datetime will always
181+
be interpreted as UTC.
184182
:type start: datetime or str
185183
:param str policy_id:
186184
A unique value up to 64 characters in length that correlates to a
@@ -337,15 +335,13 @@ def generate_account_sas(
337335
:type permission: str or ~azure.storage.blob.AccountSasPermissions
338336
:param expiry:
339337
The time at which the shared access signature becomes invalid.
340-
Azure will always convert values to UTC. If a date is passed in
341-
without timezone info, it is assumed to be UTC.
338+
The provided datetime will always be interpreted as UTC.
342339
:type expiry: ~datetime.datetime or str
343340
:param start:
344341
The time at which the shared access signature becomes valid. If
345342
omitted, start time for this call is assumed to be the time when the
346-
storage service receives the request. Azure will always convert values
347-
to UTC. If a date is passed in without timezone info, it is assumed to
348-
be UTC.
343+
storage service receives the request. The provided datetime will always
344+
be interpreted as UTC.
349345
:type start: ~datetime.datetime or str
350346
:param str ip:
351347
Specifies an IP address or a range of IP addresses from which to accept requests.
@@ -433,9 +429,8 @@ def generate_container_sas(
433429
:param start:
434430
The time at which the shared access signature becomes valid. If
435431
omitted, start time for this call is assumed to be the time when the
436-
storage service receives the request. Azure will always convert values
437-
to UTC. If a date is passed in without timezone info, it is assumed to
438-
be UTC.
432+
storage service receives the request. The provided datetime will always
433+
be interpreted as UTC.
439434
:type start: ~datetime.datetime or str
440435
:param str policy_id:
441436
A unique value up to 64 characters in length that correlates to a
@@ -560,9 +555,8 @@ def generate_blob_sas(
560555
:param start:
561556
The time at which the shared access signature becomes valid. If
562557
omitted, start time for this call is assumed to be the time when the
563-
storage service receives the request. Azure will always convert values
564-
to UTC. If a date is passed in without timezone info, it is assumed to
565-
be UTC.
558+
storage service receives the request. The provided datetime will always
559+
be interpreted as UTC.
566560
:type start: ~datetime.datetime or str
567561
:param str policy_id:
568562
A unique value up to 64 characters in length that correlates to a

sdk/storage/azure-storage-file-datalake/azure/storage/filedatalake/_models.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -656,9 +656,8 @@ class AccessPolicy(BlobAccessPolicy):
656656
:keyword start:
657657
The time at which the shared access signature becomes valid. If
658658
omitted, start time for this call is assumed to be the time when the
659-
storage service receives the request. Azure will always convert values
660-
to UTC. If a date is passed in without timezone info, it is assumed to
661-
be UTC.
659+
storage service receives the request. The provided datetime will always
660+
be interpreted as UTC.
662661
:paramtype start: ~datetime.datetime or str
663662
"""
664663

sdk/storage/azure-storage-file-datalake/azure/storage/filedatalake/_shared/shared_access_signature.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,8 @@ def generate_account(self, services, resource_types, permission, expiry, start=N
136136
:param start:
137137
The time at which the shared access signature becomes valid. If
138138
omitted, start time for this call is assumed to be the time when the
139-
storage service receives the request. Azure will always convert values
140-
to UTC. If a date is passed in without timezone info, it is assumed to
141-
be UTC.
139+
storage service receives the request. The provided datetime will always
140+
be interpreted as UTC.
142141
:type start: datetime or str
143142
:param str ip:
144143
Specifies an IP address or a range of IP addresses from which to accept requests.

sdk/storage/azure-storage-file-datalake/azure/storage/filedatalake/_shared_access_signature.py

+9-14
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,13 @@ def generate_account_sas(
5454
:type permission: str or ~azure.storage.filedatalake.AccountSasPermissions
5555
:param expiry:
5656
The time at which the shared access signature becomes invalid.
57-
Azure will always convert values to UTC. If a date is passed in
58-
without timezone info, it is assumed to be UTC.
57+
The provided datetime will always be interpreted as UTC.
5958
:type expiry: ~datetime.datetime or str
6059
:keyword start:
6160
The time at which the shared access signature becomes valid. If
6261
omitted, start time for this call is assumed to be the time when the
63-
storage service receives the request. Azure will always convert values
64-
to UTC. If a date is passed in without timezone info, it is assumed to
65-
be UTC.
62+
storage service receives the request. The provided datetime will always
63+
be interpreted as UTC.
6664
:paramtype start: ~datetime.datetime or str
6765
:keyword str ip:
6866
Specifies an IP address or a range of IP addresses from which to accept requests.
@@ -137,9 +135,8 @@ def generate_file_system_sas(
137135
:keyword start:
138136
The time at which the shared access signature becomes valid. If
139137
omitted, start time for this call is assumed to be the time when the
140-
storage service receives the request. Azure will always convert values
141-
to UTC. If a date is passed in without timezone info, it is assumed to
142-
be UTC.
138+
storage service receives the request. The provided datetime will always
139+
be interpreted as UTC.
143140
:paramtype start: datetime or str
144141
:keyword str policy_id:
145142
A unique value up to 64 characters in length that correlates to a
@@ -245,9 +242,8 @@ def generate_directory_sas(
245242
:keyword start:
246243
The time at which the shared access signature becomes valid. If
247244
omitted, start time for this call is assumed to be the time when the
248-
storage service receives the request. Azure will always convert values
249-
to UTC. If a date is passed in without timezone info, it is assumed to
250-
be UTC.
245+
storage service receives the request. The provided datetime will always
246+
be interpreted as UTC.
251247
:paramtype start: ~datetime.datetime or str
252248
:keyword str policy_id:
253249
A unique value up to 64 characters in length that correlates to a
@@ -360,9 +356,8 @@ def generate_file_sas(
360356
:keyword start:
361357
The time at which the shared access signature becomes valid. If
362358
omitted, start time for this call is assumed to be the time when the
363-
storage service receives the request. Azure will always convert values
364-
to UTC. If a date is passed in without timezone info, it is assumed to
365-
be UTC.
359+
storage service receives the request. The provided datetime will always
360+
be interpreted as UTC.
366361
:paramtype start: ~datetime.datetime or str
367362
:keyword str policy_id:
368363
A unique value up to 64 characters in length that correlates to a

sdk/storage/azure-storage-file-share/azure/storage/fileshare/_models.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -220,9 +220,8 @@ class AccessPolicy(GenAccessPolicy):
220220
:param start:
221221
The time at which the shared access signature becomes valid. If
222222
omitted, start time for this call is assumed to be the time when the
223-
storage service receives the request. Azure will always convert values
224-
to UTC. If a date is passed in without timezone info, it is assumed to
225-
be UTC.
223+
storage service receives the request. The provided datetime will always
224+
be interpreted as UTC.
226225
:type start: ~datetime.datetime or str
227226
"""
228227
def __init__(self, permission=None, expiry=None, start=None):

sdk/storage/azure-storage-file-share/azure/storage/fileshare/_shared/shared_access_signature.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,8 @@ def generate_account(self, services, resource_types, permission, expiry, start=N
136136
:param start:
137137
The time at which the shared access signature becomes valid. If
138138
omitted, start time for this call is assumed to be the time when the
139-
storage service receives the request. Azure will always convert values
140-
to UTC. If a date is passed in without timezone info, it is assumed to
141-
be UTC.
139+
storage service receives the request. The provided datetime will always
140+
be interpreted as UTC.
142141
:type start: datetime or str
143142
:param str ip:
144143
Specifies an IP address or a range of IP addresses from which to accept requests.

sdk/storage/azure-storage-file-share/azure/storage/fileshare/_shared_access_signature.py

+11-17
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,8 @@ def generate_file(self, share_name, directory_name=None, file_name=None,
7676
:param start:
7777
The time at which the shared access signature becomes valid. If
7878
omitted, start time for this call is assumed to be the time when the
79-
storage service receives the request. Azure will always convert values
80-
to UTC. If a date is passed in without timezone info, it is assumed to
81-
be UTC.
79+
storage service receives the request. The provided datetime will always
80+
be interpreted as UTC.
8281
:type start: datetime or str
8382
:param str policy_id:
8483
A unique value up to 64 characters in length that correlates to a
@@ -157,9 +156,8 @@ def generate_share(self, share_name, permission=None, expiry=None,
157156
:param start:
158157
The time at which the shared access signature becomes valid. If
159158
omitted, start time for this call is assumed to be the time when the
160-
storage service receives the request. Azure will always convert values
161-
to UTC. If a date is passed in without timezone info, it is assumed to
162-
be UTC.
159+
storage service receives the request. The provided datetime will always
160+
be interpreted as UTC.
163161
:type start: datetime or str
164162
:param str policy_id:
165163
A unique value up to 64 characters in length that correlates to a
@@ -269,15 +267,13 @@ def generate_account_sas(
269267
user is restricted to operations allowed by the permissions.
270268
:param expiry:
271269
The time at which the shared access signature becomes invalid.
272-
Azure will always convert values to UTC. If a date is passed in without
273-
timezone info, it is assumed to be UTC.
270+
The provided datetime will always be interpreted as UTC.
274271
:type expiry: ~datetime.datetime or str
275272
:param start:
276273
The time at which the shared access signature becomes valid. If
277274
omitted, start time for this call is assumed to be the time when the
278-
storage service receives the request. Azure will always convert values
279-
to UTC. If a date is passed in without timezone info, it is assumed to
280-
be UTC.
275+
storage service receives the request. The provided datetime will always
276+
be interpreted as UTC.
281277
:type start: ~datetime.datetime or str
282278
:param str ip:
283279
Specifies an IP address or a range of IP addresses from which to accept requests.
@@ -355,9 +351,8 @@ def generate_share_sas(
355351
:param start:
356352
The time at which the shared access signature becomes valid. If
357353
omitted, start time for this call is assumed to be the time when the
358-
storage service receives the request. Azure will always convert values
359-
to UTC. If a date is passed in without timezone info, it is assumed to
360-
be UTC.
354+
storage service receives the request. The provided datetime will always
355+
be interpreted as UTC.
361356
:type start: ~datetime.datetime or str
362357
:param str policy_id:
363358
A unique value up to 64 characters in length that correlates to a
@@ -452,9 +447,8 @@ def generate_file_sas(
452447
:param start:
453448
The time at which the shared access signature becomes valid. If
454449
omitted, start time for this call is assumed to be the time when the
455-
storage service receives the request. Azure will always convert values
456-
to UTC. If a date is passed in without timezone info, it is assumed to
457-
be UTC.
450+
storage service receives the request. The provided datetime will always
451+
be interpreted as UTC.
458452
:type start: ~datetime.datetime or str
459453
:param str policy_id:
460454
A unique value up to 64 characters in length that correlates to a

sdk/storage/azure-storage-queue/azure/storage/queue/_models.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -325,9 +325,8 @@ class AccessPolicy(GenAccessPolicy):
325325
:param Optional[Union["datetime", str]] start:
326326
The time at which the shared access signature becomes valid. If
327327
omitted, start time for this call is assumed to be the time when the
328-
storage service receives the request. Azure will always convert values
329-
to UTC. If a date is passed in without timezone info, it is assumed to
330-
be UTC.
328+
storage service receives the request. The provided datetime will always
329+
be interpreted as UTC.
331330
"""
332331

333332
permission: Optional[Union[QueueSasPermissions, str]] #type: ignore [assignment]

sdk/storage/azure-storage-queue/azure/storage/queue/_shared/shared_access_signature.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,8 @@ def generate_account(self, services, resource_types, permission, expiry, start=N
136136
:param start:
137137
The time at which the shared access signature becomes valid. If
138138
omitted, start time for this call is assumed to be the time when the
139-
storage service receives the request. Azure will always convert values
140-
to UTC. If a date is passed in without timezone info, it is assumed to
141-
be UTC.
139+
storage service receives the request. The provided datetime will always
140+
be interpreted as UTC.
142141
:type start: datetime or str
143142
:param str ip:
144143
Specifies an IP address or a range of IP addresses from which to accept requests.

sdk/storage/azure-storage-queue/azure/storage/queue/_shared_access_signature.py

+7-11
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,8 @@ def generate_queue(
7474
:param start:
7575
The time at which the shared access signature becomes valid. If
7676
omitted, start time for this call is assumed to be the time when the
77-
storage service receives the request. Azure will always convert values
78-
to UTC. If a date is passed in without timezone info, it is assumed to
79-
be UTC.
77+
storage service receives the request. The provided datetime will always
78+
be interpreted as UTC.
8079
:type start: ~datetime.datetime or str
8180
:param str policy_id:
8281
A unique value up to 64 characters in length that correlates to a
@@ -161,15 +160,13 @@ def generate_account_sas(
161160
:type permission: ~azure.storage.queue.AccountSasPermissions or str
162161
:param expiry:
163162
The time at which the shared access signature becomes invalid.
164-
Azure will always convert values to UTC. If a date is passed in
165-
without timezone info, it is assumed to be UTC.
163+
The provided datetime will always be interpreted as UTC.
166164
:type expiry: ~datetime.datetime or str
167165
:param start:
168166
The time at which the shared access signature becomes valid. If
169167
omitted, start time for this call is assumed to be the time when the
170-
storage service receives the request. Azure will always convert values
171-
to UTC. If a date is passed in without timezone info, it is assumed to
172-
be UTC.
168+
storage service receives the request. The provided datetime will always
169+
be interpreted as UTC.
173170
:type start: ~datetime.datetime or str
174171
:param str ip:
175172
Specifies an IP address or a range of IP addresses from which to accept requests.
@@ -236,9 +233,8 @@ def generate_queue_sas(
236233
:param start:
237234
The time at which the shared access signature becomes valid. If
238235
omitted, start time for this call is assumed to be the time when the
239-
storage service receives the request. Azure will always convert values
240-
to UTC. If a date is passed in without timezone info, it is assumed to
241-
be UTC.
236+
storage service receives the request. The provided datetime will always
237+
be interpreted as UTC.
242238
:type start: ~datetime.datetime or str
243239
:param str policy_id:
244240
A unique value up to 64 characters in length that correlates to a

0 commit comments

Comments
 (0)