Skip to content

Commit cc7c2fa

Browse files
authored
Improved docs for from_url (#138)
1 parent 185bd05 commit cc7c2fa

File tree

4 files changed

+19
-0
lines changed

4 files changed

+19
-0
lines changed

obstore/python/obstore/store/_aws.pyi

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,11 @@ class S3Store:
237237
- `https://<bucket>.s3.<region>.amazonaws.com`
238238
- `https://ACCOUNT_ID.r2.cloudflarestorage.com/bucket`
239239
240+
!!! note
241+
Note that `from_url` will not use any additional parts of the path as a
242+
bucket prefix. It will only extract the bucket, region, and endpoint. If you
243+
wish to use a path prefix, consider wrapping this with `PrefixStore`.
244+
240245
Args:
241246
url: well-known storage URL.
242247

obstore/python/obstore/store/_azure.pyi

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,11 @@ class AzureStore:
198198
- `https://<account>.blob.fabric.microsoft.com`
199199
- `https://<account>.blob.fabric.microsoft.com/<container>`
200200
201+
!!! note
202+
Note that `from_url` will not use any additional parts of the path as a
203+
bucket prefix. It will only extract the container name, account name, and
204+
whether it's a fabric endpoint. If you wish to use a path prefix, consider
205+
wrapping this with `PrefixStore`.
201206
202207
Args:
203208
url: well-known storage URL.

obstore/python/obstore/store/_gcs.pyi

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,11 @@ class GCSStore:
9292
9393
- `gs://<bucket>/<path>`
9494
95+
!!! note
96+
Note that `from_url` will not use any additional parts of the path as a
97+
bucket prefix. It will only extract the bucket name. If you wish to use a
98+
path prefix, consider wrapping this with `PrefixStore`.
99+
95100
Args:
96101
url: well-known storage URL.
97102

obstore/python/obstore/store/_http.pyi

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ class HTTPStore:
1616
) -> HTTPStore:
1717
"""Construct a new HTTPStore from a URL
1818
19+
!!! note
20+
Note that in contrast to the other stores, `from_url` **will** use the full
21+
URL provided here as a prefix for further operations.
22+
1923
Args:
2024
url: The base URL to use for the store.
2125

0 commit comments

Comments
 (0)