globus / globus/globus-sdk-python

Python equivalent of `globus gcp create mapped`

Open
#1,337 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
75
Forks
48
Avg merge
1d 5h
Merged PRs (30d)
9

Description

`globus gcp create mapped` creates a new collection for use with GCP *but without needing GCP to be already running*. There is seemingly no way to do this in `globus_sdk==4.1.0` that I have found.

If I look at how the CLI does it, it apparently [calls some deprecated API](https://github.com/globus/globus-cli/blob/e7d2804882a8f828385873023609994572d91624/src/globus_cli/commands/gcp/create/mapped.py#L59-L80C40).

***

There is a similar method called `TransferClient.create_shared_endpoint` available, but this seems to require a "host_endpoint", which isn't what I want:

```python
result = globus_sdk.TransferClient(
app=app
).create_shared_endpoint(data=dict(
display_name="XXX",
)
)
```
```json
{
"code": "BadRequest",
"message": "invalid host_endpoint, cannot be empty string, null, or missing",
"request_id": "XXXXXXXX",
"resource": "/shared_endpoint"
}
```

***

If I try to bypass the abstractions and hit the API directly, it still doesn't work for me:
```python
result = globus_sdk.TransferClient(
app=app
).post(
"/v0.10/endpoint",
data=dict(
display_name="XXX",
)
)
```
```json
{
"code": "NotSupported",
"message": "GCSv4 is no longer supported. Contact your sysadmin.",
"request_id": "XXXXXXXX",
"resource": "/endpoint"
}
```

What should I do here?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.