Skip to content

Commit

Permalink
Fixed url building in Windows (#672)
Browse files Browse the repository at this point in the history
  • Loading branch information
Raalsky authored Aug 25, 2021
1 parent 9bd5bf4 commit e375df7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 13 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## neptune-client 0.10.7 [UNRELEASED]

### Fixes
- Fixed url building in Windows ([#672](https://github.com/neptune-ai/neptune-client/pull/672))

## neptune-client 0.10.6

### Fixes
Expand Down
15 changes: 2 additions & 13 deletions neptune/new/internal/backends/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,9 @@
import socket
import sys
import time
import pathlib
from typing import Optional, Dict

from urllib.parse import urlparse, urlunparse
from urllib.parse import urlparse, urljoin

import click
import requests
Expand Down Expand Up @@ -155,14 +154,4 @@ def build_operation_url(base_api: str, operation_url: str) -> str:
if '://' not in base_api:
base_api = f'https://{base_api}'

base_api_url = urlparse(base_api)
path = pathlib.Path(base_api_url.path) / operation_url

return urlunparse((
base_api_url.scheme,
base_api_url.netloc,
str(path),
base_api_url.params,
base_api_url.query,
base_api_url.fragment,
))
return urljoin(base=base_api, url=operation_url)

0 comments on commit e375df7

Please sign in to comment.