kevinjqliu commented on code in PR #1007:
URL: https://github.com/apache/iceberg-python/pull/1007#discussion_r1829809442
##########
pyiceberg/io/fsspec.py:
##########
@@ -171,6 +172,14 @@ def _gs(properties: Properties) -> AbstractFileSystem:
# https://gcsfs.readthedocs.io/en/latest/api.html#gcsfs.core.GCSFileSystem
from gcsfs import GCSFileSystem
+ if (endpoint := properties.get(GCS_ENDPOINT)) and GCS_SERVICE_HOST not in
properties:
+ deprecation_message(
+ deprecated_in="0.8.0",
+ removed_in="0.9.0",
+ help_message=f"The property {GCS_ENDPOINT} is deprecated, please
use {GCS_SERVICE_HOST} instead",
+ )
+ properties[GCS_SERVICE_HOST] = endpoint
+
Review Comment:
```suggestion
if properties.get(GCS_ENDPOINT):
deprecation_message(
deprecated_in="0.8.0",
removed_in="0.9.0",
help_message=f"The property {GCS_ENDPOINT} is deprecated, please
use {GCS_SERVICE_HOST} instead",
)
```
##########
pyiceberg/io/fsspec.py:
##########
@@ -179,7 +188,7 @@ def _gs(properties: Properties) -> AbstractFileSystem:
cache_timeout=properties.get(GCS_CACHE_TIMEOUT),
requester_pays=property_as_bool(properties, GCS_REQUESTER_PAYS, False),
session_kwargs=json.loads(properties.get(GCS_SESSION_KWARGS, "{}")),
- endpoint_url=properties.get(GCS_ENDPOINT),
+ endpoint_url=properties.get(GCS_SERVICE_HOST),
Review Comment:
```suggestion
endpoint_url=get_first_property_value(properties, GCS_SERVICE_HOST,
GCS_ENDPOINT),
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]