Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 11 additions & 6 deletions docs/content/en/latest/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,19 @@ Start integrating GoodData into your Python application right now.
profiles.yaml file structure example:

```yaml
default:
host: http://localhost:3000
token: YWRtaW46Ym9vdHN0cmFwOmFkbWluMTIz
custom_headers: #optional
Host: localhost
extra_user_agent: xyz #optional
profiles:
dev:
host: http://localhost:3000
token: $GOODDATA_API_TOKEN_DEV
custom_headers: #optional
Host: localhost
extra_user_agent: xyz #optional
default_profile: dev
access: {}
```

The `token` field should reference an environment variable that holds your personal access token. The `access` field can include references to environment variables with data source secrets, or it can be left empty if not needed.

1. Start using Python SDK! For example, get a list of all workspaces:

```python
Expand Down
6 changes: 4 additions & 2 deletions gooddata-sdk/gooddata_sdk/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,12 +283,14 @@ def _create_profile_aac(profile: str, content: dict) -> dict:
def _get_profile(profile: str, content: dict) -> dict[str, Any]:
is_aac_config = AacConfig.can_structure(content)
if not is_aac_config and profile not in content:
raise ValueError("Configuration is invalid. Please check the documentation for the valid configuration.")
raise ValueError(
"Configuration is invalid. Please check the documentation for the valid configuration: https://www.gooddata.com/docs/python-sdk/latest/getting-started/"
)
if is_aac_config:
return _create_profile_aac(profile, content)
else:
warn(
"Used configuration is deprecated and will be removed in the future. Please use the new configuration.",
"Used configuration is deprecated and will be removed in the future. Please use the new configuration: https://www.gooddata.com/docs/python-sdk/latest/getting-started/",
DeprecationWarning,
stacklevel=2,
)
Expand Down
Loading