Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: EOL string error #124

Merged
merged 1 commit into from
Sep 6, 2024
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
6 changes: 3 additions & 3 deletions src/ydata/sdk/common/client/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,8 @@ def get_static_file(
from urllib.parse import urlparse
url_data = self.__build_url(endpoint, project=project)
url_parse = urlparse(self._base_url)
url_data['url'] = f'{
url_parse.scheme}://{url_parse.netloc}/static-content{endpoint}'
url_data['url'] = f"""{
url_parse.scheme}://{url_parse.netloc}/static-content{endpoint}"""
response = self._http_client.get(**url_data)

if response.status_code != Client.codes.OK and raise_for_status:
Expand Down Expand Up @@ -216,7 +216,7 @@ def __build_url(self, endpoint: str, params: Optional[Dict] = None, data: Option
}

url_data = {
'url': f'{self._base_url}/{endpoint.removeprefix("/")}',
'url': f"""{self._base_url}/{endpoint.removeprefix("/")}""",
'headers': self._headers,
'params': _params,
}
Expand Down
4 changes: 2 additions & 2 deletions src/ydata/sdk/common/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ class ClientCreationError(ClientException):
def __init__(self, message=None):
from ydata.sdk.common.client.client import HELP_TEXT
if message is None:
message = f"Could not initialize a client. It usually means that no token could be found or the token needs to be refreshed.\n{
HELP_TEXT}"
message = f"""Could not initialize a client. It usually means that no token could be found or the
token needs to be refreshed.\n{HELP_TEXT}"""

super().__init__(message)

Expand Down
Loading