Skip to content
This repository has been archived by the owner on Dec 22, 2022. It is now read-only.

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ndmeiri committed Jun 25, 2018
1 parent c620eac commit 993d65b
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions bugswarm/common/rest_api/database_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class DatabaseAPI(object):
"""
This class encapsulates programmatic access to the BugSwarm metadata database via the REST API.
"""
_BASE_URL = 'http://api.bugswarm.org/v1/'
_BASE_URL = 'http://api.bugswarm.org/v1'
_ARTIFACTS_RESOURCE = 'artifacts'
_MINED_BUILD_PAIRS_RESOURCE = 'minedBuildPairs'
_MINED_PROJECTS_RESOURCE = 'minedProjects'
Expand Down Expand Up @@ -464,7 +464,7 @@ def _endpoint(resource: str) -> Endpoint:
raise TypeError
if not resource:
raise ValueError
return urljoin(DatabaseAPI.base_url, resource)
return '/'.join([DatabaseAPI.base_url, resource])

@staticmethod
def _artifacts_endpoint() -> Endpoint:
Expand All @@ -476,7 +476,7 @@ def _artifact_image_tag_endpoint(image_tag: str) -> Endpoint:
raise TypeError
if not image_tag:
raise ValueError
return urljoin(DatabaseAPI._artifacts_endpoint(), image_tag)
return '/'.join([DatabaseAPI._artifacts_endpoint(), image_tag])

@staticmethod
def _mined_build_pairs_endpoint() -> Endpoint:
Expand All @@ -488,7 +488,7 @@ def _mined_build_pair_object_id_endpoint(object_id: str) -> Endpoint:
raise TypeError
if not object_id:
raise ValueError
return urljoin(DatabaseAPI._mined_build_pairs_endpoint(), object_id)
return '/'.join([DatabaseAPI._mined_build_pairs_endpoint(), object_id])

@staticmethod
def _mined_projects_endpoint() -> Endpoint:
Expand All @@ -500,7 +500,7 @@ def _mined_project_repo_endpoint(repo: str) -> Endpoint:
raise TypeError
if not repo:
raise ValueError
return urljoin(DatabaseAPI._mined_projects_endpoint(), repo)
return '/'.join([DatabaseAPI._mined_projects_endpoint(), repo])

@staticmethod
def _email_subscribers_endpoint() -> Endpoint:
Expand All @@ -512,7 +512,7 @@ def _email_subscriber_email_endpoint(email: str) -> Endpoint:
raise TypeError
if not email:
raise ValueError
return urljoin(DatabaseAPI._email_subscribers_endpoint(), email)
return '/'.join([DatabaseAPI._email_subscribers_endpoint(), email])

@staticmethod
def _accounts_endpoint() -> Endpoint:
Expand All @@ -524,4 +524,4 @@ def _account_email_endpoint(email: str) -> Endpoint:
raise TypeError
if not email:
raise ValueError
return urljoin(DatabaseAPI._accounts_endpoint(), email)
return '/'.join([DatabaseAPI._accounts_endpoint(), email])

0 comments on commit 993d65b

Please sign in to comment.